Class GLEnvironment
Namespace: ValveResourceFormat.Renderer
Assembly: Renderer.dll
OpenGL environment initialization and default render state configuration.
csharp
public static class GLEnvironmentInheritance
Fields
RequiredVersion
Minimum required OpenGL version (4.6).
csharp
public static readonly Version RequiredVersionField Value
Properties
GpuRendererAndDriver
Gets the GPU renderer name and driver version string.
csharp
public static string? GpuRendererAndDriver { get; }Property Value
IndirectCountSupported
Indicates whether indirect count draw calls are supported by the current driver.
csharp
public static bool IndirectCountSupported { get; }Property Value
Methods
Initialize(ILogger)
Initializes the OpenGL environment and queries capabilities.
csharp
public static void Initialize(ILogger logger)Parameters
logger ILogger
Logger for diagnostic output.
Exceptions
Thrown if the OpenGL version is too old.
SetDefaultRenderState()
Sets the default OpenGL render state for Source 2 rendering.
csharp
public static void SetDefaultRenderState()To3x4(Matrix4x4)
Converts a to an OpenTK Matrix3x4 by dropping the last row.
csharp
public static Matrix3x4 To3x4(this Matrix4x4 m)Parameters
Returns
ToOpenTK(Matrix4x4)
Converts a to an OpenTK Matrix4.
csharp
public static Matrix4 ToOpenTK(this Matrix4x4 m)
