Changeset 2122


Ignore:
Timestamp:
Dec 6, 2007, 11:46:14 PM (12 years ago)
Author:
Sam Hocevar
Message:
  • Put serpentine Floyd-Steinberg in a separate subsection.
Location:
www/study
Files:
4 added
1 edited

Legend:

Unmodified
Added
Removed
  • www/study/part3.html

    r2027 r2122  
    7070</p>
    7171
    72 On the left is the result of the simple algorithm. The image on the right is
    73 a variant called <b>serpentine Floyd-Steinberg</b> which parses every odd line
    74 in reverse order (right to left). The results are very close to the original
    75 Floyd-Steinberg, but the method avoids artifacts in some corner cases: </p>
     72<p> The result of this algorithm is rather impressive even compared to the
     73best ordered dither results we could achieve: </p>
    7674
    7775<p style="text-align: center;">
     
    7977       class="inline" alt="Floyd-Steinberg error diffusion" />
    8078  <img src="grad3-1-1.png" width="32" height="256"
    81        class="inline" alt="Floyd-Steinberg error diffusion gradient" />
    82   <img src="out3-1-2.png" width="256" height="256"
    83        class="inline" alt="Floyd-Steinberg error diffusion" />
    84   <img src="grad3-1-2.png" width="32" height="256"
    8579       class="inline" alt="Floyd-Steinberg error diffusion gradient" />
    8680</p>
     
    202196-->
    203197
     198<h3> 3.3. Image parsing </h3>
     199
     200<p> While image parsing order does not matter with ordered dithering, it can
     201actually be crucial with error diffusion. The reason is that once a pixel has
     202been processed, standard error diffusion methods do not go back. </p>
     203
     204<p> The usual way to parse an image is one pixel after the other, following
     205their order in memory. When reaching the end of a line, we automatically jump
     206to the beginning of the next line: </p>
     207
     208<p style="text-align: center;">
     209  <img src="fig3-3-1.png" width="390" height="165"
     210       class="matrix" alt="Regular parsing" />
     211</p>
     212
     213<p> Changing the parsing order can help prevent the apparition of artifacts in
     214error diffusion algorithms. This is serpentine parsing, where every odd line is
     215parsed in reverse order (right to left): </p>
     216
     217<p style="text-align: center;">
     218  <img src="fig3-3-2.png" width="390" height="165"
     219       class="matrix" alt="Serpentine parsing" />
     220</p>
     221
     222<p> And here are the results of <b>serpentine Floyd-Steinberg</b>. Only a
     223very close look will show the differences with standard Floyd-Steinberg, but
     224a few of the artifacts did disappear: </p>
     225
     226<p style="text-align: center;">
     227  <img src="out3-1-2.png" width="256" height="256"
     228       class="inline" alt="Floyd-Steinberg error diffusion" />
     229  <img src="grad3-1-2.png" width="32" height="256"
     230       class="inline" alt="Floyd-Steinberg error diffusion gradient" />
     231</p>
     232
    204233<div style="float: left;">
    205234   <a href="part2.html">Halftoning patterns &lt;&lt;&lt;</a>
Note: See TracChangeset for help on using the changeset viewer.