webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
TranslatorHLSL Class Reference

#include <TranslatorHLSL.h>

Inheritance diagram for TranslatorHLSL:
TCompiler TShHandleBase

Public Member Functions

 TranslatorHLSL (sh::GLenum type, ShShaderSpec spec, ShShaderOutput output)
 
bool hasInterfaceBlock (const std::string &interfaceBlockName) const
 
unsigned int getInterfaceBlockRegister (const std::string &interfaceBlockName) const
 
const std::map< std::string, unsigned int > * getUniformRegisterMap () const
 
- Public Member Functions inherited from TCompiler
 TCompiler (sh::GLenum type, ShShaderSpec spec, ShShaderOutput output)
 
 ~TCompiler () override
 
TCompilergetAsCompiler () override
 
bool Init (const ShBuiltInResources &resources)
 
TIntermBlockcompileTreeForTesting (const char *const shaderStrings[], size_t numStrings, ShCompileOptions compileOptions)
 
bool compile (const char *const shaderStrings[], size_t numStrings, ShCompileOptions compileOptions)
 
int getShaderVersion () const
 
TInfoSinkgetInfoSink ()
 
bool isComputeShaderLocalSizeDeclared () const
 
const sh::WorkGroupSizegetComputeShaderLocalSize ()
 
void clearResults ()
 
const std::vector< sh::Attribute > & getAttributes () const
 
const std::vector< sh::OutputVariable > & getOutputVariables () const
 
const std::vector< sh::Uniform > & getUniforms () const
 
const std::vector< sh::Varying > & getVaryings () const
 
const std::vector< sh::InterfaceBlock > & getInterfaceBlocks () const
 
ShHashFunction64 getHashFunction () const
 
NameMapgetNameMap ()
 
TSymbolTablegetSymbolTable ()
 
ShShaderSpec getShaderSpec () const
 
ShShaderOutput getOutputType () const
 
const std::stringgetBuiltInResourcesString () const
 
bool shouldRunLoopAndIndexingValidation (ShCompileOptions compileOptions) const
 
const ShBuiltInResourcesgetResources () const
 
- Public Member Functions inherited from TShHandleBase
 TShHandleBase ()
 
virtual ~TShHandleBase ()
 

Protected Member Functions

void translate (TIntermNode *root, ShCompileOptions compileOptions) override
 
bool shouldFlattenPragmaStdglInvariantAll () override
 
bool shouldCollectVariables (ShCompileOptions compileOptions) override
 
- Protected Member Functions inherited from TCompiler
sh::GLenum getShaderType () const
 
bool InitBuiltInSymbolTable (const ShBuiltInResources &resources)
 
void setResourceString ()
 
bool checkCallDepth ()
 
bool validateOutputs (TIntermNode *root)
 
bool validateLimitations (TIntermNode *root)
 
void collectVariables (TIntermNode *root)
 
virtual void initBuiltInFunctionEmulator (BuiltInFunctionEmulator *emu, ShCompileOptions compileOptions)
 
bool enforcePackingRestrictions ()
 
void useAllMembersInUnusedStandardAndSharedBlocks (TIntermNode *root)
 
void initializeOutputVariables (TIntermNode *root)
 
void initializeGLPosition (TIntermNode *root)
 
bool limitExpressionComplexity (TIntermNode *root)
 
const TExtensionBehaviorgetExtensionBehavior () const
 
const char * getSourcePath () const
 
const TPragmagetPragma () const
 
void writePragma (ShCompileOptions compileOptions)
 
unsigned int * getTemporaryIndex ()
 
bool isVaryingDefined (const char *varyingName)
 
const ArrayBoundsClampergetArrayBoundsClamper () const
 
ShArrayIndexClampingStrategy getArrayIndexClampingStrategy () const
 
const BuiltInFunctionEmulatorgetBuiltInFunctionEmulator () const
 

Protected Attributes

std::map< std::string, unsigned int > mInterfaceBlockRegisterMap
 
std::map< std::string, unsigned int > mUniformRegisterMap
 
- Protected Attributes inherited from TCompiler
std::vector< sh::Attributeattributes
 
std::vector< sh::OutputVariableoutputVariables
 
std::vector< sh::Uniformuniforms
 
std::vector< sh::ShaderVariableexpandedUniforms
 
std::vector< sh::Varyingvaryings
 
std::vector< sh::InterfaceBlockinterfaceBlocks
 
bool variablesCollected
 
- Protected Attributes inherited from TShHandleBase
TPoolAllocator allocator
 

Constructor & Destructor Documentation

◆ TranslatorHLSL()

TranslatorHLSL::TranslatorHLSL ( sh::GLenum  type,
ShShaderSpec  spec,
ShShaderOutput  output 
)

Member Function Documentation

◆ getInterfaceBlockRegister()

unsigned int TranslatorHLSL::getInterfaceBlockRegister ( const std::string interfaceBlockName) const

◆ getUniformRegisterMap()

const std::map< std::string, unsigned int > * TranslatorHLSL::getUniformRegisterMap ( ) const

◆ hasInterfaceBlock()

bool TranslatorHLSL::hasInterfaceBlock ( const std::string interfaceBlockName) const

◆ shouldCollectVariables()

bool TranslatorHLSL::shouldCollectVariables ( ShCompileOptions  compileOptions)
inlineoverrideprotectedvirtual

Reimplemented from TCompiler.

◆ shouldFlattenPragmaStdglInvariantAll()

bool TranslatorHLSL::shouldFlattenPragmaStdglInvariantAll ( )
overrideprotectedvirtual

Implements TCompiler.

◆ translate()

void TranslatorHLSL::translate ( TIntermNode root,
ShCompileOptions  compileOptions 
)
overrideprotectedvirtual

Implements TCompiler.

Member Data Documentation

◆ mInterfaceBlockRegisterMap

std::map<std::string, unsigned int> TranslatorHLSL::mInterfaceBlockRegisterMap
protected

◆ mUniformRegisterMap

std::map<std::string, unsigned int> TranslatorHLSL::mUniformRegisterMap
protected

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