|
typedef void(* | ErrorHandlerFunc) (void *iData, int iLine, const char *iError, const char *iToken, size_t iTokenLen) |
| An error handler function type. More...
|
|
typedef void(* | ErrorHandlerFunc) (void *iData, int iLine, const char *iError, const char *iToken, size_t iTokenLen) |
| An error handler function type. More...
|
|
typedef void(* | ErrorHandlerFunc) (void *iData, int iLine, const char *iError, const char *iToken, size_t iTokenLen) |
| An error handler function type. More...
|
|
|
| CPreprocessor () |
| Create an empty preprocessor object. More...
|
|
| CPreprocessor () |
| Create an empty preprocessor object. More...
|
|
| CPreprocessor () |
| Create an empty preprocessor object. More...
|
|
virtual | ~CPreprocessor () |
| Destroy the preprocessor object. More...
|
|
virtual | ~CPreprocessor () |
| Destroy the preprocessor object. More...
|
|
virtual | ~CPreprocessor () |
| Destroy the preprocessor object. More...
|
|
void | Define (const char *iMacroName, size_t iMacroNameLen, const char *iMacroValue, size_t iMacroValueLen) |
| Define a macro without parameters. More...
|
|
void | Define (const char *iMacroName, size_t iMacroNameLen, const char *iMacroValue, size_t iMacroValueLen) |
| Define a macro without parameters. More...
|
|
void | Define (const char *iMacroName, size_t iMacroNameLen, const char *iMacroValue, size_t iMacroValueLen) |
| Define a macro without parameters. More...
|
|
void | Define (const char *iMacroName, size_t iMacroNameLen, long iMacroValue) |
| Define a numerical macro. More...
|
|
void | Define (const char *iMacroName, size_t iMacroNameLen, long iMacroValue) |
| Define a numerical macro. More...
|
|
void | Define (const char *iMacroName, size_t iMacroNameLen, long iMacroValue) |
| Define a numerical macro. More...
|
|
char * | Parse (const char *iSource, size_t iLength, size_t &oLength) |
| Parse the input string and return a newly-allocated output string. More...
|
|
char * | Parse (const char *iSource, size_t iLength, size_t &oLength) |
| Parse the input string and return a newly-allocated output string. More...
|
|
char * | Parse (const char *iSource, size_t iLength, size_t &oLength) |
| Parse the input string and return a newly-allocated output string. More...
|
|
bool | Undef (const char *iMacroName, size_t iMacroNameLen) |
| Undefine a macro. More...
|
|
bool | Undef (const char *iMacroName, size_t iMacroNameLen) |
| Undefine a macro. More...
|
|
bool | Undef (const char *iMacroName, size_t iMacroNameLen) |
| Undefine a macro. More...
|
|
This is a simplistic C/C++-like preprocessor.
It takes an non-zero-terminated string on input and outputs a non-zero-terminated string buffer.
This preprocessor was designed specifically for GLSL shaders, so if you want to use it for other purposes you might want to check if the feature set it provides is enough for you.
Here's a list of supported features:
-
Fast memory allocation-less operation (mostly).
-
Line continuation (backslash-newline) is swallowed.
-
Line numeration is fully preserved by inserting empty lines where required. This is crucial if, say, GLSL compiler reports you an error with a line number.
-
#define: Parametrized and non-parametrized macros. Invoking a macro with less arguments than it takes assignes empty values to missing arguments.
-
#undef: Forget defined macros
-
#ifdef/#ifndef/#else/#endif: Conditional suppression of parts of code.
-
#if: Supports numeric expression of any complexity, also supports the defined() pseudo-function.
takes an non-zero-terminated string on input and outputs a non-zero-terminated string buffer.
This preprocessor was designed specifically for GLSL shaders, so if you want to use it for other purposes you might want to check if the feature set it provides is enough for you.
Here's a list of supported features:
-
Fast memory allocation-less operation (mostly).
-
Line continuation (backslash-newline) is swallowed.
-
Line numeration is fully preserved by inserting empty lines where required. This is crucial if, say, GLSL compiler reports you an error with a line number.
-
#define: Parametrized and non-parametrized macros. Invoking a macro with less arguments than it takes assignes empty values to missing arguments.
-
#undef: Forget defined macros
-
#ifdef/#ifndef/#elif/#else/#endif: Conditional suppression of parts of code.
-
#if: Supports numeric expression of any complexity, also supports the defined() pseudo-function.
takes an non-zero-terminated string on input and outputs a non-zero-terminated string buffer.
This preprocessor was designed specifically for GLSL ES shaders, so if you want to use it for other purposes you might want to check if the feature set it provides is enough for you.
Here's a list of supported features:
-
Fast memory allocation-less operation (mostly).
-
Line continuation (backslash-newline) is swallowed.
-
Line numeration is fully preserved by inserting empty lines where required. This is crucial if, say, GLSL ES compiler reports you an error with a line number.
-
#define: Parametrized and non-parametrized macros. Invoking a macro with less arguments than it takes assignes empty values to missing arguments.
-
#undef: Forget defined macros
-
#ifdef/#ifndef/#else/#endif: Conditional suppression of parts of code.
-
#if: Supports numeric expression of any complexity, also supports the defined() pseudo-function.