Rhino C++ API  7.19
Public Member Functions | Static Public Member Functions | List of all members
IRhRdkLinearWorkflow Class Referenceabstract

#include <IRhRdkLinearWorkflow.h>

Inheritance diagram for IRhRdkLinearWorkflow:
CRhRdkLinearWorkflow CRhRdkLinearWorkflowEx

Public Member Functions

virtual ~IRhRdkLinearWorkflow ()
 
virtual void ApplyPostProcessGamma (CRhinoDib &dibInOut) const =0
 
virtual void ApplyPreProcessGamma (CRhinoDib &dibInOut) const =0
 
virtual void ApplyPreProcessGamma (CRhRdkColor &col, bool bForTexture) const =0
 
virtual IRhRdkLinearWorkflowBeginChange (RhRdkChangeContext cc) const =0
 
virtual ON__UINT32 ComputeCRC (void) const =0
 
virtual void CopyFrom (const IRhRdkLinearWorkflow &lw)=0
 
virtual bool EndChange (void)=0
 
virtual void * EVF (const wchar_t *wszFunc, void *pvData)=0
 
virtual bool IsEqual (const IRhRdkLinearWorkflow &lw) const =0
 
virtual bool PostProcessFrameBuffer (void) const =0
 
virtual float PostProcessGamma (void) const =0
 
bool PostProcessGammaOn (void) const
 
virtual float PostProcessGammaReciprocal (void) const =0
 
virtual bool PreProcessColors (void) const =0
 
virtual float PreProcessGamma (void) const =0
 
virtual bool PreProcessTextures (void) const =0
 
virtual void SetPostProcessFrameBuffer (bool b)=0
 
virtual void SetPostProcessGamma (float f)=0
 
void SetPostProcessGammaOn (bool)
 
virtual void SetPreProcessColors (bool b)=0
 
virtual void SetPreProcessGamma (float f)=0
 
virtual void SetPreProcessTextures (bool b)=0
 

Static Public Member Functions

static IRhRdkLinearWorkflowNew (void)
 

Detailed Description

This is the interface to linear workflow settings.

See also
CRhRdkDocument::LinearWorkflow()

Constructor & Destructor Documentation

◆ ~IRhRdkLinearWorkflow()

virtual IRhRdkLinearWorkflow::~IRhRdkLinearWorkflow ( )
inlinevirtual

Member Function Documentation

◆ ApplyPostProcessGamma()

virtual void IRhRdkLinearWorkflow::ApplyPostProcessGamma ( CRhinoDib dibInOut) const
pure virtual

Modifies a DIB by applying gamma correction using the gamma reciprocal.

Note
This method replaces the NewGammaCorrectedBitmap() method.
Parameters
dibInOutis the DIB which is altered if gamma is not equal to 1.

Implemented in CRhRdkLinearWorkflowEx, and CRhRdkLinearWorkflow.

◆ ApplyPreProcessGamma() [1/2]

virtual void IRhRdkLinearWorkflow::ApplyPreProcessGamma ( CRhinoDib dibInOut) const
pure virtual

Applies pre-process gamma correction to a dib (i.e., an LDR texture) if PreProcessTextures is true.

Note
If this texture comes from a CRhRdkTexture, you should first check CRhRdkTexture::IsLinear(). If the texture is linear, it will require no further processing.

Implemented in CRhRdkLinearWorkflow.

◆ ApplyPreProcessGamma() [2/2]

virtual void IRhRdkLinearWorkflow::ApplyPreProcessGamma ( CRhRdkColor col,
bool  bForTexture 
) const
pure virtual

Applies pre-process gamma correction to a color if linear workflow is active.

Parameters
bForTextureis true if the color is part of a texture. See notes below for checking CRhRdkTexture::IsLinear().

Implemented in CRhRdkLinearWorkflow.

◆ BeginChange()

virtual IRhRdkLinearWorkflow& IRhRdkLinearWorkflow::BeginChange ( RhRdkChangeContext  cc) const
pure virtual

Call this method to get a non-const object upon which you can call non-const methods. Calls to this method are counted; you must call EndChange() once for every call to BeginChange(). Please do not use const_cast or any other means of circumventing this requirement.

Implemented in CRhRdkLinearWorkflow.

◆ ComputeCRC()

virtual ON__UINT32 IRhRdkLinearWorkflow::ComputeCRC ( void  ) const
pure virtual
Returns
CRC of gamma and linear workflow active state.

Implemented in CRhRdkLinearWorkflow.

◆ CopyFrom()

virtual void IRhRdkLinearWorkflow::CopyFrom ( const IRhRdkLinearWorkflow lw)
pure virtual

Copy another linear workflow object to this one.

Implemented in CRhRdkLinearWorkflow.

◆ EndChange()

virtual bool IRhRdkLinearWorkflow::EndChange ( void  )
pure virtual

Implemented in CRhRdkLinearWorkflow.

◆ EVF()

virtual void* IRhRdkLinearWorkflow::EVF ( const wchar_t *  wszFunc,
void *  pvData 
)
pure virtual

Emergency virtual function for future expansion. Currently implemented wszFunc: "PostProcessGammaOn" (pvData = null; returns pointer to bool). "SetPostProcessGammaOn" (pvData is pointer to bool).

Implemented in CRhRdkLinearWorkflowEx, and CRhRdkLinearWorkflow.

◆ IsEqual()

virtual bool IRhRdkLinearWorkflow::IsEqual ( const IRhRdkLinearWorkflow lw) const
pure virtual
Returns
true if this object is equal to another one.

Implemented in CRhRdkLinearWorkflow.

◆ New()

static IRhRdkLinearWorkflow* IRhRdkLinearWorkflow::New ( void  )
static

◆ PostProcessFrameBuffer()

virtual bool IRhRdkLinearWorkflow::PostProcessFrameBuffer ( void  ) const
pure virtual
Returns
whether the frame buffer should be gamma corrected.

Implemented in CRhRdkLinearWorkflow.

◆ PostProcessGamma()

virtual float IRhRdkLinearWorkflow::PostProcessGamma ( void  ) const
pure virtual
Returns
post-process gamma for frame buffer. This is not the value applied, this is the value that appears in the UI.
See also
PostProcessGammaReciprocal().

Implemented in CRhRdkLinearWorkflow.

◆ PostProcessGammaOn()

bool IRhRdkLinearWorkflow::PostProcessGammaOn ( void  ) const

◆ PostProcessGammaReciprocal()

virtual float IRhRdkLinearWorkflow::PostProcessGammaReciprocal ( void  ) const
pure virtual
Returns
gamma reciprocal for frame buffer. This is the value that is applied to each color channel for post-process and is supplied here as an optimization.

Implemented in CRhRdkLinearWorkflow.

◆ PreProcessColors()

virtual bool IRhRdkLinearWorkflow::PreProcessColors ( void  ) const
pure virtual
Returns
linear workflow active state for individual colors.

Implemented in CRhRdkLinearWorkflow.

◆ PreProcessGamma()

virtual float IRhRdkLinearWorkflow::PreProcessGamma ( void  ) const
pure virtual
Returns
pre-process gamma for input textures and colors.

Implemented in CRhRdkLinearWorkflow.

◆ PreProcessTextures()

virtual bool IRhRdkLinearWorkflow::PreProcessTextures ( void  ) const
pure virtual
Returns
linear workflow active state for textures (also check IsLinear()).

Implemented in CRhRdkLinearWorkflow.

◆ SetPostProcessFrameBuffer()

virtual void IRhRdkLinearWorkflow::SetPostProcessFrameBuffer ( bool  b)
pure virtual

Set linear workflow (pre-process) active state for individual colors.

Implemented in CRhRdkLinearWorkflow.

◆ SetPostProcessGamma()

virtual void IRhRdkLinearWorkflow::SetPostProcessGamma ( float  f)
pure virtual

Set post-process gamma. This will generally be >= 1.0 (usually 2.2). The actual value to be applied in post-process is the reciprocal.

Implemented in CRhRdkLinearWorkflow.

◆ SetPostProcessGammaOn()

void IRhRdkLinearWorkflow::SetPostProcessGammaOn ( bool  )

◆ SetPreProcessColors()

virtual void IRhRdkLinearWorkflow::SetPreProcessColors ( bool  b)
pure virtual

Set linear workflow (pre-process) active state for individual colors.

Implemented in CRhRdkLinearWorkflow.

◆ SetPreProcessGamma()

virtual void IRhRdkLinearWorkflow::SetPreProcessGamma ( float  f)
pure virtual

Set pre-process gamma. This will generally be >= 1.0 (usually 2.2). This is the actual value applied in pre-process.

Implemented in CRhRdkLinearWorkflow.

◆ SetPreProcessTextures()

virtual void IRhRdkLinearWorkflow::SetPreProcessTextures ( bool  b)
pure virtual

Set linear workflow (pre-process) active state for textures.

Implemented in CRhRdkLinearWorkflow.