Interface to a set of brush preset parameter values, associated with a particular Brush Preset context.
Implemented by the plug-in.
#include <IBrushPresets.h>
Public Member Functions |
|
virtual | ~IBrushPresetParams () |
Destructor. |
|
virtual Class_ID | ContextID ()=0 |
Returns the ID of the brush preset context
associated with this parameter set. |
|
virtual void | ApplyParams ()=0 |
Applies the values from the parameter set
into the UI of the corresponding context. |
|
virtual void | FetchParams ()=0 |
Fetches the values from the UI of the
corresponding context into the parameter set. |
|
virtual int | GetNumParams ()=0 |
Returns the number of individual parameters
in the parameter set. |
|
virtual int | GetParamID (int paramIndex)=0 |
Translates the index number of a parameter
value into the corresponding parameter ID. |
|
virtual int | GetParamIndex (int paramID)=0 |
Translates the ID of a parameter value into
the corresponding parameter index number. |
|
virtual FPValue | GetParamValue (int paramID)=0 |
Returns a parameter value by ID. |
|
virtual void | SetParamValue (int paramID, FPValue val)=0 |
Sets a parameter value by ID. |
|
virtual FPValue | GetDisplayParamValue (int paramID) |
Returns the value of a parameter as it
should be displayed in the UI. |
|
virtual void | SetParent (IBrushPreset *parent)=0 |
Informs the parameter set of the brush
preset holding it. |
virtual ~IBrushPresetParams | ( | ) | [inline, virtual] |
Destructor.
{;}
virtual Class_ID ContextID | ( | ) | [pure virtual] |
Returns the ID of the brush preset context associated with this parameter set.
virtual void ApplyParams | ( | ) | [pure virtual] |
Applies the values from the parameter set into the UI of the corresponding context.
The parameter object is assumed to be part of the same plug-in as its context object, and to have knowledge of its state. The parameter object should apply its values into the UI as appropriate.
virtual void FetchParams | ( | ) | [pure virtual] |
Fetches the values from the UI of the corresponding context into the parameter set.
The parameter object is assumed to be part of the same plug-in as its context object, and to have knowledge of its state. The parameter object should fetch its values from the UI as appropriate.
virtual int GetNumParams | ( | ) | [pure virtual] |
Returns the number of individual parameters in the parameter set.
virtual int GetParamID | ( | int | paramIndex | ) | [pure virtual] |
Translates the index number of a parameter value into the corresponding parameter ID.
[in] | paramIndex | The index of the parameter value |
virtual int GetParamIndex | ( | int | paramID | ) | [pure virtual] |
Translates the ID of a parameter value into the corresponding parameter index number.
[in] | paramID | The ID of the parameter value |
virtual FPValue GetParamValue | ( | int | paramID | ) | [pure virtual] |
Returns a parameter value by ID.
[in] | paramID | The ID of the parameter value |
virtual void SetParamValue | ( | int | paramID, |
FPValue | val | ||
) | [pure virtual] |
Sets a parameter value by ID.
[in] | paramID | The ID of the parameter value |
[in] | val | The value to set |
virtual FPValue GetDisplayParamValue | ( | int | paramID | ) | [inline, virtual] |
Returns the value of a parameter as it should be displayed in the UI.
This is used to display values with a user-friendly format in the brush preset manager dialog. For example, a minimum and maximum value of 0 and 100 might be displayed together as one entry with the string value "0-100". In this case, the parameter set should return TYPE_VOID for the minimum and maximum display values, but provide a third, display-only parameter, with the string value.
[in] | paramID | The ID of the parameter value |
{return GetParamValue(paramID);}
virtual void SetParent | ( | IBrushPreset * | parent | ) | [pure virtual] |
Informs the parameter set of the brush preset holding it.
This is called by the system when parameter sets are created, to make them aware of the preset they are held by. No specific action is required by the parameter set.
[in] | parent | The brush preset parent which holds this parameter set. |