|
| IlvGradientPattern (IlvDisplay *display, IlvColor *start, IlvColor *end, IlvDim width, IlvDim height, IlvGradientGeometry *geometry, IlvGradientSpread spread, const char *alias=0) |
| Constructor. More...
|
|
| IlvGradientPattern (IlvDisplay *display, IlvColorStop **colorStops, IlUInt nColorStops, IlvDim width, IlvDim height, IlvGradientGeometry *geometry, IlvGradientSpread spread, const char *alias=0) |
| Constructor. More...
|
|
void | addColorStop (IlvColorStop *colorStop) |
| Adds a color stop. More...
|
|
const char * | getAlias () const |
| Gets the alias of the gradient pattern. More...
|
|
IlvColorStop * | getColorStop (IlUInt index) const |
| Gets the color stop at the specified index. More...
|
|
IlUInt | getColorStopsCount () const |
| Gets the number of color stops of this gradient. More...
|
|
IlvGradientGeometry * | getGeometry () const |
| Gets the geometry of the gradient pattern. More...
|
|
IlvGradientSpread | getSpread () const |
| Gets the type of spread of the gradient pattern. More...
|
|
IlBoolean | removeColorStop (IlvColorStop *colorStop) |
| Removes a color stop. More...
|
|
void | setAlias (const char *alias) |
| Sets the alias of the gradient pattern. More...
|
|
IlBoolean | setColorStopOffset (IlvColorStop *colorStop, IlFloat offset) |
| Sets a color stop offset. More...
|
|
void | setGeometry (IlvGradientGeometry *geometry) |
| Sets the geometry of the gradient pattern. More...
|
|
void | setHeight (IlvDim height) |
| Sets the height of the gradient pattern. More...
|
|
void | setSpread (IlvGradientSpread spread) |
| Sets the type of spread of the gradient pattern. More...
|
|
void | setWidth (IlvDim width) |
| Sets the width of the gradient pattern. More...
|
|
| IlvPattern (IlvDisplay *display, IlvDim width, IlvDim height, unsigned char *data) |
| Constructor. More...
|
|
| IlvPattern (IlvBitmap *bitmap) |
| Constructor. More...
|
|
virtual IlUShort | depth () const |
| Retrieves the depth (number of bits that define a pixel value) of this pattern. More...
|
|
unsigned char * | getBitmapData (IlUInt &size) const |
| Retrieves the pixels of this pattern. More...
|
|
IlvDim | height () const |
| Retrieves the height of this pattern. More...
|
|
void | putBitmapData (unsigned char *data, IlUInt size) |
| Modifies the pixels of this pattern. More...
|
|
IlvDim | width () const |
| Retrieves the width of this pattern. More...
|
|
IlvDisplay * | getDisplay () const |
| Gets the IlvDisplay instance. More...
|
|
const char * | getName () const |
| Gets the resource name. More...
|
|
void | lock () |
| Locks the resource. More...
|
|
virtual void | setName (const char *name) |
| Sets the name of the resource. More...
|
|
virtual void | unLock () |
| Unlocks the resource. More...
|
|
Resource class.
Library: xviews or winviews or mviews (mutually exclusive)
Base class for gradient patterns. The IlvGradientPattern
class supports linear and radial gradients. The IlvGradientPattern
class is a subclass of IlvPattern
. The IlvPalette
class allows you to get and set the gradient pattern attribute using the following methods:
A dedicated fill style value exists for gradient patterns: IlvFillGradientPattern
. If you want to use your palette to draw gradients, set an instance of IlvGradientPattern
on the palette, and set the palette fill style to IlvFillGradientPattern
. Gradients can only be drawn if your application is properly set to use GDI+ or Cairo for rendering. The IlvGradientPattern
class has the following attributes:
-
A gradient geometry which defines the type of gradient desired and its parameters. The gradient geometry classes are:
IlvLinearGradientGeometry
and IlvRadialGradientGeometry
which both derive from the IlvGradientGeometry
class.
-
Width and height
-
The type of spread which indicates how the gradient should be drawn outside of its boundaries.
-
The color stops which are used to render the gradient. A color stop is defined by an
IlvColor
instance, an alpha value which defines the transparency to apply on this color, and an offset value between 0 and 1 which defines the position where the color should be used along the gradient. You must set at least 2 color stops on the gradient. See class IlvColorStop
for details.
-
An alias which is an optional attribute allowing you to control how the display will share the gradient pattern instance with the different palettes.
For more details, read the user manual section related to gradients.
- See also
IlvGradientGeometry
, IlvLinearGradientGeometry
, IlvRadialGradientGeometry
, IlvColorStop
.