rwlogo
Rogue Wave Views 5.6

Rogue Wave Views
Foundation Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

List of all members | Public Types | Public Member Functions
IlvBitmapDataKernel Class Reference

Kernel. More...

#include <ilviews/bitmaps/filters/kernel.h>

Inherits IlvValueInterface.

Public Types

enum  KernelHint { Normal, Nice }
 This enumeration defines the possible values for the hint. More...
 

Public Member Functions

 IlvBitmapDataKernel ()
 Constructor. More...
 
 IlvBitmapDataKernel (IlUInt width, IlUInt height, const IlFloat *values)
 Constructor. More...
 
 IlvBitmapDataKernel (IlUInt width, IlUInt height, const char *values)
 Constructor. More...
 
virtual ~IlvBitmapDataKernel ()
 Destructor. More...
 
IlUInt getHeight () const
 Returns the height of the kernel. More...
 
KernelHint getHints () const
 Returns the hints of the kernel. More...
 
const char * getKernelString ()
 Returns a string representation of the kernel. More...
 
const IlFloatgetKernelValues (IlUInt &width, IlUInt &height) const
 Returns an array of floating point values representing the kernel. More...
 
IlUInt getWidth () const
 Returns the width of the kernel. More...
 
void setHeight (IlUInt height)
 Sets the height of the kernel. More...
 
void setHints (KernelHint hints)
 Sets the given hints. More...
 
void setKernelString (const char *values)
 
void setValues (IlUInt width, IlUInt height, const IlFloat *values)
 Sets the kernel values using an array of floating point values. More...
 
void setValues (IlUInt width, IlUInt height, const char *values)
 
void setWidth (IlUInt width)
 Sets the width of the kernel. More...
 

Detailed Description

Kernel.

Library: ilvbmpflt

This class lets you manipulate kernels. A kernel is an m x n matrix. It is mainly used by the IlvConvolutionFilter.

For the Arithmetic operator each pixel is computed as follows:

result = k1 * c1 * c2 + k2 * c1 + k3 * c2 + k4
k1, k2, k3, and k4 can be specified.

See Also
IlvRGBBitmapData, IlvBitmapFilter, IlvConvolutionFilter, IlvGaussianBlurFilter

Member Enumeration Documentation

This enumeration defines the possible values for the hint.

Enumerator
Normal 

No particular hint.

Nice 

The kernel has positive values and the divisor is the sum of the coefficients.

Constructor & Destructor Documentation

IlvBitmapDataKernel::IlvBitmapDataKernel ( )

Constructor.

Initializes a new instance of the class IlvBitmapDataKernel.

IlvBitmapDataKernel::IlvBitmapDataKernel ( IlUInt  width,
IlUInt  height,
const IlFloat values 
)

Constructor.

Initializes a new instance of the class IlvBitmapDataKernel using an array of floating point values.

Parameters
widthThe width (columns) of the kernel.
heightThe height (rows) of the kernel.
valuesAn array of width x height values.
IlvBitmapDataKernel::IlvBitmapDataKernel ( IlUInt  width,
IlUInt  height,
const char *  values 
)

Constructor.

Initializes a new instance of the class IlvBitmapDataKernel using a string representing the values, separated by 'space' or ','. For example: "1 1 1 1 2 1 1 1 1" is a simple blurring kernel.

Parameters
widthThe width (columns) of the kernel.
heightThe height (rows) of the kernel.
valuesA string representing the values.
virtual IlvBitmapDataKernel::~IlvBitmapDataKernel ( )
virtual

Destructor.

The destructor releases all the memory used by the instance.

Member Function Documentation

IlUInt IlvBitmapDataKernel::getHeight ( ) const

Returns the height of the kernel.

Returns
The height of the kernel.
KernelHint IlvBitmapDataKernel::getHints ( ) const

Returns the hints of the kernel.

Returns
The hints of the kernel.
const char* IlvBitmapDataKernel::getKernelString ( )

Returns a string representation of the kernel.

Returns
A string representation of the kernel.
const IlFloat* IlvBitmapDataKernel::getKernelValues ( IlUInt width,
IlUInt height 
) const

Returns an array of floating point values representing the kernel.

Parameters
widthThe width of the kernel.
heightThe height of the kernel.
Returns
An array of width x height values.
IlUInt IlvBitmapDataKernel::getWidth ( ) const

Returns the width of the kernel.

Returns
The width of the kernel.
void IlvBitmapDataKernel::setHeight ( IlUInt  height)

Sets the height of the kernel.

Parameters
heightThe new height of the kernel.
void IlvBitmapDataKernel::setHints ( KernelHint  hints)

Sets the given hints.

Parameters
hintsThe new kernel hints.
void IlvBitmapDataKernel::setKernelString ( const char *  values)

Sets the kernel values using a string representation.

Parameters
valuesThe string representation of the new kernel.
void IlvBitmapDataKernel::setValues ( IlUInt  width,
IlUInt  height,
const IlFloat values 
)

Sets the kernel values using an array of floating point values.

Parameters
widthThe width (columns) of the kernel.
heightThe height (rows) of the kernel.
valuesAn array of width x height values.
void IlvBitmapDataKernel::setValues ( IlUInt  width,
IlUInt  height,
const char *  values 
)

short Sets the kernel values using a string representation.

Parameters
widthThe width (columns) of the kernel.
heightThe height (rows) of the kernel.
valuesA string representing the values.
void IlvBitmapDataKernel::setWidth ( IlUInt  width)

Sets the width of the kernel.

Parameters
widthThe new width of the kernel.

© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.