<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>AlbumShaper: blur.cpp File Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.6.2 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> </ul> </div> <div class="tabs"> <ul> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>File Members</span></a></li> </ul> </div> </div> <div class="contents"> <h1>blur.cpp File Reference</h1><code>#include <qimage.h></code><br/> <code>#include <qstring.h></code><br/> <code>#include <math.h></code><br/> <code>#include "<a class="el" href="blur_8h_source.html">blur.h</a>"</code><br/> <div class="dynheader"> Include dependency graph for blur.cpp:</div> <div class="dynsection"> </div> <p><a href="blur_8cpp_source.html">Go to the source code of this file.</a></p> <table border="0" cellpadding="0" cellspacing="0"> <tr><td colspan="2"><h2>Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a05a2bdd9a08d923f1cbb51fb3c82e87a">computeCoeffs</a> (float sigma)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a4f60299801c18dfeb6188d1905dc9753">fillBuffer</a> (QImage &image, int channel)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a94205af164693648b9082eefcbb9cdbc">blurBuffer</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a91fed80947f02fc86a923a68a37fd0c9">blurRow</a> (int row)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a7cf2d364e9c5bd5c66fee296c5b85784">blurColumn</a> (int column)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#ae2bd8758f167288d1f3f3be7cd77c4e3">blurRegionsInRow</a> (int y)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a5b070fddaaa81dc81a431ce9741a5fc8">blurRegionsInCol</a> (int x)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a7fbca6e5494a3008dd90ec0d6103bba0">resetImageData</a> (QImage &image, int channel, bool blurEdges)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a374c077a12cb98c0a52723b460079ae9">edgeValue</a> (int x, int y)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#ae7be57816a66918a26e567655f4b8e1c">blurImage</a> (QImage &image, float sigma)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#ae42c06320d849e8fca2912fa5dd38eed">blurImage</a> (QImage &image, float sigma, QPoint offset, QSize fullImageRes, QImage *edges, int *regions, int numRegions, bool targetEdges)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a66793d4213f628c343f1b318e1026b73">regionIndex</a> (int x, int y)</td></tr> <tr><td colspan="2"><h2>Variables</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a0a19a0620af7373e3ddba0ce4e1058e1">q</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float * </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float * </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float * </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float * </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">float * </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">QImage * </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int * </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#a99011823ef56f33be976af30f313f132">regionCount</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">QPoint </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#ab9f240ebcd7065350a7b041439db28ab">displayOffset</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">QSize </td><td class="memItemRight" valign="bottom"><a class="el" href="blur_8cpp.html#ab903d24dabd249aee4c0d5335f332d02">fullRes</a></td></tr> </table> <hr/><h2>Function Documentation</h2> <a class="anchor" id="a94205af164693648b9082eefcbb9cdbc"></a><!-- doxytag: member="blur.cpp::blurBuffer" ref="a94205af164693648b9082eefcbb9cdbc" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void blurBuffer </td> <td>(</td> <td class="paramname"></td> <td> ) </td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00204">204</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>, <a class="el" href="blur_8cpp_source.html#l00087">edgeImage</a>, <a class="el" href="blur_8cpp_source.html#l00079">height</a>, <a class="el" href="blur_8cpp_source.html#l00088">regionMap</a>, and <a class="el" href="blur_8cpp_source.html#l00079">width</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00205"></a>00205 { <a name="l00206"></a>00206 <span class="comment">//blur rows, then columns</span> <a name="l00207"></a>00207 <span class="keywordtype">int</span> index; <a name="l00208"></a>00208 <a name="l00209"></a>00209 <span class="keywordflow">if</span>(<a class="code" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a> == NULL || <a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a> == NULL ) <a name="l00210"></a>00210 { <a name="l00211"></a>00211 <span class="keywordflow">for</span>(index=0; index < <a class="code" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a>; index++) <a name="l00212"></a>00212 { <a class="code" href="blur_8cpp.html#a91fed80947f02fc86a923a68a37fd0c9">blurRow</a>( index ); } <a name="l00213"></a>00213 <a name="l00214"></a>00214 <span class="keywordflow">for</span>(index=0; index< <a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>; index++) <a name="l00215"></a>00215 { <a class="code" href="blur_8cpp.html#a7cf2d364e9c5bd5c66fee296c5b85784">blurColumn</a>( index ); } <a name="l00216"></a>00216 } <a name="l00217"></a>00217 <span class="keywordflow">else</span> <a name="l00218"></a>00218 { <a name="l00219"></a>00219 <span class="keywordflow">for</span>(index=0; index < height; index++) <a name="l00220"></a>00220 { <a class="code" href="blur_8cpp.html#ae2bd8758f167288d1f3f3be7cd77c4e3">blurRegionsInRow</a>( index ); } <a name="l00221"></a>00221 <a name="l00222"></a>00222 <span class="keywordflow">for</span>(index=0; index< <a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>; index++) <a name="l00223"></a>00223 { <a class="code" href="blur_8cpp.html#a5b070fddaaa81dc81a431ce9741a5fc8">blurRegionsInCol</a>( index ); } <a name="l00224"></a>00224 } <a name="l00225"></a>00225 } </pre></div></p> </div> </div> <a class="anchor" id="a7cf2d364e9c5bd5c66fee296c5b85784"></a><!-- doxytag: member="blur.cpp::blurColumn" ref="a7cf2d364e9c5bd5c66fee296c5b85784" args="(int column)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void blurColumn </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"> <em>column</em></td> <td> ) </td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00409">409</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00078">B</a>, <a class="el" href="blur_8cpp_source.html#l00078">b0</a>, <a class="el" href="blur_8cpp_source.html#l00078">b1</a>, <a class="el" href="blur_8cpp_source.html#l00078">b2</a>, <a class="el" href="blur_8cpp_source.html#l00078">b3</a>, <a class="el" href="blur_8cpp_source.html#l00080">buffer</a>, <a class="el" href="blur_8cpp_source.html#l00082">colBuffer</a>, <a class="el" href="blur_8cpp_source.html#l00079">height</a>, and <a class="el" href="blur_8cpp_source.html#l00079">width</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00410"></a>00410 { <a name="l00411"></a>00411 <span class="keywordtype">int</span> i; <a name="l00412"></a>00412 <a name="l00413"></a>00413 <span class="comment">//forward</span> <a name="l00414"></a>00414 <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[0] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ column + 0*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> ]; <a name="l00415"></a>00415 <span class="keywordflow">for</span>(i=1; i<<a class="code" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a>; i++) <a name="l00416"></a>00416 { <a name="l00417"></a>00417 <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[i] = <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a>*<a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ column + i*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> ] + <a name="l00418"></a>00418 ( <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a> * <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[ QMAX(i-1, 0) ] + <a name="l00419"></a>00419 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> * <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[ QMAX(i-2, 0) ] + <a name="l00420"></a>00420 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> * <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[ QMAX(i-3, 0) ]) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>; <a name="l00421"></a>00421 } <a name="l00422"></a>00422 <a name="l00423"></a>00423 <span class="comment">//reverse</span> <a name="l00424"></a>00424 <span class="keywordflow">for</span>(i=height-1; i>=0; i--) <a name="l00425"></a>00425 { <a name="l00426"></a>00426 <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ column + i*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> ] = <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a>*<a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[ i ] + <a name="l00427"></a>00427 ( <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a> * <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ column + QMIN(i+1, height-1)*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> ] + <a name="l00428"></a>00428 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> * <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ column + QMIN(i+2, height-1)*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> ] + <a name="l00429"></a>00429 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> * <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ column + QMIN(i+3, height-1)*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> ]) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>; <a name="l00430"></a>00430 } <a name="l00431"></a>00431 <a name="l00432"></a>00432 } </pre></div></p> </div> </div> <a class="anchor" id="ae42c06320d849e8fca2912fa5dd38eed"></a><!-- doxytag: member="blur.cpp::blurImage" ref="ae42c06320d849e8fca2912fa5dd38eed" args="(QImage &image, float sigma, QPoint offset, QSize fullImageRes, QImage *edges, int *regions, int numRegions, bool targetEdges)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void blurImage </td> <td>(</td> <td class="paramtype">QImage & </td> <td class="paramname"> <em>image</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">float </td> <td class="paramname"> <em>sigma</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">QPoint </td> <td class="paramname"> <em>offset</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">QSize </td> <td class="paramname"> <em>fullImageRes</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">QImage * </td> <td class="paramname"> <em>edges</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int * </td> <td class="paramname"> <em>regions</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>numRegions</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">bool </td> <td class="paramname"> <em>targetEdges</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00101">101</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>, <a class="el" href="blur_8cpp_source.html#l00080">buffer</a>, <a class="el" href="blur_8cpp_source.html#l00082">colBuffer</a>, <a class="el" href="blur_8cpp_source.html#l00150">computeCoeffs()</a>, <a class="el" href="blur_8cpp_source.html#l00090">displayOffset</a>, <a class="el" href="blur_8cpp_source.html#l00087">edgeImage</a>, <a class="el" href="blur_8cpp_source.html#l00172">fillBuffer()</a>, <a class="el" href="blur_8cpp_source.html#l00091">fullRes</a>, <a class="el" href="blur_8cpp_source.html#l00079">height</a>, <a class="el" href="blur_8cpp_source.html#l00085">regionColBuffer</a>, <a class="el" href="blur_8cpp_source.html#l00089">regionCount</a>, <a class="el" href="blur_8cpp_source.html#l00088">regionMap</a>, <a class="el" href="blur_8cpp_source.html#l00084">regionRowBuffer</a>, <a class="el" href="blur_8cpp_source.html#l00527">resetImageData()</a>, <a class="el" href="blur_8cpp_source.html#l00081">rowBuffer</a>, and <a class="el" href="blur_8cpp_source.html#l00079">width</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00105"></a>00105 { <a name="l00106"></a>00106 <a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a> = edges; <a name="l00107"></a>00107 <a class="code" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a> = regions; <a name="l00108"></a>00108 <a class="code" href="blur_8cpp.html#a99011823ef56f33be976af30f313f132">regionCount</a> = numRegions; <a name="l00109"></a>00109 <a class="code" href="blur_8cpp.html#ab9f240ebcd7065350a7b041439db28ab">displayOffset</a> = offset; <a name="l00110"></a>00110 <a class="code" href="blur_8cpp.html#ab903d24dabd249aee4c0d5335f332d02">fullRes</a> = fullImageRes; <a name="l00111"></a>00111 <a name="l00112"></a>00112 <span class="comment">//compute blurring coeffecients</span> <a name="l00113"></a>00113 <a class="code" href="blur_8cpp.html#a05a2bdd9a08d923f1cbb51fb3c82e87a">computeCoeffs</a>(sigma); <a name="l00114"></a>00114 <a name="l00115"></a>00115 <span class="comment">//store image dimensions</span> <a name="l00116"></a>00116 <a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> = image.width(); <a name="l00117"></a>00117 <a class="code" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a> = image.height(); <a name="l00118"></a>00118 <a name="l00119"></a>00119 <span class="comment">//Construct float buffer that is the size of the image/</span> <a name="l00120"></a>00120 <span class="comment">//In order to conserve memory process image three times, once for</span> <a name="l00121"></a>00121 <span class="comment">//each color channel.</span> <a name="l00122"></a>00122 <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a> = <span class="keyword">new</span> <span class="keywordtype">float</span>[ <a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> * <a class="code" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a> ]; <a name="l00123"></a>00123 <a name="l00124"></a>00124 <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a> = <span class="keyword">new</span> <span class="keywordtype">float</span>[<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>]; <a name="l00125"></a>00125 <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a> = <span class="keyword">new</span> <span class="keywordtype">float</span>[<a class="code" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a>]; <a name="l00126"></a>00126 <a name="l00127"></a>00127 <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a> = <span class="keyword">new</span> <span class="keywordtype">float</span>[<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a> * numRegions]; <a name="l00128"></a>00128 <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a> = <span class="keyword">new</span> <span class="keywordtype">float</span>[<a class="code" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a> * numRegions]; <a name="l00129"></a>00129 <a name="l00130"></a>00130 <span class="comment">//iterate over each color channel</span> <a name="l00131"></a>00131 <span class="keywordtype">int</span> channel; <a name="l00132"></a>00132 <span class="keywordflow">for</span>( channel = 0; channel <=2; channel++) <a name="l00133"></a>00133 { <a name="l00134"></a>00134 <span class="comment">//copy color data into float buffer</span> <a name="l00135"></a>00135 <a class="code" href="blur_8cpp.html#a4f60299801c18dfeb6188d1905dc9753">fillBuffer</a>( image, channel ); <a name="l00136"></a>00136 <a name="l00137"></a>00137 <span class="comment">//blur buffer data</span> <a name="l00138"></a>00138 <a class="code" href="blur_8cpp.html#a94205af164693648b9082eefcbb9cdbc">blurBuffer</a>(); <a name="l00139"></a>00139 <a name="l00140"></a>00140 <span class="comment">//reset image data used blurred buffer</span> <a name="l00141"></a>00141 <a class="code" href="blur_8cpp.html#a7fbca6e5494a3008dd90ec0d6103bba0">resetImageData</a>(image, channel, targetEdges); <a name="l00142"></a>00142 } <a name="l00143"></a>00143 <a name="l00144"></a>00144 <span class="comment">//delete buffer</span> <a name="l00145"></a>00145 <span class="keyword">delete</span>[] <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>; <a name="l00146"></a>00146 <span class="keyword">delete</span>[] <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>; <a name="l00147"></a>00147 <span class="keyword">delete</span>[] <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>; <a name="l00148"></a>00148 } </pre></div></p> </div> </div> <a class="anchor" id="ae7be57816a66918a26e567655f4b8e1c"></a><!-- doxytag: member="blur.cpp::blurImage" ref="ae7be57816a66918a26e567655f4b8e1c" args="(QImage &image, float sigma)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void blurImage </td> <td>(</td> <td class="paramtype">QImage & </td> <td class="paramname"> <em>image</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">float </td> <td class="paramname"> <em>sigma</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00094">94</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00094">blurImage()</a>.</p> <p>Referenced by <a class="el" href="grainEditor_8cpp_source.html#l00262">GrainEditor::adjustImage()</a>, <a class="el" href="blur_8cpp_source.html#l00094">blurImage()</a>, <a class="el" href="edgeDetect_8cpp_source.html#l00859">EdgeDetect::constructEdgeImage()</a>, and <a class="el" href="sharpen_8cpp_source.html#l00092">sharpenImage()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00095"></a>00095 { <a name="l00096"></a>00096 <span class="comment">//supply dummy data for edges, notably NULL for the edge image pointer.</span> <a name="l00097"></a>00097 <span class="comment">//other values have no effect</span> <a name="l00098"></a>00098 <a class="code" href="blur_8cpp.html#ae7be57816a66918a26e567655f4b8e1c">blurImage</a>( image, sigma, QPoint(0,0), image.size(), NULL, NULL, 0, false ); <a name="l00099"></a>00099 } </pre></div></p> </div> </div> <a class="anchor" id="a5b070fddaaa81dc81a431ce9741a5fc8"></a><!-- doxytag: member="blur.cpp::blurRegionsInCol" ref="a5b070fddaaa81dc81a431ce9741a5fc8" args="(int x)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void blurRegionsInCol </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"> <em>x</em></td> <td> ) </td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00434">434</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00078">B</a>, <a class="el" href="blur_8cpp_source.html#l00078">b0</a>, <a class="el" href="blur_8cpp_source.html#l00078">b1</a>, <a class="el" href="blur_8cpp_source.html#l00078">b2</a>, <a class="el" href="blur_8cpp_source.html#l00078">b3</a>, <a class="el" href="blur_8cpp_source.html#l00080">buffer</a>, <a class="el" href="blur_8cpp_source.html#l00082">colBuffer</a>, <a class="el" href="blur_8cpp_source.html#l00079">height</a>, <a class="el" href="blur_8cpp_source.html#l00085">regionColBuffer</a>, <a class="el" href="blur_8cpp_source.html#l00089">regionCount</a>, <a class="el" href="blur_8cpp_source.html#l00227">regionIndex()</a>, <a class="el" href="blur_8cpp_source.html#l00088">regionMap</a>, and <a class="el" href="blur_8cpp_source.html#l00079">width</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00435"></a>00435 { <a name="l00436"></a>00436 <span class="comment">//---------------------------------</span> <a name="l00437"></a>00437 <span class="comment">//populate region col buffer. a col has been allocated for </span> <a name="l00438"></a>00438 <span class="comment">//each region. Pixels between regions</span> <a name="l00439"></a>00439 <span class="comment">//take the closest pixel value in that col from that region</span> <a name="l00440"></a>00440 <span class="comment">// int yTimesWidth = y*width;</span> <a name="l00441"></a>00441 <span class="keywordtype">int</span> regionTimesHeight; <a name="l00442"></a>00442 <span class="keywordtype">int</span> region,y,y2; <a name="l00443"></a>00443 <a name="l00444"></a>00444 <span class="comment">//for each region</span> <a name="l00445"></a>00445 <span class="keywordflow">for</span>(region=0; region<<a class="code" href="blur_8cpp.html#a99011823ef56f33be976af30f313f132">regionCount</a>; region++) <a name="l00446"></a>00446 { <a name="l00447"></a>00447 regionTimesHeight = region*<a class="code" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a>; <a name="l00448"></a>00448 <span class="keywordtype">int</span> lastY = -1; <a name="l00449"></a>00449 <span class="keywordflow">for</span>(y=0; y<height; y++) <a name="l00450"></a>00450 { <a name="l00451"></a>00451 <span class="comment">//if pixel belongs to this region then update lastY index and copy value over</span> <a name="l00452"></a>00452 <span class="comment">//if lastY is more than one pixel away than fill inbetween region</span> <a name="l00453"></a>00453 <span class="keywordflow">if</span>( region == <a class="code" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a>[<a class="code" href="blur_8cpp.html#a66793d4213f628c343f1b318e1026b73">regionIndex</a>(x, y)] ) <a name="l00454"></a>00454 { <a name="l00455"></a>00455 <span class="comment">//fill empty region preceeding this region blob</span> <a name="l00456"></a>00456 <span class="keywordflow">if</span>( lastY < y-1) <a name="l00457"></a>00457 { <a name="l00458"></a>00458 <span class="comment">//no preceeding region, spread left!</span> <a name="l00459"></a>00459 <span class="keywordflow">if</span>(lastY == -1) <a name="l00460"></a>00460 { <a name="l00461"></a>00461 <span class="keywordflow">for</span>(y2=0; y2<y; y2++) { <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[y2 + regionTimesHeight] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + y*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>]; } <a name="l00462"></a>00462 } <a name="l00463"></a>00463 <span class="comment">//else spread from both left and right of empty stretch</span> <a name="l00464"></a>00464 <span class="keywordflow">else</span> <a name="l00465"></a>00465 { <a name="l00466"></a>00466 <span class="keywordtype">int</span> yMid = lastY + ((y-1) - lastY)/2; <a name="l00467"></a>00467 <a name="l00468"></a>00468 <span class="keywordflow">for</span>(y2=lastY+1; y2<=yMid; y2++) <a name="l00469"></a>00469 { <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[y2 + regionTimesHeight] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + lastY*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>]; } <a name="l00470"></a>00470 <a name="l00471"></a>00471 <span class="keywordflow">for</span>(y2=yMid+1; y2<y; y2++) <a name="l00472"></a>00472 { <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[y2 + regionTimesHeight] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + y*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>]; } <a name="l00473"></a>00473 } <a name="l00474"></a>00474 } <a name="l00475"></a>00475 <a name="l00476"></a>00476 <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[y + regionTimesHeight] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + y*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>]; <a name="l00477"></a>00477 lastY = y; <a name="l00478"></a>00478 } <a name="l00479"></a>00479 } <span class="comment">//y</span> <a name="l00480"></a>00480 <a name="l00481"></a>00481 <span class="comment">//if last stretch is empty, fill right</span> <a name="l00482"></a>00482 <span class="keywordflow">if</span>( region != <a class="code" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a>[<a class="code" href="blur_8cpp.html#a66793d4213f628c343f1b318e1026b73">regionIndex</a>(x, height-1)] ) <a name="l00483"></a>00483 { <a name="l00484"></a>00484 <span class="keywordflow">for</span>(y2=lastY+1; y2<height; y2++) <a name="l00485"></a>00485 { <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[y2 + regionTimesHeight] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + lastY*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>]; } <a name="l00486"></a>00486 } <a name="l00487"></a>00487 <a name="l00488"></a>00488 } <span class="comment">//region</span> <a name="l00489"></a>00489 <span class="comment">//---------------------------------</span> <a name="l00490"></a>00490 <span class="comment">//blur the region col buffers</span> <a name="l00491"></a>00491 <a name="l00492"></a>00492 <span class="comment">//for each region</span> <a name="l00493"></a>00493 <span class="keywordflow">for</span>(region=0; region<regionCount; region++) <a name="l00494"></a>00494 { <a name="l00495"></a>00495 regionTimesHeight = region*height; <a name="l00496"></a>00496 <a name="l00497"></a>00497 <span class="comment">//forward</span> <a name="l00498"></a>00498 <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[0] = <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[ 0 + regionTimesHeight ]; <a name="l00499"></a>00499 <span class="keywordflow">for</span>(y=1; y<height; y++) <a name="l00500"></a>00500 { <a name="l00501"></a>00501 <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[y] = <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a>*<a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[ y + regionTimesHeight ] + <a name="l00502"></a>00502 ( <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a> * <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[ QMAX(y-1, 0) ] + <a name="l00503"></a>00503 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> * <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[ QMAX(y-2, 0) ] + <a name="l00504"></a>00504 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> * <a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[ QMAX(y-3, 0) ]) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>; <a name="l00505"></a>00505 } <a name="l00506"></a>00506 <a name="l00507"></a>00507 <span class="comment">//reverse</span> <a name="l00508"></a>00508 <span class="keywordflow">for</span>(y=height-1; y>=0; y--) <a name="l00509"></a>00509 { <a name="l00510"></a>00510 <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[ y + regionTimesHeight ] = <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a>*<a class="code" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a>[ y ] + <a name="l00511"></a>00511 ( <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a> * <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[ QMIN(y+1, height-1) + regionTimesHeight ] + <a name="l00512"></a>00512 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> * <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[ QMIN(y+2, height-1) + regionTimesHeight ] + <a name="l00513"></a>00513 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> * <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[ QMIN(y+3, height-1) + regionTimesHeight ]) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>; <a name="l00514"></a>00514 } <a name="l00515"></a>00515 } <a name="l00516"></a>00516 <span class="comment">//---------------------------------</span> <a name="l00517"></a>00517 <span class="comment">//copy data from the region row buffers back to the</span> <a name="l00518"></a>00518 <span class="comment">//buffer. for each pixel we choose the correct region</span> <a name="l00519"></a>00519 <span class="comment">//row buffer basedon the original regionidentity of hte pixel</span> <a name="l00520"></a>00520 <span class="keywordflow">for</span>(y=0; y<height; y++) <a name="l00521"></a>00521 { <a name="l00522"></a>00522 <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + y*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>] = <a class="code" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a>[y + <a class="code" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a>[<a class="code" href="blur_8cpp.html#a66793d4213f628c343f1b318e1026b73">regionIndex</a>(x,y)]*height]; <a name="l00523"></a>00523 } <a name="l00524"></a>00524 <span class="comment">//---------------------------------</span> <a name="l00525"></a>00525 } </pre></div></p> </div> </div> <a class="anchor" id="ae2bd8758f167288d1f3f3be7cd77c4e3"></a><!-- doxytag: member="blur.cpp::blurRegionsInRow" ref="ae2bd8758f167288d1f3f3be7cd77c4e3" args="(int y)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void blurRegionsInRow </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"> <em>y</em></td> <td> ) </td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00311">311</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00078">B</a>, <a class="el" href="blur_8cpp_source.html#l00078">b0</a>, <a class="el" href="blur_8cpp_source.html#l00078">b1</a>, <a class="el" href="blur_8cpp_source.html#l00078">b2</a>, <a class="el" href="blur_8cpp_source.html#l00078">b3</a>, <a class="el" href="blur_8cpp_source.html#l00080">buffer</a>, <a class="el" href="blur_8cpp_source.html#l00089">regionCount</a>, <a class="el" href="blur_8cpp_source.html#l00227">regionIndex()</a>, <a class="el" href="blur_8cpp_source.html#l00088">regionMap</a>, <a class="el" href="blur_8cpp_source.html#l00084">regionRowBuffer</a>, <a class="el" href="blur_8cpp_source.html#l00081">rowBuffer</a>, and <a class="el" href="blur_8cpp_source.html#l00079">width</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00312"></a>00312 { <a name="l00313"></a>00313 <span class="comment">//---------------------------------</span> <a name="l00314"></a>00314 <span class="comment">//populate region row buffer. a row has been allocated for </span> <a name="l00315"></a>00315 <span class="comment">//each region. Pixels between regions</span> <a name="l00316"></a>00316 <span class="comment">//take the closest pixel value in that row from that region</span> <a name="l00317"></a>00317 <span class="keywordtype">int</span> yTimesWidth = y*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>; <a name="l00318"></a>00318 <span class="keywordtype">int</span> regionTimesWidth; <a name="l00319"></a>00319 <span class="keywordtype">int</span> region,x,x2; <a name="l00320"></a>00320 <a name="l00321"></a>00321 <span class="comment">//for each region</span> <a name="l00322"></a>00322 <span class="keywordflow">for</span>(region=0; region<<a class="code" href="blur_8cpp.html#a99011823ef56f33be976af30f313f132">regionCount</a>; region++) <a name="l00323"></a>00323 { <a name="l00324"></a>00324 regionTimesWidth = region*width; <a name="l00325"></a>00325 <span class="keywordtype">int</span> lastX = -1; <a name="l00326"></a>00326 <span class="keywordflow">for</span>(x=0; x<width; x++) <a name="l00327"></a>00327 { <a name="l00328"></a>00328 <span class="comment">//if pixel belongs to this region then update lastX index and copy value over</span> <a name="l00329"></a>00329 <span class="comment">//if lastX is mroe than one pixel away than fill inbetween region</span> <a name="l00330"></a>00330 <span class="keywordflow">if</span>( region == <a class="code" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a>[<a class="code" href="blur_8cpp.html#a66793d4213f628c343f1b318e1026b73">regionIndex</a>(x, y)] ) <a name="l00331"></a>00331 { <a name="l00332"></a>00332 <span class="comment">//fill empty region preceeding this region blob</span> <a name="l00333"></a>00333 <span class="keywordflow">if</span>( lastX < x-1) <a name="l00334"></a>00334 { <a name="l00335"></a>00335 <span class="comment">//no preceeding region, spread left!</span> <a name="l00336"></a>00336 <span class="keywordflow">if</span>(lastX == -1) <a name="l00337"></a>00337 { <a name="l00338"></a>00338 <span class="keywordflow">for</span>(x2=0; x2<x; x2++) { <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[x2 + regionTimesWidth] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + yTimesWidth]; } <a name="l00339"></a>00339 } <a name="l00340"></a>00340 <span class="comment">//else spread from both left and right of empty stretch</span> <a name="l00341"></a>00341 <span class="keywordflow">else</span> <a name="l00342"></a>00342 { <a name="l00343"></a>00343 <span class="keywordtype">int</span> xMid = lastX + ((x-1) - lastX)/2; <a name="l00344"></a>00344 <a name="l00345"></a>00345 <span class="keywordflow">for</span>(x2=lastX+1; x2<=xMid; x2++) <a name="l00346"></a>00346 { <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[x2 + regionTimesWidth] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[lastX + yTimesWidth]; } <a name="l00347"></a>00347 <a name="l00348"></a>00348 <span class="keywordflow">for</span>(x2=xMid+1; x2<x; x2++) <a name="l00349"></a>00349 { <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[x2 + regionTimesWidth] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + yTimesWidth]; } <a name="l00350"></a>00350 } <a name="l00351"></a>00351 } <a name="l00352"></a>00352 <a name="l00353"></a>00353 <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[x + regionTimesWidth] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + yTimesWidth]; <a name="l00354"></a>00354 lastX = x; <a name="l00355"></a>00355 } <a name="l00356"></a>00356 } <span class="comment">//x</span> <a name="l00357"></a>00357 <a name="l00358"></a>00358 <span class="comment">//if last stretch is empty, fill right</span> <a name="l00359"></a>00359 <span class="keywordflow">if</span>( region != <a class="code" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a>[<a class="code" href="blur_8cpp.html#a66793d4213f628c343f1b318e1026b73">regionIndex</a>(width-1, y)] ) <a name="l00360"></a>00360 { <a name="l00361"></a>00361 <span class="keywordflow">for</span>(x2=lastX+1; x2<width; x2++) <a name="l00362"></a>00362 { <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[x2 + regionTimesWidth] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[lastX + yTimesWidth]; } <a name="l00363"></a>00363 } <a name="l00364"></a>00364 <a name="l00365"></a>00365 } <span class="comment">//region</span> <a name="l00366"></a>00366 <span class="comment">//---------------------------------</span> <a name="l00367"></a>00367 <span class="comment">//blur the region row buffers</span> <a name="l00368"></a>00368 <a name="l00369"></a>00369 <span class="comment">//for each region</span> <a name="l00370"></a>00370 <span class="keywordflow">for</span>(region=0; region<regionCount; region++) <a name="l00371"></a>00371 { <a name="l00372"></a>00372 regionTimesWidth = region*width; <a name="l00373"></a>00373 <a name="l00374"></a>00374 <span class="comment">//forward</span> <a name="l00375"></a>00375 <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[0] = <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[ 0 + regionTimesWidth ]; <a name="l00376"></a>00376 <span class="keywordflow">for</span>(x=1; x<width; x++) <a name="l00377"></a>00377 { <a name="l00378"></a>00378 <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[x] = <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a>*<a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[ x + regionTimesWidth ] + <a name="l00379"></a>00379 ( <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a>*<a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[ QMAX(x-1, 0) ] + <a name="l00380"></a>00380 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> * <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[ QMAX(x-2, 0) ] + <a name="l00381"></a>00381 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> * <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[ QMAX(x-3, 0) ]) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>; <a name="l00382"></a>00382 } <a name="l00383"></a>00383 <a name="l00384"></a>00384 <span class="comment">//reverse</span> <a name="l00385"></a>00385 <span class="keywordflow">for</span>(x=width-1; x>=0; x--) <a name="l00386"></a>00386 { <a name="l00387"></a>00387 <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[ x + regionTimesWidth ] = <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a>*<a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[ x ] + <a name="l00388"></a>00388 ( <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a> * <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[ QMIN(x+1, width-1) + regionTimesWidth ] + <a name="l00389"></a>00389 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> * <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[ QMIN(x+2, width-1) + regionTimesWidth ] + <a name="l00390"></a>00390 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> * <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[ QMIN(x+3, width-1) + regionTimesWidth ]) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>; <a name="l00391"></a>00391 } <a name="l00392"></a>00392 } <a name="l00393"></a>00393 <span class="comment">//---------------------------------</span> <a name="l00394"></a>00394 <span class="comment">//copy data from the region row buffers back to the</span> <a name="l00395"></a>00395 <span class="comment">//buffer. for each pixel we choose the correct region</span> <a name="l00396"></a>00396 <span class="comment">//row buffer basedon the original regionidentity of hte pixel</span> <a name="l00397"></a>00397 <span class="keywordflow">for</span>(x=0; x<width; x++) <a name="l00398"></a>00398 { <a name="l00399"></a>00399 <span class="keywordtype">int</span> ri = <a class="code" href="blur_8cpp.html#a66793d4213f628c343f1b318e1026b73">regionIndex</a>(x,y); <a name="l00400"></a>00400 <span class="keywordtype">int</span> region = <a class="code" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a>[ri]; <a name="l00401"></a>00401 <span class="keywordtype">float</span> bufferVal = <a class="code" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a>[ x + region*width ]; <a name="l00402"></a>00402 <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[x + yTimesWidth] = bufferVal; <a name="l00403"></a>00403 <a name="l00404"></a>00404 <span class="comment">// buffer[x + yTimesWidth] = regionRowBuffer[x + regionMap[regionIndex(x,y)]*width]; </span> <a name="l00405"></a>00405 } <a name="l00406"></a>00406 <span class="comment">//---------------------------------</span> <a name="l00407"></a>00407 } </pre></div></p> </div> </div> <a class="anchor" id="a91fed80947f02fc86a923a68a37fd0c9"></a><!-- doxytag: member="blur.cpp::blurRow" ref="a91fed80947f02fc86a923a68a37fd0c9" args="(int row)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void blurRow </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"> <em>row</em></td> <td> ) </td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00285">285</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00078">B</a>, <a class="el" href="blur_8cpp_source.html#l00078">b0</a>, <a class="el" href="blur_8cpp_source.html#l00078">b1</a>, <a class="el" href="blur_8cpp_source.html#l00078">b2</a>, <a class="el" href="blur_8cpp_source.html#l00078">b3</a>, <a class="el" href="blur_8cpp_source.html#l00080">buffer</a>, <a class="el" href="blur_8cpp_source.html#l00081">rowBuffer</a>, and <a class="el" href="blur_8cpp_source.html#l00079">width</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00286"></a>00286 { <a name="l00287"></a>00287 <span class="keywordtype">int</span> i; <a name="l00288"></a>00288 <span class="keywordtype">int</span> rtw = row*<a class="code" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a>; <a name="l00289"></a>00289 <a name="l00290"></a>00290 <span class="comment">//forward</span> <a name="l00291"></a>00291 <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[0] = <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ 0 + rtw ]; <a name="l00292"></a>00292 <span class="keywordflow">for</span>(i=1; i<width; i++) <a name="l00293"></a>00293 { <a name="l00294"></a>00294 <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[i] = <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a>*<a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ i + rtw ] + <a name="l00295"></a>00295 ( <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a>*<a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[ QMAX(i-1, 0) ] + <a name="l00296"></a>00296 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> * <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[ QMAX(i-2, 0) ] + <a name="l00297"></a>00297 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> * <a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[ QMAX(i-3, 0) ]) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>; <a name="l00298"></a>00298 <a name="l00299"></a>00299 } <a name="l00300"></a>00300 <a name="l00301"></a>00301 <span class="comment">//reverse</span> <a name="l00302"></a>00302 <span class="keywordflow">for</span>(i=width-1; i>=0; i--) <a name="l00303"></a>00303 { <a name="l00304"></a>00304 <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ i + rtw ] = <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a>*<a class="code" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a>[ i ] + <a name="l00305"></a>00305 ( <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a> * <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ QMIN(i+1, width-1) + rtw ] + <a name="l00306"></a>00306 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> * <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ QMIN(i+2, width-1) + rtw ] + <a name="l00307"></a>00307 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> * <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[ QMIN(i+3, width-1) + rtw ]) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>; <a name="l00308"></a>00308 } <a name="l00309"></a>00309 } </pre></div></p> </div> </div> <a class="anchor" id="a05a2bdd9a08d923f1cbb51fb3c82e87a"></a><!-- doxytag: member="blur.cpp::computeCoeffs" ref="a05a2bdd9a08d923f1cbb51fb3c82e87a" args="(float sigma)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void computeCoeffs </td> <td>(</td> <td class="paramtype">float </td> <td class="paramname"> <em>sigma</em></td> <td> ) </td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00150">150</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00078">B</a>, <a class="el" href="blur_8cpp_source.html#l00078">b0</a>, <a class="el" href="blur_8cpp_source.html#l00078">b1</a>, <a class="el" href="blur_8cpp_source.html#l00078">b2</a>, <a class="el" href="blur_8cpp_source.html#l00078">b3</a>, and <a class="el" href="blur_8cpp_source.html#l00078">q</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00151"></a>00151 { <a name="l00152"></a>00152 <span class="comment">//compute q as a function of sigma</span> <a name="l00153"></a>00153 <span class="keywordflow">if</span>( sigma >= 2.5f ) <a name="l00154"></a>00154 { <a name="l00155"></a>00155 <a class="code" href="blur_8cpp.html#a0a19a0620af7373e3ddba0ce4e1058e1">q</a> = 0.98711f*sigma - 0.96330f; <a name="l00156"></a>00156 } <a name="l00157"></a>00157 <span class="keywordflow">else</span> <a name="l00158"></a>00158 { <a name="l00159"></a>00159 <a class="code" href="blur_8cpp.html#a0a19a0620af7373e3ddba0ce4e1058e1">q</a> = 3.97156f - 4.14554f * sqrt( 1.0f - 0.26891f*sigma ); <a name="l00160"></a>00160 } <a name="l00161"></a>00161 <a name="l00162"></a>00162 <span class="comment">//compute b0, b1, b2, and b3</span> <a name="l00163"></a>00163 <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a> = 1.57825f + (2.44413f*<a class="code" href="blur_8cpp.html#a0a19a0620af7373e3ddba0ce4e1058e1">q</a>) + (1.4281f * <a class="code" href="blur_8cpp.html#a0a19a0620af7373e3ddba0ce4e1058e1">q</a>*<a class="code" href="blur_8cpp.html#a0a19a0620af7373e3ddba0ce4e1058e1">q</a> ) + (0.422205f * q*q*q ); <a name="l00164"></a>00164 <a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a> = (2.44413f * q) + (2.85619f * q*q) + (1.26661 * q*q*q ); <a name="l00165"></a>00165 <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> = -((1.4281 * q*q) + (1.26661 * q*q*q)); <a name="l00166"></a>00166 <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a> = 0.422205 * q*q*q; <a name="l00167"></a>00167 <a name="l00168"></a>00168 <span class="comment">//compute B</span> <a name="l00169"></a>00169 <a class="code" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a> = 1.0f - ((<a class="code" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a> + <a class="code" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a> + <a class="code" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a>) / <a class="code" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a>); <a name="l00170"></a>00170 } </pre></div></p> </div> </div> <a class="anchor" id="a374c077a12cb98c0a52723b460079ae9"></a><!-- doxytag: member="blur.cpp::edgeValue" ref="a374c077a12cb98c0a52723b460079ae9" args="(int x, int y)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float edgeValue </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"> <em>x</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>y</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00234">234</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00090">displayOffset</a>, <a class="el" href="blur_8cpp_source.html#l00087">edgeImage</a>, and <a class="el" href="blur_8cpp_source.html#l00091">fullRes</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00527">resetImageData()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00235"></a>00235 { <a name="l00236"></a>00236 <span class="comment">//compute floating point x and y coordinates for edge image</span> <a name="l00237"></a>00237 <span class="keywordtype">float</span> edgeX = ((<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->width()-1.0f) * (x+<a class="code" href="blur_8cpp.html#ab9f240ebcd7065350a7b041439db28ab">displayOffset</a>.x())) / (<a class="code" href="blur_8cpp.html#ab903d24dabd249aee4c0d5335f332d02">fullRes</a>.width()-1); <a name="l00238"></a>00238 <span class="keywordtype">float</span> edgeY = ((<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->height()-1.0f) * (y+<a class="code" href="blur_8cpp.html#ab9f240ebcd7065350a7b041439db28ab">displayOffset</a>.y())) / (<a class="code" href="blur_8cpp.html#ab903d24dabd249aee4c0d5335f332d02">fullRes</a>.height()-1); <a name="l00239"></a>00239 <a name="l00240"></a>00240 <span class="comment">//compute 4 int values of coordinates</span> <a name="l00241"></a>00241 <span class="keywordtype">int</span> x1 = (int)edgeX; <a name="l00242"></a>00242 <span class="keywordtype">int</span> y1 = (int)edgeY; <a name="l00243"></a>00243 <span class="keywordtype">int</span> x2, y2; <a name="l00244"></a>00244 <span class="keywordflow">if</span>( edgeX > x1 ) <a name="l00245"></a>00245 x2 = x1+1; <a name="l00246"></a>00246 <span class="keywordflow">else</span> <a name="l00247"></a>00247 x2 = x1; <a name="l00248"></a>00248 <span class="keywordflow">if</span>( edgeY > y1 ) <a name="l00249"></a>00249 y2 = y1+1; <a name="l00250"></a>00250 <span class="keywordflow">else</span> <a name="l00251"></a>00251 y2 = y1; <a name="l00252"></a>00252 <a name="l00253"></a>00253 <span class="comment">//compute the four indices</span> <a name="l00254"></a>00254 <span class="keywordtype">int</span> index1, index2, index3, index4; <a name="l00255"></a>00255 index1 = x1 + y1*<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->width(); <a name="l00256"></a>00256 index2 = x2 + y1*<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->width(); <a name="l00257"></a>00257 index3 = x1 + y2*<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->width(); <a name="l00258"></a>00258 index4 = x2 + y2*<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->width(); <a name="l00259"></a>00259 <a name="l00260"></a>00260 <span class="comment">//find edge quantity for each corner</span> <a name="l00261"></a>00261 <span class="keywordtype">float</span> v1, v2, v3, v4; <a name="l00262"></a>00262 uchar* scanline = <a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->scanLine( y1 ); <a name="l00263"></a>00263 QRgb* rgb = ((QRgb*)scanline+x1); <a name="l00264"></a>00264 v1 = ((float) qRed( *rgb )) / 255.0f; <a name="l00265"></a>00265 rgb = ((QRgb*)scanline+x2); <a name="l00266"></a>00266 v2 = ((float) qRed( *rgb )) / 255.0f; <a name="l00267"></a>00267 <a name="l00268"></a>00268 scanline = <a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->scanLine( y2 ); <a name="l00269"></a>00269 rgb = ((QRgb*)scanline+x1); <a name="l00270"></a>00270 v3 = ((float) qRed( *rgb )) / 255.0f; <a name="l00271"></a>00271 rgb = ((QRgb*)scanline+x2); <a name="l00272"></a>00272 v4 = ((float) qRed( *rgb )) / 255.0f; <a name="l00273"></a>00273 <a name="l00274"></a>00274 <span class="comment">//blur combine left-right</span> <a name="l00275"></a>00275 v1 = (edgeX-x1)*v2 + (1 - edgeX + x1)*v1; <a name="l00276"></a>00276 v3 = (edgeX-x1)*v4 + (1 - edgeX + x1)*v3; <a name="l00277"></a>00277 <a name="l00278"></a>00278 <span class="comment">//combine top-bottom</span> <a name="l00279"></a>00279 v1 = (edgeY-y1)*v3 + (1 - edgeY + y1)*v1; <a name="l00280"></a>00280 <a name="l00281"></a>00281 <span class="comment">//return result</span> <a name="l00282"></a>00282 <span class="keywordflow">return</span> v1; <a name="l00283"></a>00283 } </pre></div></p> </div> </div> <a class="anchor" id="a4f60299801c18dfeb6188d1905dc9753"></a><!-- doxytag: member="blur.cpp::fillBuffer" ref="a4f60299801c18dfeb6188d1905dc9753" args="(QImage &image, int channel)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void fillBuffer </td> <td>(</td> <td class="paramtype">QImage & </td> <td class="paramname"> <em>image</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>channel</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00172">172</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00080">buffer</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00173"></a>00173 { <a name="l00174"></a>00174 <span class="comment">//precompute 1/255</span> <a name="l00175"></a>00175 <span class="keywordtype">float</span> multiplier = 1.0f / 255.0f; <a name="l00176"></a>00176 <a name="l00177"></a>00177 <span class="comment">//iterate over each selected scanline </span> <a name="l00178"></a>00178 <span class="keywordtype">int</span> x, y; <a name="l00179"></a>00179 QRgb* rgb; <a name="l00180"></a>00180 uchar* scanLine; <a name="l00181"></a>00181 <span class="keywordflow">for</span>( y=0; y<image.height(); y++) <a name="l00182"></a>00182 { <a name="l00183"></a>00183 <span class="comment">//iterate over each pixel in scanline</span> <a name="l00184"></a>00184 scanLine = image.scanLine(y); <a name="l00185"></a>00185 <span class="keywordflow">for</span>( x=0; x<image.width(); x++) <a name="l00186"></a>00186 { <a name="l00187"></a>00187 <span class="comment">//get handle on rgb value in image</span> <a name="l00188"></a>00188 rgb = ((QRgb*)scanLine+x); <a name="l00189"></a>00189 <a name="l00190"></a>00190 <span class="comment">//compute index where float value is stored in buffer</span> <a name="l00191"></a>00191 <span class="keywordtype">int</span> index = x + y*image.width(); <a name="l00192"></a>00192 <a name="l00193"></a>00193 <span class="comment">//convert and store correct channel in buffer</span> <a name="l00194"></a>00194 <span class="keywordflow">if</span>( channel == 0 ) <a name="l00195"></a>00195 <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[index] = multiplier * qRed( *rgb ); <a name="l00196"></a>00196 <span class="keywordflow">else</span> <span class="keywordflow">if</span>( channel == 1 ) <a name="l00197"></a>00197 <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[index] = multiplier * qGreen( *rgb ); <a name="l00198"></a>00198 <span class="keywordflow">else</span> <a name="l00199"></a>00199 <a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[index] = multiplier * qBlue( *rgb ); <a name="l00200"></a>00200 } <span class="comment">//x</span> <a name="l00201"></a>00201 } <span class="comment">//y</span> <a name="l00202"></a>00202 } </pre></div></p> </div> </div> <a class="anchor" id="a66793d4213f628c343f1b318e1026b73"></a><!-- doxytag: member="blur.cpp::regionIndex" ref="a66793d4213f628c343f1b318e1026b73" args="(int x, int y)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int regionIndex </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"> <em>x</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>y</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00227">227</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00090">displayOffset</a>, <a class="el" href="blur_8cpp_source.html#l00087">edgeImage</a>, and <a class="el" href="blur_8cpp_source.html#l00091">fullRes</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, and <a class="el" href="redEye_8cpp_source.html#l00561">IDedPixel()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00228"></a>00228 { <a name="l00229"></a>00229 <span class="keywordtype">int</span> edgeX = ((<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->width()-1) * (x+<a class="code" href="blur_8cpp.html#ab9f240ebcd7065350a7b041439db28ab">displayOffset</a>.x())) / (<a class="code" href="blur_8cpp.html#ab903d24dabd249aee4c0d5335f332d02">fullRes</a>.width()-1); <a name="l00230"></a>00230 <span class="keywordtype">int</span> edgeY = ((<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->height()-1) * (y+<a class="code" href="blur_8cpp.html#ab9f240ebcd7065350a7b041439db28ab">displayOffset</a>.y())) / (<a class="code" href="blur_8cpp.html#ab903d24dabd249aee4c0d5335f332d02">fullRes</a>.height()-1); <a name="l00231"></a>00231 <span class="keywordflow">return</span> edgeY*<a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a>->width() + edgeX; <a name="l00232"></a>00232 } </pre></div></p> </div> </div> <a class="anchor" id="a7fbca6e5494a3008dd90ec0d6103bba0"></a><!-- doxytag: member="blur.cpp::resetImageData" ref="a7fbca6e5494a3008dd90ec0d6103bba0" args="(QImage &image, int channel, bool blurEdges)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void resetImageData </td> <td>(</td> <td class="paramtype">QImage & </td> <td class="paramname"> <em>image</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>channel</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">bool </td> <td class="paramname"> <em>blurEdges</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00527">527</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>References <a class="el" href="blur_8cpp_source.html#l00080">buffer</a>, <a class="el" href="blur_8cpp_source.html#l00087">edgeImage</a>, and <a class="el" href="blur_8cpp_source.html#l00234">edgeValue()</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>.</p> <p><div class="fragment"><pre class="fragment"><a name="l00528"></a>00528 { <a name="l00529"></a>00529 <span class="comment">//iterate over each selected scanline </span> <a name="l00530"></a>00530 <span class="keywordtype">int</span> x, y; <a name="l00531"></a>00531 QRgb *rgb; <a name="l00532"></a>00532 uchar* imageScanline = NULL; <a name="l00533"></a>00533 <span class="keywordflow">for</span>( y=0; y<image.height(); y++) <a name="l00534"></a>00534 { <a name="l00535"></a>00535 imageScanline = image.scanLine(y); <a name="l00536"></a>00536 <span class="keywordflow">for</span>( x=0; x<image.width(); x++) <a name="l00537"></a>00537 { <a name="l00538"></a>00538 <span class="comment">//get handle on rgb value in image</span> <a name="l00539"></a>00539 rgb = ((QRgb*)imageScanline+x); <a name="l00540"></a>00540 <a name="l00541"></a>00541 <span class="comment">//compute index where float value is stored in buffer</span> <a name="l00542"></a>00542 <span class="keywordtype">int</span> index = x + y*image.width(); <a name="l00543"></a>00543 <a name="l00544"></a>00544 <span class="comment">//convert blured value to 0-255 range</span> <a name="l00545"></a>00545 <span class="keywordtype">int</span> blurredColor = QMAX( QMIN( ((<span class="keywordtype">int</span>) (255*<a class="code" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a>[index])), 255 ), 0 ); <a name="l00546"></a>00546 <a name="l00547"></a>00547 <span class="comment">//blur the entire thing!</span> <a name="l00548"></a>00548 <span class="keywordtype">float</span> alpha; <a name="l00549"></a>00549 <span class="keywordflow">if</span>( <a class="code" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a> == NULL) <a name="l00550"></a>00550 alpha = 1.0f; <a name="l00551"></a>00551 <span class="keywordflow">else</span> <a name="l00552"></a>00552 { <a name="l00553"></a>00553 alpha = <a class="code" href="blur_8cpp.html#a374c077a12cb98c0a52723b460079ae9">edgeValue</a>( x, y ); <a name="l00554"></a>00554 <span class="keywordflow">if</span>(!blurEdges) <a name="l00555"></a>00555 alpha = 1.0f - alpha; <a name="l00556"></a>00556 } <a name="l00557"></a>00557 <a name="l00558"></a>00558 <span class="comment">//convert and store correct channel in buffer</span> <a name="l00559"></a>00559 <span class="keywordflow">if</span>( channel == 0 ) <a name="l00560"></a>00560 *rgb = qRgb( (<span class="keywordtype">int</span>) (alpha*blurredColor + (1-alpha)*qRed(*rgb)), <a name="l00561"></a>00561 qGreen(*rgb), qBlue(*rgb) ); <a name="l00562"></a>00562 <span class="keywordflow">else</span> <span class="keywordflow">if</span>( channel == 1 ) <a name="l00563"></a>00563 *rgb = qRgb( qRed(*rgb), <a name="l00564"></a>00564 (<span class="keywordtype">int</span>) (alpha*blurredColor + (1-alpha)*qGreen(*rgb)), <a name="l00565"></a>00565 qBlue(*rgb) ); <a name="l00566"></a>00566 <span class="keywordflow">else</span> <a name="l00567"></a>00567 *rgb = qRgb( qRed(*rgb), qGreen(*rgb), <a name="l00568"></a>00568 (<span class="keywordtype">int</span>) (alpha*blurredColor + (1-alpha)*qBlue(*rgb)) ); <a name="l00569"></a>00569 } <span class="comment">//x</span> <a name="l00570"></a>00570 } <span class="comment">//y</span> <a name="l00571"></a>00571 } </pre></div></p> </div> </div> <hr/><h2>Variable Documentation</h2> <a class="anchor" id="a8188fea1f6709096fe21a3ee084d00d0"></a><!-- doxytag: member="blur.cpp::B" ref="a8188fea1f6709096fe21a3ee084d00d0" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float <a class="el" href="blur_8cpp.html#a8188fea1f6709096fe21a3ee084d00d0">B</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00078">78</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>, <a class="el" href="edgeDetect_8cpp_source.html#l00618">EdgeDetect::computeClusterThresholds()</a>, and <a class="el" href="blur_8cpp_source.html#l00150">computeCoeffs()</a>.</p> </div> </div> <a class="anchor" id="aae36fc890ea9532f56273eb4ff3d8fc3"></a><!-- doxytag: member="blur.cpp::b0" ref="aae36fc890ea9532f56273eb4ff3d8fc3" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float <a class="el" href="blur_8cpp.html#aae36fc890ea9532f56273eb4ff3d8fc3">b0</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00078">78</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>, and <a class="el" href="blur_8cpp_source.html#l00150">computeCoeffs()</a>.</p> </div> </div> <a class="anchor" id="a0a909289ec9fbfaa70c0e112ec9e3b15"></a><!-- doxytag: member="blur.cpp::b1" ref="a0a909289ec9fbfaa70c0e112ec9e3b15" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float <a class="el" href="blur_8cpp.html#a0a909289ec9fbfaa70c0e112ec9e3b15">b1</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00078">78</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>, <a class="el" href="blur_8cpp_source.html#l00150">computeCoeffs()</a>, and <a class="el" href="sharpen_8cpp_source.html#l00092">sharpenImage()</a>.</p> </div> </div> <a class="anchor" id="a746bcb222044619e5a9b335d242a2a92"></a><!-- doxytag: member="blur.cpp::b2" ref="a746bcb222044619e5a9b335d242a2a92" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float <a class="el" href="blur_8cpp.html#a746bcb222044619e5a9b335d242a2a92">b2</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00078">78</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>, <a class="el" href="blur_8cpp_source.html#l00150">computeCoeffs()</a>, and <a class="el" href="sharpen_8cpp_source.html#l00092">sharpenImage()</a>.</p> </div> </div> <a class="anchor" id="a9c6487b4db396a5910c351e126a2a3a6"></a><!-- doxytag: member="blur.cpp::b3" ref="a9c6487b4db396a5910c351e126a2a3a6" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float <a class="el" href="blur_8cpp.html#a9c6487b4db396a5910c351e126a2a3a6">b3</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00078">78</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>, and <a class="el" href="blur_8cpp_source.html#l00150">computeCoeffs()</a>.</p> </div> </div> <a class="anchor" id="afa761c0753ecc94346e155a39bd9ed9c"></a><!-- doxytag: member="blur.cpp::buffer" ref="afa761c0753ecc94346e155a39bd9ed9c" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float* <a class="el" href="blur_8cpp.html#afa761c0753ecc94346e155a39bd9ed9c">buffer</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00080">80</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>, <a class="el" href="fileTools_8cpp_source.html#l00061">copyFile()</a>, <a class="el" href="subalbumsIconView_8cpp_source.html#l00080">SubalbumsIconView::dragObject()</a>, <a class="el" href="blur_8cpp_source.html#l00172">fillBuffer()</a>, <a class="el" href="splitViewInterface_8cpp_source.html#l00058">SplitViewInterface::paintEvent()</a>, <a class="el" href="selectionPlacementInterface_8cpp_source.html#l00086">SelectionPlacementInterface::paintEvent()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00161">SelectionInterface::paintEvent()</a>, <a class="el" href="histogramInterface_8cpp_source.html#l00155">HistogramInterface::paintEvent()</a>, <a class="el" href="clickableLabel_8cpp_source.html#l00031">ClickableLabel::paintEvent()</a>, <a class="el" href="subalbumPreviewWidget_8cpp_source.html#l00059">SubalbumPreviewWidget::paintItem()</a>, <a class="el" href="photoPreviewWidget_8cpp_source.html#l00109">PhotoPreviewWidget::paintItem()</a>, and <a class="el" href="blur_8cpp_source.html#l00527">resetImageData()</a>.</p> </div> </div> <a class="anchor" id="aaec903fd4cc73f7ef5918cbe5ecfc1c1"></a><!-- doxytag: member="blur.cpp::colBuffer" ref="aaec903fd4cc73f7ef5918cbe5ecfc1c1" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float* <a class="el" href="blur_8cpp.html#aaec903fd4cc73f7ef5918cbe5ecfc1c1">colBuffer</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00082">82</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, and <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>.</p> </div> </div> <a class="anchor" id="ab9f240ebcd7065350a7b041439db28ab"></a><!-- doxytag: member="blur.cpp::displayOffset" ref="ab9f240ebcd7065350a7b041439db28ab" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">QPoint <a class="el" href="blur_8cpp.html#ab9f240ebcd7065350a7b041439db28ab">displayOffset</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00090">90</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00234">edgeValue()</a>, and <a class="el" href="blur_8cpp_source.html#l00227">regionIndex()</a>.</p> </div> </div> <a class="anchor" id="a8bb23dbf5a4b8bb7e3e90e0567712bdd"></a><!-- doxytag: member="blur.cpp::edgeImage" ref="a8bb23dbf5a4b8bb7e3e90e0567712bdd" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">QImage* <a class="el" href="blur_8cpp.html#a8bb23dbf5a4b8bb7e3e90e0567712bdd">edgeImage</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00087">87</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>, <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00234">edgeValue()</a>, <a class="el" href="blur_8cpp_source.html#l00227">regionIndex()</a>, and <a class="el" href="blur_8cpp_source.html#l00527">resetImageData()</a>.</p> </div> </div> <a class="anchor" id="ab903d24dabd249aee4c0d5335f332d02"></a><!-- doxytag: member="blur.cpp::fullRes" ref="ab903d24dabd249aee4c0d5335f332d02" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">QSize <a class="el" href="blur_8cpp.html#ab903d24dabd249aee4c0d5335f332d02">fullRes</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00091">91</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00234">edgeValue()</a>, and <a class="el" href="blur_8cpp_source.html#l00227">regionIndex()</a>.</p> </div> </div> <a class="anchor" id="ad12fc34ce789bce6c8a05d8a17138534"></a><!-- doxytag: member="blur.cpp::height" ref="ad12fc34ce789bce6c8a05d8a17138534" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int <a class="el" href="blur_8cpp.html#ad12fc34ce789bce6c8a05d8a17138534">height</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00079">79</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>, <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="photoPreviewWidget_8cpp_source.html#l00175">PhotoPreviewWidget::compare()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00117">SelectionInterface::constructDisplayImages()</a>, <a class="el" href="edgeDetect_8cpp_source.html#l00859">EdgeDetect::constructEdgeImage()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00874">SelectionInterface::ConvertDisplayToImageCoordinate()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00900">SelectionInterface::ConvertImageToDisplayCoordinate()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00926">SelectionInterface::cropSelectedPoint()</a>, <a class="el" href="subalbumPreviewWidget_8cpp_source.html#l00175">SubalbumPreviewWidget::dropped()</a>, <a class="el" href="photoPreviewWidget_8cpp_source.html#l00224">PhotoPreviewWidget::getPhotoInfoRect()</a>, <a class="el" href="tilt_8cpp_source.html#l00312">interpolatedPixelValue()</a>, <a class="el" href="main_8cpp_source.html#l00050">main()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00351">SelectionInterface::mouseActionByPosition()</a>, <a class="el" href="splitViewInterface_8cpp_source.html#l00322">SplitViewInterface::mouseMoveEvent()</a>, <a class="el" href="clickableLabel_8cpp_source.html#l00089">ClickableLabel::mouseMoveEvent()</a>, <a class="el" href="clickableLabel_8cpp_source.html#l00193">ClickableLabel::mouseReleaseEvent()</a>, <a class="el" href="splitViewInterface_8cpp_source.html#l00287">SplitViewInterface::nearSplitPoint()</a>, <a class="el" href="selectionPlacementInterface_8cpp_source.html#l00161">SelectionPlacementInterface::overRegion()</a>, <a class="el" href="photoPreviewWidget_8cpp_source.html#l00076">PhotoPreviewWidget::paint()</a>, <a class="el" href="splitViewInterface_8cpp_source.html#l00058">SplitViewInterface::paintEvent()</a>, <a class="el" href="selectionPlacementInterface_8cpp_source.html#l00086">SelectionPlacementInterface::paintEvent()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00161">SelectionInterface::paintEvent()</a>, <a class="el" href="subalbumPreviewWidget_8cpp_source.html#l00059">SubalbumPreviewWidget::paintItem()</a>, <a class="el" href="photoPreviewWidget_8cpp_source.html#l00109">PhotoPreviewWidget::paintItem()</a>, <a class="el" href="item_8cpp_source.html#l00026">Item::paintItem()</a>, <a class="el" href="groupIcon_8cpp_source.html#l00034">GroupIcon::paintItem()</a>, <a class="el" href="pointillism_8cpp_source.html#l00058">pixelValid()</a>, <a class="el" href="pointillism_8cpp_source.html#l00109">pointillismEffect()</a>, <a class="el" href="selectionPlacementInterface_8cpp_source.html#l00185">SelectionPlacementInterface::recenterSelection()</a>, <a class="el" href="scaledPreviewInterface_8cpp_source.html#l00033">ScaledPreviewInterface::resizeEvent()</a>, <a class="el" href="layoutSettingsWidget_8cpp_source.html#l00130">LayoutSettingsWidget::setDefaults()</a>, <a class="el" href="item_8cpp_source.html#l00063">Item::setTextWidth()</a>, <a class="el" href="dynamicSlider_8cpp_source.html#l00167">SliderToolTip::update()</a>, and <a class="el" href="window_8cpp_source.html#l00152">Window::~Window()</a>.</p> </div> </div> <a class="anchor" id="a0a19a0620af7373e3ddba0ce4e1058e1"></a><!-- doxytag: member="blur.cpp::q" ref="a0a19a0620af7373e3ddba0ce4e1058e1" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float <a class="el" href="blur_8cpp.html#a0a19a0620af7373e3ddba0ce4e1058e1">q</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00078">78</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00150">computeCoeffs()</a>, and <a class="el" href="imageTools_8cpp_source.html#l00264">HSVtoRGB()</a>.</p> </div> </div> <a class="anchor" id="a2cce1ac8bdf75e631a3cc099d7444c7a"></a><!-- doxytag: member="blur.cpp::regionColBuffer" ref="a2cce1ac8bdf75e631a3cc099d7444c7a" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float* <a class="el" href="blur_8cpp.html#a2cce1ac8bdf75e631a3cc099d7444c7a">regionColBuffer</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00085">85</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, and <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>.</p> </div> </div> <a class="anchor" id="a99011823ef56f33be976af30f313f132"></a><!-- doxytag: member="blur.cpp::regionCount" ref="a99011823ef56f33be976af30f313f132" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int <a class="el" href="blur_8cpp.html#a99011823ef56f33be976af30f313f132">regionCount</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00089">89</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, and <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>.</p> </div> </div> <a class="anchor" id="a9752978c7e4bd6f4fbdedbce54b5776d"></a><!-- doxytag: member="blur.cpp::regionMap" ref="a9752978c7e4bd6f4fbdedbce54b5776d" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int* <a class="el" href="blur_8cpp.html#a9752978c7e4bd6f4fbdedbce54b5776d">regionMap</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00088">88</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>, <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, and <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>.</p> </div> </div> <a class="anchor" id="acf497bcaec224469d3e0906be03a438b"></a><!-- doxytag: member="blur.cpp::regionRowBuffer" ref="acf497bcaec224469d3e0906be03a438b" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float* <a class="el" href="blur_8cpp.html#acf497bcaec224469d3e0906be03a438b">regionRowBuffer</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00084">84</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, and <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>.</p> </div> </div> <a class="anchor" id="a89c34a2d7f884fa813593747fd9e4bdb"></a><!-- doxytag: member="blur.cpp::rowBuffer" ref="a89c34a2d7f884fa813593747fd9e4bdb" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">float* <a class="el" href="blur_8cpp.html#a89c34a2d7f884fa813593747fd9e4bdb">rowBuffer</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00081">81</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, and <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>.</p> </div> </div> <a class="anchor" id="a2474a5474cbff19523a51eb1de01cda4"></a><!-- doxytag: member="blur.cpp::width" ref="a2474a5474cbff19523a51eb1de01cda4" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int <a class="el" href="blur_8cpp.html#a2474a5474cbff19523a51eb1de01cda4">width</a></td> </tr> </table> </div> <div class="memdoc"> <p>Definition at line <a class="el" href="blur_8cpp_source.html#l00079">79</a> of file <a class="el" href="blur_8cpp_source.html">blur.cpp</a>.</p> <p>Referenced by <a class="el" href="ALabel_8cpp_source.html#l00193">ALabel::animate()</a>, <a class="el" href="blur_8cpp_source.html#l00204">blurBuffer()</a>, <a class="el" href="blur_8cpp_source.html#l00409">blurColumn()</a>, <a class="el" href="blur_8cpp_source.html#l00101">blurImage()</a>, <a class="el" href="blur_8cpp_source.html#l00434">blurRegionsInCol()</a>, <a class="el" href="blur_8cpp_source.html#l00311">blurRegionsInRow()</a>, <a class="el" href="blur_8cpp_source.html#l00285">blurRow()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00117">SelectionInterface::constructDisplayImages()</a>, <a class="el" href="edgeDetect_8cpp_source.html#l00859">EdgeDetect::constructEdgeImage()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00874">SelectionInterface::ConvertDisplayToImageCoordinate()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00900">SelectionInterface::ConvertImageToDisplayCoordinate()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00926">SelectionInterface::cropSelectedPoint()</a>, <a class="el" href="histogramInterface_8cpp_source.html#l00145">HistogramInterface::displayToIndex()</a>, <a class="el" href="titleWidget_8cpp_source.html#l01282">TitleWidget::dropEvent()</a>, <a class="el" href="photosIconView_8cpp_source.html#l00110">PhotosIconView::findNearestUnselectedPhoto()</a>, <a class="el" href="photoPreviewWidget_8cpp_source.html#l00224">PhotoPreviewWidget::getPhotoInfoRect()</a>, <a class="el" href="histogramInterface_8cpp_source.html#l00150">HistogramInterface::indexToDisplay()</a>, <a class="el" href="tilt_8cpp_source.html#l00312">interpolatedPixelValue()</a>, <a class="el" href="main_8cpp_source.html#l00050">main()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00351">SelectionInterface::mouseActionByPosition()</a>, <a class="el" href="splitViewInterface_8cpp_source.html#l00322">SplitViewInterface::mouseMoveEvent()</a>, <a class="el" href="histogramInterface_8cpp_source.html#l00368">HistogramInterface::mouseMoveEvent()</a>, <a class="el" href="clickableLabel_8cpp_source.html#l00089">ClickableLabel::mouseMoveEvent()</a>, <a class="el" href="clickableLabel_8cpp_source.html#l00193">ClickableLabel::mouseReleaseEvent()</a>, <a class="el" href="splitViewInterface_8cpp_source.html#l00287">SplitViewInterface::nearSplitPoint()</a>, <a class="el" href="selectionPlacementInterface_8cpp_source.html#l00161">SelectionPlacementInterface::overRegion()</a>, <a class="el" href="photoPreviewWidget_8cpp_source.html#l00076">PhotoPreviewWidget::paint()</a>, <a class="el" href="splitViewInterface_8cpp_source.html#l00058">SplitViewInterface::paintEvent()</a>, <a class="el" href="selectionPlacementInterface_8cpp_source.html#l00086">SelectionPlacementInterface::paintEvent()</a>, <a class="el" href="selectionInterface_8cpp_source.html#l00161">SelectionInterface::paintEvent()</a>, <a class="el" href="histogramInterface_8cpp_source.html#l00155">HistogramInterface::paintEvent()</a>, <a class="el" href="subalbumPreviewWidget_8cpp_source.html#l00059">SubalbumPreviewWidget::paintItem()</a>, <a class="el" href="photoPreviewWidget_8cpp_source.html#l00109">PhotoPreviewWidget::paintItem()</a>, <a class="el" href="pointillism_8cpp_source.html#l00058">pixelValid()</a>, <a class="el" href="pointillism_8cpp_source.html#l00109">pointillismEffect()</a>, <a class="el" href="selectionPlacementInterface_8cpp_source.html#l00185">SelectionPlacementInterface::recenterSelection()</a>, <a class="el" href="titleWidget_8cpp_source.html#l01435">TitleWidget::refreshOpenRecentMenu()</a>, <a class="el" href="scaledPreviewInterface_8cpp_source.html#l00033">ScaledPreviewInterface::resizeEvent()</a>, <a class="el" href="layoutSettingsWidget_8cpp_source.html#l00130">LayoutSettingsWidget::setDefaults()</a>, <a class="el" href="dynamicSlider_8cpp_source.html#l00167">SliderToolTip::update()</a>, and <a class="el" href="window_8cpp_source.html#l00152">Window::~Window()</a>.</p> </div> </div> </div> <hr size="1"/><address style="text-align: right;"><small>Generated by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.2 </small></address> </body> </html>