![]() |
ThorVG v1.0
|
A class that enables initialization and termination of the TVG engines. More...
#include <thorvg.h>
Static Public Member Functions | |
| static Result | init (uint32_t threads=0) noexcept |
| Initializes the ThorVG engine runtime. | |
| static Result | term () noexcept |
| Terminates the ThorVG engine. | |
| static const char * | version (uint32_t *major, uint32_t *minor, uint32_t *micro) noexcept |
| Retrieves the version of the TVG engine. | |
A class that enables initialization and termination of the TVG engines.
|
staticnoexcept |
Initializes the ThorVG engine runtime.
ThorVG requires an active runtime environment for rendering operations. This function sets up an internal task scheduler and creates a specified number of worker threads to enable parallel rendering.
| [in] | threads | The number of worker threads to launch. A value of 0 indicates that only the main thread will be used. |
|
staticnoexcept |
Terminates the ThorVG engine.
Cleans up resources and stops any internal threads initialized by init().
| Result::InsufficientCondition | Returned if there is nothing to terminate (e.g., init() was not called). |
|
staticnoexcept |
Retrieves the version of the TVG engine.
| [out] | major | A major version number. |
| [out] | minor | A minor version number. |
| [out] | micro | A micro version number. |
nullptr in case of an internal error.