\section{KImage\-Effect Class Reference}
\label{classKImageEffect}\index{KImageEffect@{KImageEffect}}
This class includes various {\bf QImage} based graphical effects.  


{\tt \#include $<$kimageeffect.h$>$}

\subsection*{Public Types}
\begin{CompactItemize}
\item 
enum {\bf Gradient\-Type} \{ \par
{\bf Vertical\-Gradient}, 
{\bf Horizontal\-Gradient}, 
{\bf Diagonal\-Gradient}, 
{\bf Cross\-Diagonal\-Gradient}, 
\par
{\bf Pyramid\-Gradient}, 
{\bf Rectangle\-Gradient}, 
{\bf Pipe\-Cross\-Gradient}, 
{\bf Elliptic\-Gradient}
 \}
\item 
enum {\bf RGBComponent} \{ \par
{\bf Red}, 
{\bf Green}, 
{\bf Blue}, 
{\bf Gray}, 
\par
{\bf All}
 \}
\item 
enum {\bf Lighting} \{ \par
{\bf North\-Lite}, 
{\bf NWLite}, 
{\bf West\-Lite}, 
{\bf SWLite}, 
\par
{\bf South\-Lite}, 
{\bf SELite}, 
{\bf East\-Lite}, 
{\bf NELite}
 \}
\item 
enum {\bf Modulation\-Type} \{ {\bf Intensity}, 
{\bf Saturation}, 
{\bf Hue\-Shift}, 
{\bf Contrast}
 \}
\item 
enum {\bf Noise\-Type} \{ \par
{\bf Uniform\-Noise} = 0, 
{\bf Gaussian\-Noise}, 
{\bf Multiplicative\-Gaussian\-Noise}, 
{\bf Impulse\-Noise}, 
\par
{\bf Laplacian\-Noise}, 
{\bf Poisson\-Noise}
 \}
\item 
enum {\bf Rotate\-Direction} \{ {\bf Rotate90}, 
{\bf Rotate180}, 
{\bf Rotate270}
 \}
\end{CompactItemize}
\subsection*{Static Public Member Functions}
\begin{CompactItemize}
\item 
{\bf QImage} {\bf gradient} (const  {\bf QSize} \&size, const  {\bf QColor} \&ca, const  {\bf QColor} \&cb, Gradient\-Type type, int ncols=3)
\begin{CompactList}\small\item\em Create a gradient from color a to color b of the specified type. \item\end{CompactList}\item 
{\bf QImage} {\bf unbalanced\-Gradient} (const  {\bf QSize} \&size, const  {\bf QColor} \&ca, const  {\bf QColor} \&cb, Gradient\-Type type, int xfactor=100, int yfactor=100, int ncols=3)
\begin{CompactList}\small\item\em Create an unbalanced gradient. \item\end{CompactList}\item 
{\bf QImage} \& {\bf blend} (const  {\bf QColor} \&clr, {\bf QImage} \&dst, float opacity)
\begin{CompactList}\small\item\em Blends a color into the destination image, using an opacity value for blending one into another. \item\end{CompactList}\item 
{\bf QImage} \& {\bf blend} ({\bf QImage} \&src, {\bf QImage} \&dst, float opacity)
\begin{CompactList}\small\item\em Blend the src image into the destination image, using an opacity value for blending one into another. \item\end{CompactList}\item 
{\bf QImage} \& {\bf blend} ({\bf QImage} \&image, float initial\_\-intensity, const  {\bf QColor} \&bgnd, Gradient\-Type eff, bool anti\_\-dir=false)
\begin{CompactList}\small\item\em Blend the provided image into a background of the indicated color. \item\end{CompactList}\item 
{\bf QImage} \& {\bf blend} ({\bf QImage} \&image1, {\bf QImage} \&image2, Gradient\-Type gt, int xf=100, int yf=100)
\begin{CompactList}\small\item\em Blend an image into another one, using a gradient type for blending from one to another. \item\end{CompactList}\item 
{\bf QImage} \& {\bf blend} ({\bf QImage} \&image1, {\bf QImage} \&image2, {\bf QImage} \&blend\-Image, RGBComponent channel)
\begin{CompactList}\small\item\em Blend an image into another one, using a color channel of a third image for the decision of blending from one to another. \item\end{CompactList}\item 
bool {\bf blend} (const  {\bf QImage} \&upper, const  {\bf QImage} \&lower, {\bf QImage} \&output)
\begin{CompactList}\small\item\em Blend an image into another one, using alpha in the expected way. \item\end{CompactList}\item 
bool {\bf blend} (int \&x, int \&y, const  {\bf QImage} \&upper, const  {\bf QImage} \&lower, {\bf QImage} \&output)
\begin{CompactList}\small\item\em Blend an image into another one, using alpha in the expected way and over coordinates {\tt x} and {\tt y} with respect to the lower image. \item\end{CompactList}\item 
bool {\bf blend\-On\-Lower} (int x, int y, const  {\bf QImage} \&upper, const  {\bf QImage} \&lower)
\begin{CompactList}\small\item\em Blend an image into another one, using alpha in the expected way and over coordinates {\tt x} and {\tt y} with respect to the lower image. \item\end{CompactList}\item 
{\bf QImage} \& {\bf channel\-Intensity} ({\bf QImage} \&image, float percent, RGBComponent channel)
\begin{CompactList}\small\item\em Modifies the intensity of a pixmap's RGB channel component. \item\end{CompactList}\item 
{\bf QImage} \& {\bf fade} ({\bf QImage} \&img, float val, const  {\bf QColor} \&color)
\begin{CompactList}\small\item\em Fade an image to a certain background color. \item\end{CompactList}\item 
{\bf QImage} \& {\bf flatten} ({\bf QImage} \&image, const  {\bf QColor} \&ca, const  {\bf QColor} \&cb, int ncols=0)
\begin{CompactList}\small\item\em This recolors a pixmap. \item\end{CompactList}\item 
{\bf QImage} \& {\bf hash} ({\bf QImage} \&image, Lighting lite=North\-Lite, unsigned int spacing=0)
\begin{CompactList}\small\item\em Build a hash on any given {\bf QImage}. \item\end{CompactList}\item 
{\bf QImage} \& {\bf intensity} ({\bf QImage} \&image, float percent)
\begin{CompactList}\small\item\em Either brighten or dim the image by a specified percent. \item\end{CompactList}\item 
{\bf QImage} \& {\bf modulate} ({\bf QImage} \&image, {\bf QImage} \&mod\-Image, bool reverse, Modulation\-Type type, int factor, RGBComponent channel)
\begin{CompactList}\small\item\em Modulate the image with a color channel of another image. \item\end{CompactList}\item 
{\bf QImage} \& {\bf to\-Gray} ({\bf QImage} \&image, bool fast=false)
\begin{CompactList}\small\item\em Convert an image to grayscale. \item\end{CompactList}\item 
{\bf QImage} \& {\bf desaturate} ({\bf QImage} \&image, float desat=0.3)
\begin{CompactList}\small\item\em Desaturate an image evenly. \item\end{CompactList}\item 
{\bf QImage} \& {\bf contrast} ({\bf QImage} \&image, int c)
\begin{CompactList}\small\item\em Fast, but low quality contrast of an image. \item\end{CompactList}\item 
{\bf QImage} \& {\bf dither} ({\bf QImage} \&img, const  {\bf QColor} $\ast$palette, int size)
\begin{CompactList}\small\item\em Dither an image using Floyd-Steinberg dithering for low-color situations. \item\end{CompactList}\item 
{\bf QImage} \& {\bf selected\-Image} ({\bf QImage} \&img, const  {\bf QColor} \&col)
\begin{CompactList}\small\item\em Calculate the image for a selected image, for instance a selected icon on the desktop. \item\end{CompactList}\item 
void {\bf contrast\-HSV} ({\bf QImage} \&img, bool sharpen=true)
\begin{CompactList}\small\item\em High quality, expensive HSV contrast. \item\end{CompactList}\item 
void {\bf normalize} ({\bf QImage} \&img)
\begin{CompactList}\small\item\em Normalizes the pixel values to span the full range of color values. \item\end{CompactList}\item 
void {\bf equalize} ({\bf QImage} \&img)
\begin{CompactList}\small\item\em Performs histogram equalization on the reference image. \item\end{CompactList}\item 
void {\bf threshold} ({\bf QImage} \&img, unsigned int value=128)
\begin{CompactList}\small\item\em Thresholds the reference image. \item\end{CompactList}\item 
void {\bf solarize} ({\bf QImage} \&img, double factor=50.0)
\begin{CompactList}\small\item\em Produces a 'solarization' effect seen when exposing a photographic film to light during the development process. \item\end{CompactList}\item 
{\bf QImage} {\bf emboss} ({\bf QImage} \&src)
\begin{CompactList}\small\item\em Embosses the source image. \item\end{CompactList}\item 
{\bf QImage} {\bf despeckle} ({\bf QImage} \&src)
\begin{CompactList}\small\item\em Minimizes speckle noise in the source image using the 8 hull algorithm. \item\end{CompactList}\item 
{\bf QImage} {\bf charcoal} ({\bf QImage} \&src, double factor=50.0)
\begin{CompactList}\small\item\em Produces a neat little \char`\"{}charcoal\char`\"{} effect. \item\end{CompactList}\item 
{\bf QImage} {\bf rotate} ({\bf QImage} \&src, Rotate\-Direction r)
\begin{CompactList}\small\item\em Rotates the image by the specified amount. \item\end{CompactList}\item 
{\bf QImage} {\bf sample} ({\bf QImage} \&src, int w, int h)
\begin{CompactList}\small\item\em Scales an image using simple pixel sampling. \item\end{CompactList}\item 
{\bf QImage} {\bf add\-Noise} ({\bf QImage} \&src, Noise\-Type type=Gaussian\-Noise)
\begin{CompactList}\small\item\em Adds noise to an image. \item\end{CompactList}\item 
{\bf QImage} {\bf blur} ({\bf QImage} \&src, double factor=50.0)
\begin{CompactList}\small\item\em Blurs an image by convolving pixel neighborhoods. \item\end{CompactList}\item 
{\bf QImage} {\bf edge} ({\bf QImage} \&src, double factor=50.0)
\begin{CompactList}\small\item\em Detects edges in an image using pixel neighborhoods and an edge detection mask. \item\end{CompactList}\item 
{\bf QImage} {\bf implode} ({\bf QImage} \&src, double factor=30.0, unsigned int background=0x\-FFFFFFFF)
\begin{CompactList}\small\item\em Implodes an image by a specified percent. \item\end{CompactList}\item 
{\bf QImage} {\bf oil\-Paint} ({\bf QImage} \&src, int radius=3)
\begin{CompactList}\small\item\em Produces an oil painting effect. \item\end{CompactList}\item 
{\bf QImage} {\bf sharpen} ({\bf QImage} \&src, double factor=30.0)
\begin{CompactList}\small\item\em Sharpens the pixels in the image using pixel neighborhoods. \item\end{CompactList}\item 
{\bf QImage} {\bf spread} ({\bf QImage} \&src, unsigned int amount=3)
\begin{CompactList}\small\item\em Randomly displaces pixels. \item\end{CompactList}\item 
{\bf QImage} {\bf shade} ({\bf QImage} \&src, bool color\_\-shading=true, double azimuth=30.0, double elevation=30.0)
\begin{CompactList}\small\item\em Shades the image using a distance light source. \item\end{CompactList}\item 
{\bf QImage} {\bf swirl} ({\bf QImage} \&src, double degrees=50.0, unsigned int background=0x\-FFFFFFFF)
\begin{CompactList}\small\item\em Swirls the image by a specified amount. \item\end{CompactList}\item 
{\bf QImage} {\bf wave} ({\bf QImage} \&src, double amplitude=25.0, double frequency=150.0, unsigned int background=0x\-FFFFFFFF)
\begin{CompactList}\small\item\em Modifies the pixels along a sine wave. \item\end{CompactList}\end{CompactItemize}


\subsection{Detailed Description}
This class includes various {\bf QImage} based graphical effects. 

Everything is static, so there is no need to create an instance of this class. You can just call the static methods. They are encapsulated here merely to provide a common namespace. 



Definition at line 47 of file kimageeffect.h.

\subsection{Member Function Documentation}
\index{KImageEffect@{KImage\-Effect}!gradient@{gradient}}
\index{gradient@{gradient}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::gradient (const {\bf QSize} \& {\em size}, const {\bf QColor} \& {\em ca}, const {\bf QColor} \& {\em cb}, Gradient\-Type {\em type}, int {\em ncols} = 3)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e0}


Create a gradient from color a to color b of the specified type. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em size}]The desired size of the gradient. \item[{\em ca}]Color a \item[{\em cb}]Color b \item[{\em type}]The type of gradient. \item[{\em ncols}]The number of colors to use when not running on a truecolor display. The gradient will be dithered to this number of colors. Pass 0 to prevent dithering. \end{description}
\end{Desc}


Definition at line 58 of file kimageeffect.cpp.

References QColor::blue(), QPixmap::default\-Depth(), dither(), QColor::green(), QSize::height(), QColor::red(), QImage::scan\-Line(), QColor::set\-Rgb(), and QSize::width().

Referenced by KPixmap\-Effect::gradient().\index{KImageEffect@{KImage\-Effect}!unbalancedGradient@{unbalancedGradient}}
\index{unbalancedGradient@{unbalancedGradient}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::unbalanced\-Gradient (const {\bf QSize} \& {\em size}, const {\bf QColor} \& {\em ca}, const {\bf QColor} \& {\em cb}, Gradient\-Type {\em type}, int {\em xfactor} = 100, int {\em yfactor} = 100, int {\em ncols} = 3)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e1}


Create an unbalanced gradient. 

An unbalanced gradient is a gradient where the transition from color a to color b is not linear, but in this case, exponential.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em size}]The desired size of the gradient. \item[{\em ca}]Color a \item[{\em cb}]Color b \item[{\em type}]The type of gradient. \item[{\em xfactor}]The x decay length. Use a value between -200 and 200. \item[{\em yfactor}]The y decay length. \item[{\em ncols}]The number of colors. See {\bf KPixmap\-Effect}{\rm (p.\,\pageref{classKPixmapEffect})}:gradient. \end{description}
\end{Desc}


Definition at line 322 of file kimageeffect.cpp.

References QColor::blue(), QPixmap::default\-Depth(), dither(), QColor::green(), QSize::height(), QColor::red(), QColor::rgb(), QImage::scan\-Line(), QColor::set\-Rgb(), and QSize::width().

Referenced by blend(), and KPixmap\-Effect::unbalanced\-Gradient().\index{KImageEffect@{KImage\-Effect}!blend@{blend}}
\index{blend@{blend}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::blend (const {\bf QColor} \& {\em clr}, {\bf QImage} \& {\em dst}, float {\em opacity})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e2}


Blends a color into the destination image, using an opacity value for blending one into another. 

Very fast direct pixel manipulation is used.

\begin{Desc}
\item[Author:]Karol Szwed ({\tt gallium@kde.org}) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em clr}]source color to be blended into the destination image. \item[{\em dst}]destination image in which the source will be blended into. \item[{\em opacity}]opacity (in percent) which determines how much the source color will be blended into the destination image. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The destination image (dst) containing the result. \end{Desc}


Definition at line 860 of file kimageeffect.cpp.

References QImage::bits(), QImage::convert\-Depth(), QImage::depth(), QImage::height(), QColor::rgb(), and QImage::width().

Referenced by KPixmap\-Effect::blend(), blend(), and selected\-Image().\index{KImageEffect@{KImage\-Effect}!blend@{blend}}
\index{blend@{blend}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::blend ({\bf QImage} \& {\em src}, {\bf QImage} \& {\em dst}, float {\em opacity})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e3}


Blend the src image into the destination image, using an opacity value for blending one into another. 

Very fast direct pixel manipulation is used.

\begin{Desc}
\item[Author:]Karol Szwed ({\tt gallium@kde.org}) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]source image to be blended into the destination image. \item[{\em dst}]destination image in which the source will be blended into. \item[{\em opacity}]opacity (in percent) which determines how much the source image will be blended into the destination image. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The destination image (dst) containing the result. \end{Desc}


Definition at line 903 of file kimageeffect.cpp.

References QImage::bits(), QImage::convert\-Depth(), QImage::depth(), QImage::height(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!blend@{blend}}
\index{blend@{blend}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::blend ({\bf QImage} \& {\em image}, float {\em initial\_\-intensity}, const {\bf QColor} \& {\em bgnd}, Gradient\-Type {\em eff}, bool {\em anti\_\-dir} = false)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e4}


Blend the provided image into a background of the indicated color. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em initial\_\-intensity}]this parameter takes values from -1 to 1: a) if positive: how much to fade the image in its less affected spot b) if negative: roughly indicates how much of the image remains unaffected \item[{\em bgnd}]indicates the color of the background to blend in \item[{\em eff}]lets you choose what kind of blending you like \item[{\em anti\_\-dir}]blend in the opposite direction (makes no much sense with concentric blending effects) \item[{\em image}]must be 32bpp \end{description}
\end{Desc}


Definition at line 955 of file kimageeffect.cpp.

References QImage::bits(), QColor::blue(), QImage::depth(), QColor::green(), QImage::height(), intensity(), QColor::red(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!blend@{blend}}
\index{blend@{blend}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::blend ({\bf QImage} \& {\em image1}, {\bf QImage} \& {\em image2}, Gradient\-Type {\em gt}, int {\em xf} = 100, int {\em yf} = 100)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e5}


Blend an image into another one, using a gradient type for blending from one to another. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image1}]source1 and result of blending \item[{\em image2}]source2 of blending \item[{\em gt}]gradient type for blending between source1 and source2 \item[{\em xf}]x decay length for unbalanced gradient tpye \item[{\em yf}]y decay length for unbalanced gradient tpye \end{description}
\end{Desc}


Definition at line 1163 of file kimageeffect.cpp.

References blend(), QImage::height(), QImage::size(), unbalanced\-Gradient(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!blend@{blend}}
\index{blend@{blend}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::blend ({\bf QImage} \& {\em image1}, {\bf QImage} \& {\em image2}, {\bf QImage} \& {\em blend\-Image}, RGBComponent {\em channel})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e6}


Blend an image into another one, using a color channel of a third image for the decision of blending from one to another. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image1}]Source 1 and result of blending \item[{\em image2}]Source 2 of blending \item[{\em blend\-Image}]If the gray value of of pixel is 0, the result for this pixel is that of image1; for a gray value of 1, the pixel of image2 is used; for a value inbetween, a corresponding blending is used. \item[{\em channel}]The RBG channel to use for the blending decision. \end{description}
\end{Desc}


Definition at line 1181 of file kimageeffect.cpp.

References QImage::bits(), QImage::color\-Table(), QImage::convert\-Depth(), QImage::depth(), QImage::height(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!blend@{blend}}
\index{blend@{blend}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool KImage\-Effect::blend (const {\bf QImage} \& {\em upper}, const {\bf QImage} \& {\em lower}, {\bf QImage} \& {\em output})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e7}


Blend an image into another one, using alpha in the expected way. 

\begin{Desc}
\item[Author:]Rik Hemsley (rikkus) $<${\tt rik@kde.org}$>$ \end{Desc}


Definition at line 1784 of file kimageeffect.cpp.

References QImage::copy(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!blend@{blend}}
\index{blend@{blend}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool KImage\-Effect::blend (int \& {\em x}, int \& {\em y}, const {\bf QImage} \& {\em upper}, const {\bf QImage} \& {\em lower}, {\bf QImage} \& {\em output})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e8}


Blend an image into another one, using alpha in the expected way and over coordinates {\tt x} and {\tt y} with respect to the lower image. 

The output is a {\bf QImage} which is the {\tt upper} image already blended with the {\tt lower} one, so its size will be (in general) the same than {\tt upper} instead of the same size than {\tt lower} like the method above. In fact, the size of {\tt output} is like upper's one only when it can be painted on lower, if there has to be some clipping, output's size will be the clipped area and x and y will be set to the correct up-left corner where the clipped rectangle begins. 

Definition at line 1856 of file kimageeffect.cpp.

References QImage::create(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!blendOnLower@{blendOnLower}}
\index{blendOnLower@{blendOnLower}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool KImage\-Effect::blend\-On\-Lower (int {\em x}, int {\em y}, const {\bf QImage} \& {\em upper}, const {\bf QImage} \& {\em lower})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e9}


Blend an image into another one, using alpha in the expected way and over coordinates {\tt x} and {\tt y} with respect to the lower image. 

The output is painted in the own {\tt lower} image. This is an optimization of the blend method above provided by convenience. 

Definition at line 1920 of file kimageeffect.cpp.

References QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!channelIntensity@{channelIntensity}}
\index{channelIntensity@{channelIntensity}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::channel\-Intensity ({\bf QImage} \& {\em image}, float {\em percent}, RGBComponent {\em channel})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e10}


Modifies the intensity of a pixmap's RGB channel component. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to process. \item[{\em percent}]Percent value. Use a negative value to dim. \item[{\em channel}]Which channel(s) should be modified \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The {\tt image}, provided for convenience. \end{Desc}


Definition at line 639 of file kimageeffect.cpp.

References QImage::bits(), QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), and QImage::width().

Referenced by KPixmap\-Effect::channel\-Intensity().\index{KImageEffect@{KImage\-Effect}!fade@{fade}}
\index{fade@{fade}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::fade ({\bf QImage} \& {\em img}, float {\em val}, const {\bf QColor} \& {\em color})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e11}


Fade an image to a certain background color. 

The number of colors will not be changed.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to process. \item[{\em val}]The strength of the effect. 0 $<$= val $<$= 1. \item[{\em color}]The background color. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Returns the image(), provided for convenience. \end{Desc}


Definition at line 1462 of file kimageeffect.cpp.

References QColor::blue(), QImage::color(), QImage::depth(), QColor::green(), QImage::height(), QImage::num\-Colors(), QColor::red(), QImage::scan\-Line(), QImage::set\-Color(), and QImage::width().

Referenced by KPixmap\-Effect::fade().\index{KImageEffect@{KImage\-Effect}!flatten@{flatten}}
\index{flatten@{flatten}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::flatten ({\bf QImage} \& {\em image}, const {\bf QColor} \& {\em ca}, const {\bf QColor} \& {\em cb}, int {\em ncols} = 0)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e12}


This recolors a pixmap. 

The most dark color will become color a, the most bright one color b, and in between.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]A {\bf QImage} to process. \item[{\em ca}]Color a \item[{\em cb}]Color b \end{description}
\end{Desc}


Definition at line 1365 of file kimageeffect.cpp.

References QColor::blue(), QImage::color(), QImage::depth(), dither(), QColor::green(), QImage::height(), QImage::num\-Colors(), QImage::pixel(), QColor::red(), QColor::rgb(), QImage::set\-Color(), QImage::set\-Pixel(), and QImage::width().

Referenced by KPixmap\-Effect::pattern().\index{KImageEffect@{KImage\-Effect}!hash@{hash}}
\index{hash@{hash}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::hash ({\bf QImage} \& {\em image}, Lighting {\em lite} = North\-Lite, unsigned int {\em spacing} = 0)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e13}


Build a hash on any given {\bf QImage}. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to process \item[{\em lite}]The hash faces the indicated lighting (cardinal poles). \item[{\em spacing}]How many unmodified pixels inbetween hashes. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Returns the image(), provided for convenience. \end{Desc}


Definition at line 1284 of file kimageeffect.cpp.

References QImage::bits(), QImage::height(), and QImage::width().

Referenced by KPixmap\-Effect::hash().\index{KImageEffect@{KImage\-Effect}!intensity@{intensity}}
\index{intensity@{intensity}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::intensity ({\bf QImage} \& {\em image}, float {\em percent})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e14}


Either brighten or dim the image by a specified percent. 

For example, .50 will modify the colors by 50\%.

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to process. \item[{\em percent}]The percent value. Use a negative value to dim. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Returns The image(), provided for convenience. \end{Desc}


Definition at line 573 of file kimageeffect.cpp.

References QImage::bits(), QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), and QImage::width().

Referenced by blend(), and KPixmap\-Effect::intensity().\index{KImageEffect@{KImage\-Effect}!modulate@{modulate}}
\index{modulate@{modulate}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::modulate ({\bf QImage} \& {\em image}, {\bf QImage} \& {\em mod\-Image}, bool {\em reverse}, Modulation\-Type {\em type}, int {\em factor}, RGBComponent {\em channel})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e15}


Modulate the image with a color channel of another image. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to modulate and result. \item[{\em mod\-Image}]The {\bf QImage} to use for modulation. \item[{\em reverse}]Invert the meaning of image/mod\-Image; result is image! \item[{\em type}]The modulation Type to use. \item[{\em factor}]The modulation amplitude; with 0 no effect [-200;200]. \item[{\em channel}]The RBG channel of image2 to use for modulation. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Returns the image(), provided for convenience. \end{Desc}


Definition at line 730 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::convert\-Depth(), QImage::depth(), QImage::height(), QColor::rgb(), QImage::scan\-Line(), QColor::set\-Hsv(), QColor::set\-Rgb(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!toGray@{toGray}}
\index{toGray@{toGray}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::to\-Gray ({\bf QImage} \& {\em image}, bool {\em fast} = false)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e16}


Convert an image to grayscale. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to process. \item[{\em fast}]Set to {\tt true} in order to use a faster but non-photographic quality algorithm. Appropriate for things such as toolbar icons. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Returns the image(), provided for convenience. \end{Desc}


Definition at line 1544 of file kimageeffect.cpp.

References QImage::bits(), QImage::color(), QImage::color\-Table(), QImage::depth(), KStd\-Accel::end(), QImage::height(), QImage::num\-Bytes(), QImage::num\-Colors(), QImage::set\-Color(), and QImage::width().

Referenced by charcoal(), emboss(), and KPixmap\-Effect::to\-Gray().\index{KImageEffect@{KImage\-Effect}!desaturate@{desaturate}}
\index{desaturate@{desaturate}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::desaturate ({\bf QImage} \& {\em image}, float {\em desat} = 0.3)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e17}


Desaturate an image evenly. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to process. \item[{\em desat}]A value between 0 and 1 setting the degree of desaturation \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Returns the image(), provided for convenience. \end{Desc}


Definition at line 1594 of file kimageeffect.cpp.

References QImage::bits(), QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), QColor::rgb(), QColor::set\-Hsv(), QColor::set\-Rgb(), and QImage::width().

Referenced by KPixmap\-Effect::desaturate().\index{KImageEffect@{KImage\-Effect}!contrast@{contrast}}
\index{contrast@{contrast}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::contrast ({\bf QImage} \& {\em image}, int {\em c})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e18}


Fast, but low quality contrast of an image. 

Also see contrast\-HSV.

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to process. \item[{\em c}]A contrast value between -255 to 255. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The image(), provided for convenience. \end{Desc}


Definition at line 1617 of file kimageeffect.cpp.

References QImage::bits(), QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), and QImage::width().

Referenced by KPixmap\-Effect::contrast().\index{KImageEffect@{KImage\-Effect}!dither@{dither}}
\index{dither@{dither}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::dither ({\bf QImage} \& {\em img}, const {\bf QColor} $\ast$ {\em palette}, int {\em size})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e19}


Dither an image using Floyd-Steinberg dithering for low-color situations. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em image}]The {\bf QImage} to process. \item[{\em palette}]The color palette to use \item[{\em size}]The size of the palette \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Returns the image(), provided for convenience. \end{Desc}


Definition at line 1667 of file kimageeffect.cpp.

References QColor::blue(), QImage::depth(), QColor::green(), QImage::height(), QColor::red(), QImage::scan\-Line(), QImage::set\-Color(), QImage::set\-Num\-Colors(), and QImage::width().

Referenced by KPixmap\-Effect::blend(), KPixmap\-Effect::dither(), flatten(), gradient(), KPixmap\-Effect::hash(), and unbalanced\-Gradient().\index{KImageEffect@{KImage\-Effect}!selectedImage@{selectedImage}}
\index{selectedImage@{selectedImage}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} \& KImage\-Effect::selected\-Image ({\bf QImage} \& {\em img}, const {\bf QColor} \& {\em col})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e20}


Calculate the image for a selected image, for instance a selected icon on the desktop. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em img}]the {\bf QImage} to select \item[{\em col}]the selected color, usually from {\bf QColor\-Group::highlight()}. \end{description}
\end{Desc}


Definition at line 1991 of file kimageeffect.cpp.

References blend().

Referenced by KPixmap\-Effect::selected\-Pixmap().\index{KImageEffect@{KImage\-Effect}!contrastHSV@{contrastHSV}}
\index{contrastHSV@{contrastHSV}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KImage\-Effect::contrast\-HSV ({\bf QImage} \& {\em img}, bool {\em sharpen} = true)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e21}


High quality, expensive HSV contrast. 

You can do a faster one by just taking a intensity threshold (ie: 128) and incrementing RGB color channels above it and decrementing those below it, but this gives much better results.

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em img}]The {\bf QImage} to process. \item[{\em sharpen}]If true sharpness is increase, (spiffed). Otherwise it is decreased, (dulled). \end{description}
\end{Desc}


Definition at line 3756 of file kimageeffect.cpp.

References QImage::bits(), QColor::blue(), QImage::color\-Table(), QImage::depth(), QColor::green(), QImage::height(), QImage::num\-Colors(), QColor::red(), QColor::set\-Hsv(), QColor::set\-Rgb(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!normalize@{normalize}}
\index{normalize@{normalize}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KImage\-Effect::normalize ({\bf QImage} \& {\em img})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e22}


Normalizes the pixel values to span the full range of color values. 

This is a contrast enhancement technique. \begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}


Definition at line 2003 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), QImage::scan\-Line(), and QImage::width().

Referenced by charcoal(), and emboss().\index{KImageEffect@{KImage\-Effect}!equalize@{equalize}}
\index{equalize@{equalize}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KImage\-Effect::equalize ({\bf QImage} \& {\em img})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e23}


Performs histogram equalization on the reference image. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}


Definition at line 2119 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!threshold@{threshold}}
\index{threshold@{threshold}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KImage\-Effect::threshold ({\bf QImage} \& {\em img}, unsigned int {\em value} = 128)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e24}


Thresholds the reference image. 

You can also threshold images by using Threshold\-Dither in the various QPixmap/QImage convert methods, but this lets you specify a threshold value.

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em img}]The {\bf QImage} to process. \item[{\em value}]The threshold value. \end{description}
\end{Desc}


Definition at line 2297 of file kimageeffect.cpp.

References QImage::bits(), QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), and QImage::width().

Referenced by solarize().\index{KImageEffect@{KImage\-Effect}!solarize@{solarize}}
\index{solarize@{solarize}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void KImage\-Effect::solarize ({\bf QImage} \& {\em img}, double {\em factor} = 50.0)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e25}


Produces a 'solarization' effect seen when exposing a photographic film to light during the development process. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em img}]The {\bf QImage} to process. \item[{\em factor}]The extent of the solarization (0-99.9) \end{description}
\end{Desc}


Definition at line 2920 of file kimageeffect.cpp.

References QImage::bits(), QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), threshold(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!emboss@{emboss}}
\index{emboss@{emboss}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::emboss ({\bf QImage} \& {\em src})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e26}


Embosses the source image. 

This involves highlighting the edges and applying various other enhancements in order to get a metal effect.

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The embossed image. The original is not changed. \end{Desc}


Definition at line 3422 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), normalize(), QImage::scan\-Line(), to\-Gray(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!despeckle@{despeckle}}
\index{despeckle@{despeckle}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::despeckle ({\bf QImage} \& {\em src})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e27}


Minimizes speckle noise in the source image using the 8 hull algorithm. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The despeckled image. The original is not changed. \end{Desc}


Definition at line 2405 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!charcoal@{charcoal}}
\index{charcoal@{charcoal}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::charcoal ({\bf QImage} \& {\em src}, double {\em factor} = 50.0)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e28}


Produces a neat little \char`\"{}charcoal\char`\"{} effect. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em factor}]The factor for detecting lines (0-99.0). \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The charcoal image. The original is not changed. \end{Desc}


Definition at line 2313 of file kimageeffect.cpp.

References blur(), QImage::detach(), edge(), QImage::invert\-Pixels(), normalize(), and to\-Gray().\index{KImageEffect@{KImage\-Effect}!rotate@{rotate}}
\index{rotate@{rotate}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::rotate ({\bf QImage} \& {\em src}, Rotate\-Direction {\em r})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e29}


Rotates the image by the specified amount. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em r}]The rotate direction. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The rotated image. The original is not changed. \end{Desc}


Definition at line 2822 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::create(), QImage::depth(), QImage::height(), QImage::num\-Colors(), QImage::scan\-Line(), QImage::set\-Num\-Colors(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!sample@{sample}}
\index{sample@{sample}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::sample ({\bf QImage} \& {\em src}, int {\em w}, int {\em h})\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e30}


Scales an image using simple pixel sampling. 

This does not produce nearly as nice a result as {\bf QImage::smooth\-Scale()}, but has the advantage of being much faster - only a few milliseconds.

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em w}]The new width. \item[{\em h}]The new height. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The scaled image. The original is not changed. \end{Desc}


Definition at line 2204 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::num\-Colors(), QImage::scan\-Line(), QImage::set\-Num\-Colors(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!addNoise@{addNoise}}
\index{addNoise@{addNoise}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::add\-Noise ({\bf QImage} \& {\em src}, Noise\-Type {\em type} = Gaussian\-Noise)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e31}


Adds noise to an image. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em type}]The algorithm used to generate the noise. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The image with noise added. The original is not changed. \end{Desc}


Definition at line 2611 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!blur@{blur}}
\index{blur@{blur}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::blur ({\bf QImage} \& {\em src}, double {\em factor} = 50.0)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e32}


Blurs an image by convolving pixel neighborhoods. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em factor}]The percent weight to give to the center pixel. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The blurred image. The original is not changed. \end{Desc}


Definition at line 3654 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().

Referenced by charcoal().\index{KImageEffect@{KImage\-Effect}!edge@{edge}}
\index{edge@{edge}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::edge ({\bf QImage} \& {\em src}, double {\em factor} = 50.0)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e33}


Detects edges in an image using pixel neighborhoods and an edge detection mask. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em factor}]The percent weight to give to the center pixel. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The image with edges detected. The original is not changed. \end{Desc}


Definition at line 3174 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().

Referenced by charcoal().\index{KImageEffect@{KImage\-Effect}!implode@{implode}}
\index{implode@{implode}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::implode ({\bf QImage} \& {\em src}, double {\em factor} = 30.0, unsigned int {\em background} = 0x\-FFFFFFFF)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e34}


Implodes an image by a specified percent. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em factor}]The extent of the implosion. \item[{\em background}]An RGBA value to use for the background. After the effect some pixels may be \char`\"{}empty\char`\"{}. This value is used for those pixels. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The imploded image. The original is not changed. \end{Desc}


Definition at line 2741 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!oilPaint@{oilPaint}}
\index{oilPaint@{oilPaint}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::oil\-Paint ({\bf QImage} \& {\em src}, int {\em radius} = 3)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e35}


Produces an oil painting effect. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em radius}]The radius of the pixel neighborhood used in applying the effect. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The new image. The original is not changed. \end{Desc}


Definition at line 3098 of file kimageeffect.cpp.

References QImage::depth(), QImage::detach(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!sharpen@{sharpen}}
\index{sharpen@{sharpen}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::sharpen ({\bf QImage} \& {\em src}, double {\em factor} = 30.0)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e36}


Sharpens the pixels in the image using pixel neighborhoods. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em factor}]The percent weight to give to the center pixel. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The sharpened image. The original is not changed. \end{Desc}


Definition at line 3271 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!spread@{spread}}
\index{spread@{spread}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::spread ({\bf QImage} \& {\em src}, unsigned int {\em amount} = 3)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e37}


Randomly displaces pixels. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em amount}]The vicinity for choosing a random pixel to swap. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The image with pixels displaced. The original is not changed. \end{Desc}


Definition at line 2943 of file kimageeffect.cpp.

References QImage::depth(), QImage::detach(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!shade@{shade}}
\index{shade@{shade}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::shade ({\bf QImage} \& {\em src}, bool {\em color\_\-shading} = true, double {\em azimuth} = 30.0, double {\em elevation} = 30.0)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e38}


Shades the image using a distance light source. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em color\_\-shading}]If true do color shading, otherwise do grayscale. \item[{\em azimuth}]Determines the light source and direction. \item[{\em elevation}]Determines the light source and direction. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The shaded image. The original is not changed. \end{Desc}


Definition at line 3520 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::scan\-Line(), shade(), and QImage::width().

Referenced by shade().\index{KImageEffect@{KImage\-Effect}!swirl@{swirl}}
\index{swirl@{swirl}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::swirl ({\bf QImage} \& {\em src}, double {\em degrees} = 50.0, unsigned int {\em background} = 0x\-FFFFFFFF)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e39}


Swirls the image by a specified amount. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em degrees}]The tightness of the swirl. \item[{\em background}]An RGBA value to use for the background. After the effect some pixels may be \char`\"{}empty\char`\"{}. This value is used for those pixels. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The swirled image. The original is not changed. \end{Desc}


Definition at line 2994 of file kimageeffect.cpp.

References QImage::color\-Table(), QImage::depth(), QImage::height(), QImage::scan\-Line(), and QImage::width().\index{KImageEffect@{KImage\-Effect}!wave@{wave}}
\index{wave@{wave}!KImageEffect@{KImage\-Effect}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QImage} KImage\-Effect::wave ({\bf QImage} \& {\em src}, double {\em amplitude} = 25.0, double {\em frequency} = 150.0, unsigned int {\em background} = 0x\-FFFFFFFF)\hspace{0.3cm}{\tt  [static]}}\label{classKImageEffect_e40}


Modifies the pixels along a sine wave. 

\begin{Desc}
\item[Author:]Daniel M. Duley (mosfet) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em src}]The {\bf QImage} to process. \item[{\em amplitude}]The amplitude of the sine wave. \item[{\em wavelength}]The frequency of the sine wave. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The new image. The original is not changed. \end{Desc}


Definition at line 3072 of file kimageeffect.cpp.

References QImage::height(), QImage::scan\-Line(), and QImage::width().

The documentation for this class was generated from the following files:\begin{CompactItemize}
\item 
kimageeffect.h\item 
kimageeffect.cpp\end{CompactItemize}
