Module glsl

Source
Expand description

Backend for GLSL (OpenGL Shading Language).

The main structure is Writer, it maintains internal state that is used to output a Module into glsl

§Supported versions

§Core

  • 330
  • 400
  • 410
  • 420
  • 430
  • 450

§ES

  • 300
  • 310

Modules§

features 🔒
Contains the features related code and the features querying method
keywords 🔒
Contains a constant with a slice of all the reserved keywords RESERVED_KEYWORDS

Structs§

BindingMapSerialization 🔒
Features
Structure used to encode additions to GLSL that aren’t supported by all versions.
IdGenerator 🔒
Helper structure that generates a number
Options
Configuration used in the Writer.
PipelineOptions
A subset of options meant to be changed per pipeline.
PushConstantItem
All information to bind a single uniform value to the shader.
ReflectionInfo
Reflection info for texture mappings and uniforms.
ScalarString 🔒
Structure returned by glsl_scalar
TextureMapping
Mapping between a texture and its sampler, if it exists.
VaryingLocation
VaryingName 🔒
Helper wrapper used to get a name for a varying
VaryingOptions 🔒
Assorted options needed for generating varyings.
Writer
Writer responsible for all code generation.
WriterFlags
Configuration flags for the Writer.

Enums§

BinaryOperation 🔒
Binary operation with a different logic on the GLSL side.
Error
A GLSL compilation error.
Version
A GLSL version.

Constants§

CLAMPED_LOD_SUFFIX 🔒
The suffix of the variable that will hold the calculated clamped level of detail for bounds checking in ImageLoad
FIRST_INSTANCE_BINDING
FREXP_FUNCTION 🔒
MODF_FUNCTION 🔒
SUPPORTED_CORE_VERSIONS
List of supported core GLSL versions.
SUPPORTED_ES_VERSIONS
List of supported es GLSL versions.

Functions§

deserialize_binding_map 🔒
glsl_built_in 🔒
Helper function that returns the glsl variable name for a builtin
glsl_dimension 🔒
Helper function that returns the glsl dimension string of ImageDimension
glsl_interpolation 🔒
Helper function that returns the string corresponding to the glsl interpolation qualifier
glsl_sampling 🔒
Return the GLSL auxiliary qualifier for the given sampling value.
glsl_scalar 🔒
Helper function that returns scalar related strings
glsl_storage_format 🔒
Helper function that returns the glsl storage format string of StorageFormat
glsl_storage_qualifier 🔒
Helper function that returns the string corresponding to the address space
is_value_init_supported 🔒

Type Aliases§

BackendResult 🔒
Shorthand result used internally by the backend
BindingMap
Mapping between resources and bindings.