ACMX 2.139.0
Dual-Backend Real-Time GPU Video Synthesis
Loading...
Searching...
No Matches
ShaderCacheEntry Struct Reference

One shader's precompiled binary data for the on-disk cache. More...

Public Attributes

std::vector< char > binary_2d
 GL program binary (2D vertex shader).
std::vector< char > binary_3d
 GL program binary (3D vertex shader).
bool failed = false
 True if this shader failed to compile; a passthrough program is substituted at load time to preserve the user-visible shader index.
GLenum format_2d = 0
 GL binary format token for 2D.
GLenum format_3d = 0
 GL binary format token for 3D.
ShaderProgramKind kind = ShaderProgramKind::Fragment
std::string shader_name
 Stem of the .glsl filename.
uint64_t source_hash = 0
 FNV-1a-64 hash of the fragment source.

Detailed Description

One shader's precompiled binary data for the on-disk cache.

Stores the GL program binary for a fragment or compute shader, plus an FNV-1a hash of the source file so stale entries are detected on load. Fragment entries can contain both 2D and 3D variants; compute entries use binary_2d for their standalone program and use a 3D passthrough slot.

Definition at line 2573 of file ACMX2/acmx.cpp.

Member Data Documentation

◆ binary_2d

std::vector<char> ShaderCacheEntry::binary_2d

GL program binary (2D vertex shader).

Definition at line 2575 of file ACMX2/acmx.cpp.

Referenced by ShaderLibrary::buildShaderCache(), and ShaderLibrary::compileShaderCacheEntry().

◆ binary_3d

std::vector<char> ShaderCacheEntry::binary_3d

GL program binary (3D vertex shader).

Definition at line 2577 of file ACMX2/acmx.cpp.

Referenced by ShaderLibrary::buildShaderCache(), and ShaderLibrary::compileShaderCacheEntry().

◆ failed

bool ShaderCacheEntry::failed = false

True if this shader failed to compile; a passthrough program is substituted at load time to preserve the user-visible shader index.

Definition at line 2581 of file ACMX2/acmx.cpp.

Referenced by ShaderLibrary::buildShaderCache(), and ShaderLibrary::compileShaderCacheEntry().

◆ format_2d

GLenum ShaderCacheEntry::format_2d = 0

GL binary format token for 2D.

Definition at line 2576 of file ACMX2/acmx.cpp.

Referenced by ShaderLibrary::buildShaderCache(), and ShaderLibrary::compileShaderCacheEntry().

◆ format_3d

GLenum ShaderCacheEntry::format_3d = 0

GL binary format token for 3D.

Definition at line 2578 of file ACMX2/acmx.cpp.

Referenced by ShaderLibrary::buildShaderCache(), and ShaderLibrary::compileShaderCacheEntry().

◆ kind

Definition at line 2580 of file ACMX2/acmx.cpp.

Referenced by ShaderLibrary::compileShaderCacheEntry().

◆ shader_name

std::string ShaderCacheEntry::shader_name

Stem of the .glsl filename.

Definition at line 2574 of file ACMX2/acmx.cpp.

Referenced by ShaderLibrary::buildShaderCache(), and ShaderLibrary::compileShaderCacheEntry().

◆ source_hash

uint64_t ShaderCacheEntry::source_hash = 0

FNV-1a-64 hash of the fragment source.

Definition at line 2579 of file ACMX2/acmx.cpp.

Referenced by ShaderLibrary::buildShaderCache(), and ShaderLibrary::compileShaderCacheEntry().


The documentation for this struct was generated from the following file: