7#ifndef PXR_IMAGING_HD_ST_MATERIAL_NETWORK_H
8#define PXR_IMAGING_HD_ST_MATERIAL_NETWORK_H
11#include "pxr/imaging/hdSt/api.h"
12#include "pxr/imaging/hdSt/enums.h"
13#include "pxr/imaging/hd/material.h"
14#include "pxr/imaging/hdSt/textureIdentifier.h"
17#ifdef PXR_MATERIALX_SUPPORT_ENABLED
18#include <MaterialXGenShader/Shader.h>
21PXR_NAMESPACE_OPEN_SCOPE
24using HioGlslfxSharedPtr = std::shared_ptr<class HioGlslfx>;
25using HdSt_MaterialParamVector = std::vector<class HdSt_MaterialParam>;
49 TfToken const& GetMaterialTag()
const;
52 std::string
const& GetFragmentCode()
const;
55 std::string
const& GetVolumeCode()
const;
58 std::string
const& GetDisplacementCode()
const;
64 HdSt_MaterialParamVector
const& GetMaterialParams()
const;
67 struct TextureDescriptor
85 bool useTexturePrimToFindTexture;
90 using TextureDescriptorVector = std::vector<TextureDescriptor>;
93 TextureDescriptorVector
const& GetTextureDescriptors()
const;
97 std::string _fragmentSource;
98 std::string _volumeSource;
99 std::string _displacementSource;
101 HdSt_MaterialParamVector _materialParams;
102 TextureDescriptorVector _textureDescriptors;
103 HioGlslfxSharedPtr _surfaceGfx;
104 size_t _surfaceGfxHash;
105#ifdef PXR_MATERIALX_SUPPORT_ENABLED
106 MaterialX::ShaderPtr _materialXGfx;
112PXR_NAMESPACE_CLOSE_SCOPE
Collection of standard parameters such as wrap modes to sample a texture.
Helps HdStMaterial process a Hydra material network into shader source code and parameters values.
HDST_API void ProcessMaterialNetwork(SdfPath const &materialId, HdMaterialNetworkMap const &hdNetworkMap, HdStResourceRegistry *resourceRegistry)
Process a material network topology and extract all the information we need from it.
A central registry of all GPU resources.
Class to identify a texture file or a texture within the texture file (e.g., a frame in a movie).
A path value used to locate objects in layers or scenegraphs.
Token for efficient comparison, assignment, and hashing of known strings.
A map with string keys and VtValue values.
Describes a map from network type to network.