HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HdSt_TextureBinder Class Reference

#include <textureBinder.h>

Public Types

using NamedTextureHandle = HdStShaderCode::NamedTextureHandle
 
using NamedTextureHandleVector = HdStShaderCode::NamedTextureHandleVector
 

Static Public Member Functions

static void GetBufferSpecs (const NamedTextureHandleVector &textures, HdBufferSpecVector *specs, bool doublesSupported)
 
static void ComputeBufferSources (const NamedTextureHandleVector &textures, HdBufferSourceSharedPtrVector *sources, bool doublesSupported)
 
static void BindResources (HdSt_ResourceBinder const &binder, const NamedTextureHandleVector &textures)
 
static void UnbindResources (HdSt_ResourceBinder const &binder, const NamedTextureHandleVector &textures)
 
static void GetBindingDescs (HdSt_ResourceBinder const &binder, HgiResourceBindingsDesc *bindingsDesc, const NamedTextureHandleVector &textures)
 

Detailed Description

A class helping HdStShaderCode with binding textures.

This class helps binding textures or populating the shader bar with texture sampler handles if bindless textures are used. It also includes writing texture metadata such as the sampling transform to the shader bar.

Definition at line 45 of file textureBinder.h.

Member Typedef Documentation

Member Function Documentation

static void HdSt_TextureBinder::BindResources ( HdSt_ResourceBinder const binder,
const NamedTextureHandleVector textures 
)
static

Bind textures.

static void HdSt_TextureBinder::ComputeBufferSources ( const NamedTextureHandleVector textures,
HdBufferSourceSharedPtrVector sources,
bool  doublesSupported 
)
static

Compute buffer sources for shader bar.

This works in conjunction with GetBufferSpecs, but unlike GetBufferSpecs is extracting information from the texture handles and thus can only be called after the textures have been committed in HdStShaderCode::AddResourcesFromTextures().

static void HdSt_TextureBinder::GetBindingDescs ( HdSt_ResourceBinder const binder,
HgiResourceBindingsDesc bindingsDesc,
const NamedTextureHandleVector textures 
)
static

Get Bindings Descs

static void HdSt_TextureBinder::GetBufferSpecs ( const NamedTextureHandleVector textures,
HdBufferSpecVector specs,
bool  doublesSupported 
)
static

Add buffer specs necessary for the textures (e.g., for bindless texture sampler handles or sampling transform).

static void HdSt_TextureBinder::UnbindResources ( HdSt_ResourceBinder const binder,
const NamedTextureHandleVector textures 
)
static

Unbind textures.


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