cohtml.Library
A class responsible for initializing the native Cohtml Library and rendering module. Creates, destroys and manages the native Cohtml plugin objects.
Public Functions
Section titled “Public Functions”| Name | |
|---|---|
| void | LoadModuleDependencies() Loads the dependencies of the Cohtml library. |
| void | RestoreProcessPath() Removes the plugin dll folder from the PATH environment variable. |
| void | SetDependenciesPath() Adds the plugin dll folder to the PATH environment variable. |
| IUISystem | CreateUISystem(ISystemSettings settings) Creates a native IUISystem object with the provided settings. |
| void | ExecuteCSharpBackendCommandBuffer() Executes the C# rendering backend command buffer if enabled. |
| void | Dispose() The Library is disposed of after all native Systems and Views, as well as their Cohtml references and objects, have already been destroyed. |
| void | ExecuteWork(WorkType type) Instructs the native library to execute the provided work type. |
| void | ScheduleWork(WorkType type) Schedules a task with the provided work type. |
| void | CreateLibrary() Initializes the native library object and its dependencies. |
Public Properties
Section titled “Public Properties”| Name | |
|---|---|
| UnityPluginListener | UnityPluginListener An instance the UnityPluginListener object. |
| ILibrary | Instance Returns a Singleton instance of the native ILibrary object. |
| Compositor | UnityCompositor An instance of the Compositor object allowing the user to use features such as Compositor and Surface Partitioning. |
Public Attributes
Section titled “Public Attributes”| Name | |
|---|---|
| UnityBackend | RenderingBackend Returns an instance of the current Unity3D rendering backend. |
| bool | ShouldUseCSharpBackend Returns true if the C# rendering backend should be used. |
| ILibraryParams | LibraryParams Returns the native LibraryParams object. |
| bool | IsLibraryInitialized Returns true if the library is successfully initialized. |
Public Functions Documentation
Section titled “Public Functions Documentation”function LoadModuleDependencies
Section titled “function LoadModuleDependencies”static void LoadModuleDependencies()Loads the dependencies of the Cohtml library.
function RestoreProcessPath
Section titled “function RestoreProcessPath”static void RestoreProcessPath()Removes the plugin dll folder from the PATH environment variable.
function SetDependenciesPath
Section titled “function SetDependenciesPath”static void SetDependenciesPath()Adds the plugin dll folder to the PATH environment variable.
function CreateUISystem
Section titled “function CreateUISystem”static IUISystem CreateUISystem( ISystemSettings settings)Creates a native IUISystem object with the provided settings.
function ExecuteCSharpBackendCommandBuffer
Section titled “function ExecuteCSharpBackendCommandBuffer”static void ExecuteCSharpBackendCommandBuffer()Executes the C# rendering backend command buffer if enabled.
function Dispose
Section titled “function Dispose”static void Dispose()The Library is disposed of after all native Systems and Views, as well as their Cohtml references and objects, have already been destroyed.
function ExecuteWork
Section titled “function ExecuteWork”static void ExecuteWork( WorkType type)Instructs the native library to execute the provided work type.
function ScheduleWork
Section titled “function ScheduleWork”static void ScheduleWork( WorkType type)Schedules a task with the provided work type.
function CreateLibrary
Section titled “function CreateLibrary”static void CreateLibrary()Initializes the native library object and its dependencies.
Public Property Documentation
Section titled “Public Property Documentation”property UnityPluginListener
Section titled “property UnityPluginListener”static UnityPluginListener UnityPluginListener;An instance the UnityPluginListener object.
property Instance
Section titled “property Instance”static ILibrary Instance;Returns a Singleton instance of the native ILibrary object.
property UnityCompositor
Section titled “property UnityCompositor”static Compositor UnityCompositor;An instance of the Compositor object allowing the user to use features such as Compositor and Surface Partitioning.
Public Attributes Documentation
Section titled “Public Attributes Documentation”variable RenderingBackend
Section titled “variable RenderingBackend”static UnityBackend RenderingBackend => s_Backend;Returns an instance of the current Unity3D rendering backend.
variable ShouldUseCSharpBackend
Section titled “variable ShouldUseCSharpBackend”static bool ShouldUseCSharpBackend => LibraryParamsManager.ShouldUseCSharpBackend;Returns true if the C# rendering backend should be used.
variable LibraryParams
Section titled “variable LibraryParams”static ILibraryParams LibraryParams => LibraryParamsManager.LibraryParams;Returns the native LibraryParams object.
variable IsLibraryInitialized
Section titled “variable IsLibraryInitialized”static bool IsLibraryInitialized => s_Library != null;Returns true if the library is successfully initialized.
© 2026 Coherent Labs. All rights reserved.