26#ifndef __ODGIPROCEDURALGENERATOR_H__
27#define __ODGIPROCEDURALGENERATOR_H__
88 kLinearInterpolation = 0,
369 static double linterp(
double a,
double b,
double t);
373 static double einterp(
double a,
double b,
double t);
377 static double cinterp(
double a,
double b,
double t);
381 static double ieinterp(
double a,
double b,
double t);
OdSmartPtr< OdGiProceduralGeneratorPE > OdGiProceduralGeneratorPEPtr
OdSmartPtr< OdGiProceduralGenerator > OdGiProceduralGeneratorPtr
void createGradient(ODCOLORREF color1, ODCOLORREF color2, OdUInt32 nColors, OdGiGradientGenerator::InterpolationType ipl=OdGiGradientGenerator::kLinearInterpolation)
OdUInt32Array m_colorGradient
OdUInt32 colorsCount() const
void fillInterval(ODCOLORREF color, double from=0.0, double to=1.0)
double toDoubleRange(OdUInt32 inVal) const
void createColorArrayFilled(ODCOLORREF color, OdUInt32 nColors)
static double cinterp(double a, double b, double t)
void generateInterval(ODCOLORREF color1, ODCOLORREF color2, OdUInt32 from, OdUInt32 to, OdGiGradientGenerator::InterpolationType ipl=OdGiGradientGenerator::kLinearInterpolation)
void copyGradient(const ODCOLORREF *colors, OdUInt32 nColors)
void createColorArray(OdUInt32 nColors)
static double linterp(double a, double b, double t)
void copyGradient(const OdUInt32Array &other)
ODCOLORREF colorAt(double at) const
OdGiGradientGenerator::AddressMode addressMode() const
void generateInterval(ODCOLORREF color1, ODCOLORREF color2, double from=0.0, double to=1.0, OdGiGradientGenerator::InterpolationType ipl=OdGiGradientGenerator::kLinearInterpolation)
static OdGiGradientGenerator createSpectrumGradient(OdUInt32 nColors, OdUInt8 alpha=0)
void createGradient(ODCOLORREF color1, ODCOLORREF color2, ODCOLORREF color3, ODCOLORREF color4, OdUInt32 nColors, OdGiGradientGenerator::InterpolationType ipl=OdGiGradientGenerator::kLinearInterpolation)
static double einterp(double a, double b, double t)
void createGradient(ODCOLORREF color1, ODCOLORREF color2, ODCOLORREF color3, OdUInt32 nColors, OdGiGradientGenerator::InterpolationType ipl1, OdGiGradientGenerator::InterpolationType ipl2)
const OdUInt32Array & asArray() const
bool isInitialized() const
void createGradient(ODCOLORREF color1, ODCOLORREF color2, ODCOLORREF color3, ODCOLORREF color4, ODCOLORREF color5, OdUInt32 nColors, OdGiGradientGenerator::InterpolationType ipl=OdGiGradientGenerator::kLinearInterpolation)
void appendGradient(const OdGiGradientGenerator &other)
OdUInt32 clampToRange(OdUInt32 inVal) const
AddressMode m_addressMode
ODCOLORREF colorAt(OdUInt32 nColor) const
void createGradient(ODCOLORREF color1, ODCOLORREF color2, ODCOLORREF color3, OdUInt32 nColors, OdGiGradientGenerator::InterpolationType ipl=OdGiGradientGenerator::kLinearInterpolation)
static ODCOLORREF interpolateColor(ODCOLORREF color1, ODCOLORREF color2, double at, OdGiGradientGenerator::InterpolationType ipl=OdGiGradientGenerator::kLinearInterpolation, OdGiGradientGenerator::AddressMode mode=OdGiGradientGenerator::kWrapMode)
void createGradient(ODCOLORREF color1, ODCOLORREF color2, ODCOLORREF color3, ODCOLORREF color4, OdUInt32 nColors, OdGiGradientGenerator::InterpolationType ipl1, OdGiGradientGenerator::InterpolationType ipl2, OdGiGradientGenerator::InterpolationType ipl3)
void createGradient(ODCOLORREF color1, ODCOLORREF color2, ODCOLORREF color3, ODCOLORREF color4, ODCOLORREF color5, OdUInt32 nColors, OdGiGradientGenerator::InterpolationType ipl1, OdGiGradientGenerator::InterpolationType ipl2, OdGiGradientGenerator::InterpolationType ipl3, OdGiGradientGenerator::InterpolationType ipl4)
static double ieinterp(double a, double b, double t)
OdGiGradientGenerator(const OdGiGradientGenerator &other)
void setAddressMode(OdGiGradientGenerator::AddressMode mode)
OdUInt32 clampToRange(double inVal) const
void fillInterval(ODCOLORREF color, OdUInt32 from, OdUInt32 to)
virtual void setColorGradient(const OdGiGradientGenerator &gradient)=0
virtual const OdGiGradientGenerator & colorGradient() const =0
virtual void generateProceduralWood(OdGiPixelBGRA32 color1, OdGiPixelBGRA32 color2, double radialNoise, double axialNoise, double grainThickness, OdGiImageBGRA32 &image, double renderCoef=1.0)=0
ODRX_DECLARE_MEMBERS(OdGiProceduralGenerator)
virtual void generateProceduralMarble(OdGiPixelBGRA32 stoneColor, OdGiPixelBGRA32 veinColor, double veinSpacing, double veinWidth, OdGiImageBGRA32 &image, double renderCoef=1.0)=0
virtual bool generateProceduralTexture(OdGiProceduralTexturePtr pTexture, OdGiImageBGRA32 &image, double renderCoef=1.0)=0
ODRX_DECLARE_MEMBERS(OdGiProceduralGeneratorPE)
OdGiProceduralGeneratorPE()
virtual bool generateProceduralTexture(OdGiProceduralTexturePtr pTexture, OdGiImageBGRA32 &image, double renderCoef=1.0)=0
GLfloat GLfloat GLfloat alpha