PDFix SDK  6.9.0
PdfColor Struct Referenceabstract

PdfColor class. More...

Public Member Functions

virtual PdfColorSpaceGetColorSpace ()=0
 Gets the color space. More...
 
virtual void SetColorSpace (PdfColorSpace *color_space)=0
 Sets the the color space. More...
 
virtual double GetValue (int index)=0
 Gets the specific value of the color at index. More...
 
virtual void SetValue (int index, double value)=0
 Sets the specific value of the color at index. More...
 
virtual bool GetRGB (PdfRGB *rgb)=0
 Convinience function to get RGB values of the color. More...
 
virtual bool GetCMYK (PdfCMYK *cmyk)=0
 Convinience function to get CMYK values of the color. More...
 
virtual bool GetGrayscale (PdfGray *gray)=0
 Convinience function to get gray value of the color. More...
 
virtual void Destroy ()=0
 Destroys color's resources. More...
 

Detailed Description

PdfColor class.

The PdfColor.

Member Function Documentation

◆ Destroy()

virtual void PdfColor::Destroy ( )
pure virtual

Destroys color's resources.

See also
PdfColorSpace::CreateColor

◆ GetCMYK()

virtual bool PdfColor::GetCMYK ( PdfCMYK cmyk)
pure virtual

Convinience function to get CMYK values of the color.

Parameters
cmykCMYK structure that will be filled by the function.
Returns
true if the conversion to CMYK was successfull.

◆ GetColorSpace()

virtual PdfColorSpace* PdfColor::GetColorSpace ( )
pure virtual

Gets the color space.

ƒ√

Returns
The color space.

◆ GetGrayscale()

virtual bool PdfColor::GetGrayscale ( PdfGray gray)
pure virtual

Convinience function to get gray value of the color.

Parameters
grayGrayscale structure that will be filled by the function.
Returns
true if the conversion to Grayscale was successfull.

◆ GetRGB()

virtual bool PdfColor::GetRGB ( PdfRGB rgb)
pure virtual

Convinience function to get RGB values of the color.

Parameters
rgbRGB structure that will be filled by the function.
Returns
true if the conversion to RGB was successfull.

◆ GetValue()

virtual double PdfColor::GetValue ( int  index)
pure virtual

Gets the specific value of the color at index.

Parameters
indexMust be smaller than components count of the colorspace.
Returns
Color value at the index, usually between 0.0 and 1.0.

◆ SetColorSpace()

virtual void PdfColor::SetColorSpace ( PdfColorSpace color_space)
pure virtual

Sets the the color space.

Parameters
color_spaceColor space to be set. Must not be nullptr.

◆ SetValue()

virtual void PdfColor::SetValue ( int  index,
double  value 
)
pure virtual

Sets the specific value of the color at index.

Parameters
indexMust be smaller than components count of the colorspace.
valueNew value to be set.