2019-02-28
This commit is contained in:
parent
47498123af
commit
84525eeaec
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
@ -48,8 +48,9 @@ $(function() {
|
|||
<table class="directory">
|
||||
<tr class="even"><td class="entry"><a class="el" href="classIdenticonpp.html#a229201bc23b0fabbcca60f2fe0188fa9">algorithm</a> enum name</td><td class="entry"><a class="el" href="classIdenticonpp.html">Identiconpp</a></td><td class="entry"></td></tr>
|
||||
<tr><td class="entry"><a class="el" href="classIdenticonpp.html#a82f624d713e2d32d5fdb26b9112b821a">generate</a>(const string &digest, const uint16_t width=100)</td><td class="entry"><a class="el" href="classIdenticonpp.html">Identiconpp</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classIdenticonpp.html#ad87f4b0b3ebb0e54fe862fb5d77f8a00">Identiconpp</a>(const uint8_t columns, const uint8_t rows, algorithm type=algorithm::ltr_symmetric, const string &background="ffffffff", const vector< string > &foreground={ "000000ff" }, const array< const uint8_t, 2 > &padding={ 0, 0 })</td><td class="entry"><a class="el" href="classIdenticonpp.html">Identiconpp</a></td><td class="entry"><span class="mlabel">explicit</span></td></tr>
|
||||
<tr bgcolor="#f0f0f0"><td class="entry"><b>Testiconpp</b> (defined in <a class="el" href="classIdenticonpp.html">Identiconpp</a>)</td><td class="entry"><a class="el" href="classIdenticonpp.html">Identiconpp</a></td><td class="entry"><span class="mlabel">friend</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classIdenticonpp.html#ac4c9752b03d6e0a7c7950aee0637a82b">generate_base64</a>(const string &magick, const string &digest, const uint16_t width=100)</td><td class="entry"><a class="el" href="classIdenticonpp.html">Identiconpp</a></td><td class="entry"></td></tr>
|
||||
<tr><td class="entry"><a class="el" href="classIdenticonpp.html#a55a4890677c963f24b89bd2aef906f1b">Identiconpp</a>(const uint8_t columns, const uint8_t rows, algorithm type=algorithm::ltr_symmetric, const string &background="ffffffff", const vector< string > &foreground={ "000000ff" }, const array< uint8_t, 2 > &padding={ 0, 0 })</td><td class="entry"><a class="el" href="classIdenticonpp.html">Identiconpp</a></td><td class="entry"><span class="mlabel">explicit</span></td></tr>
|
||||
<tr bgcolor="#f0f0f0" class="even"><td class="entry"><b>Testiconpp</b> (defined in <a class="el" href="classIdenticonpp.html">Identiconpp</a>)</td><td class="entry"><a class="el" href="classIdenticonpp.html">Identiconpp</a></td><td class="entry"><span class="mlabel">friend</span></td></tr>
|
||||
</table></div><!-- contents -->
|
||||
<!-- start footer part -->
|
||||
<hr class="footer"/><address class="footer"><small>
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
@ -46,8 +46,11 @@ $(function() {
|
|||
<li>generate()
|
||||
: <a class="el" href="classIdenticonpp.html#a82f624d713e2d32d5fdb26b9112b821a">Identiconpp</a>
|
||||
</li>
|
||||
<li>generate_base64()
|
||||
: <a class="el" href="classIdenticonpp.html#ac4c9752b03d6e0a7c7950aee0637a82b">Identiconpp</a>
|
||||
</li>
|
||||
<li>Identiconpp()
|
||||
: <a class="el" href="classIdenticonpp.html#ad87f4b0b3ebb0e54fe862fb5d77f8a00">Identiconpp</a>
|
||||
: <a class="el" href="classIdenticonpp.html#a55a4890677c963f24b89bd2aef906f1b">Identiconpp</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
@ -43,8 +43,11 @@ $(function() {
|
|||
<li>generate()
|
||||
: <a class="el" href="classIdenticonpp.html#a82f624d713e2d32d5fdb26b9112b821a">Identiconpp</a>
|
||||
</li>
|
||||
<li>generate_base64()
|
||||
: <a class="el" href="classIdenticonpp.html#ac4c9752b03d6e0a7c7950aee0637a82b">Identiconpp</a>
|
||||
</li>
|
||||
<li>Identiconpp()
|
||||
: <a class="el" href="classIdenticonpp.html#ad87f4b0b3ebb0e54fe862fb5d77f8a00">Identiconpp</a>
|
||||
: <a class="el" href="classIdenticonpp.html#a55a4890677c963f24b89bd2aef906f1b">Identiconpp</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -19,7 +19,7 @@
|
|||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">identiconpp
|
||||
 <span id="projectnumber">0.4.0</span>
|
||||
 <span id="projectnumber">0.6.0</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
@ -70,7 +70,7 @@ $(function() {
|
|||
<p>You need to generate hashes yourself, any hexadecimal string will do. Make sure to use a safe hashing algorithm for sensitive data (<b>not MD5</b>). You can select as many columns and rows as you like, but make sure you have enough entropy. If something seems to be wrong, exceptions will be thrown.</p>
|
||||
<p>The "sigil" algorithm generates the same results as <a href="https://github.com/cupcake/sigil/">sigil</a> and <a href="https://github.com/azaghal/pydenticon/">pydenticon</a>.</p>
|
||||
<h3>Example</h3>
|
||||
<div class="fragment"><div class="line">{C++}</div><div class="line">// Compile with g++ $(Magick++-config --cppflags --ldflags) -lidenticonpp</div><div class="line">#include <identiconpp.hpp></div><div class="line">#include <Magick++/Image.h></div><div class="line"></div><div class="line">int main()</div><div class="line">{</div><div class="line"> Identiconpp identicon(5, 5, Identiconpp::algorithm::ltr_symmetric,</div><div class="line"> "ffffff80", { "800000ff" }, { 10, 10 });</div><div class="line"> Magick::Image img;</div><div class="line"> img = identicon.generate("55502f40dc8b7c769880b10874abc9d0", 200);</div><div class="line"> img.write("identicon.png");</div><div class="line">}</div></div><!-- fragment --><h3>C interface</h3>
|
||||
<div class="fragment"><div class="line">{C++}</div><div class="line">// Compile with g++ $(Magick++-config --cppflags --ldflags) -lidenticonpp</div><div class="line">#include <iostream></div><div class="line">#include <identiconpp.hpp></div><div class="line">#include <Magick++/Image.h></div><div class="line"></div><div class="line">int main()</div><div class="line">{</div><div class="line"> Identiconpp identicon(5, 5, Identiconpp::algorithm::ltr_symmetric,</div><div class="line"> "ffffff80", { "800000ff" }, { 10, 10 });</div><div class="line"> Magick::Image img;</div><div class="line"> img = identicon.generate("55502f40dc8b7c769880b10874abc9d0", 200);</div><div class="line"> img.write("identicon.png");</div><div class="line"></div><div class="line"> std::cout << identicon.generate_base64("png", "5550", 200) << std::endl;</div><div class="line">}</div></div><!-- fragment --><h3>C interface</h3>
|
||||
<p>This is somewhat experimental. Have a look at <a href="https://schlomp.space/tastytea/identiconpp/src/branch/master/example.c">example.c</a> and <a href="https://doc.schlomp.space/identiconpp/identiconpp__c_8h.html">identiconpp_c.h</a>.</p>
|
||||
<p>It seems to be impossible to use <code>Magick++</code> and <code>MagickWand</code> in the same library, so the images are returned as base64-encoded strings.</p>
|
||||
<h2>Install</h2>
|
||||
|
|
Loading…
Reference in New Issue