Runtime state management.
More...
| enum | SRPInterpolationMode { SRP_INTERPOLATION_MODE_PERSPECTIVE
, SRP_INTERPOLATION_MODE_AFFINE
} |
| |
| enum | SRPContextParameter { SRP_CONTEXT_MESSAGE_CALLBACK
, SRP_CONTEXT_MESSAGE_CALLBACK_USER_PARAMETER
, SRP_CONTEXT_INTERPOLATION_MODE
} |
| |
| typedef enum SRPInterpolationMode | SRPInterpolationMode |
| |
| typedef struct SRPContext | SRPContext |
| |
| typedef enum SRPContextParameter | SRPContextParameter |
| |
| void | srpNewContext (SRPContext *pContext) |
| |
| void | srpContextSetP (SRPContextParameter contextParameter, const void *data) |
| |
| void | srpContextSetI (SRPContextParameter contextParameter, int data) |
| |
| void * | srpContextGetP (SRPContextParameter contextParameter) |
| |
| int | srpContextGetI (SRPContextParameter contextParameter) |
| |
| enum | MessageType { SRP_MESSAGE_ERROR
, SRP_MESSAGE_WARNING
} |
| |
| enum | MessageSeverity { SRP_MESSAGE_SEVERITY_LOW
, SRP_MESSAGE_SEVERITY_MODERATE
, SRP_MESSAGE_SEVERITY_HIGH
} |
| |
| typedef enum MessageType | SRPMessageType |
| |
| typedef enum MessageSeverity | SRPMessageSeverity |
| |
| typedef void(* | SRPMessageCallbackType) (SRPMessageType type, SRPMessageSeverity severity, const char *sourceFunction, const char *message, void *userParameter) |
| |
Runtime state management.
◆ SRPContext
Holds runtime settings. This always needs to be declared as SRPContext srpContext in user programs and initialized with srpNewContext()
◆ SRPContextParameter
Possible arguments to srpContextSet...
◆ SRPInterpolationMode
Available attribute interpolation types
◆ SRPMessageCallbackType
A function of this type may be defined by user to handle the messages generated by the library (errors, warnings, etc.)
- See also
SRPContext
◆ SRPMessageSeverity
◆ SRPMessageType
◆ MessageSeverity
◆ MessageType
◆ SRPContextParameter
Possible arguments to srpContextSet...
◆ SRPInterpolationMode
Available attribute interpolation types
◆ srpContextGetI()
Get an integer/enum parameter in the context
- Parameters
-
| [in] | contextParameter | The context parameter you want to get |
- Returns
- Requested parameter or 0 on error
◆ srpContextGetP()
Get a pointer parameter in the context
- Parameters
-
| [in] | contextParameter | The context parameter you want to get |
- Returns
- Requested parameter or NULL on error
◆ srpContextSetI()
Set an integer/enum parameter in the context
- Parameters
-
| [in] | contextParameter | The context parameter you want to modify |
| [in] | data | The value you want to assign to specified context parameter |
◆ srpContextSetP()
Set a pointer parameter in the context
- Parameters
-
| [in] | contextParameter | The context parameter you want to modify |
| [in] | data | The pointer you want to assign to specified context parameter |
- Todo:
- Is this cast OK?
◆ srpNewContext()
Initialize the context
- Parameters
-
| [in] | pContext | The pointer to context |