MaterialX 1.38.2
SurfaceNodeGlsl.h
1//
2// TM & (c) 2017 Lucasfilm Entertainment Company Ltd. and Lucasfilm Ltd.
3// All rights reserved. See LICENSE.txt for license.
4//
5
6#ifndef MATERIALX_SURFACENODEGLSL_H
7#define MATERIALX_SURFACENODEGLSL_H
8
11
12namespace MaterialX
13{
14
16class MX_GENGLSL_API SurfaceNodeGlsl : public GlslImplementation
17{
18 public:
20
21 static ShaderNodeImplPtr create();
22
23 void createVariables(const ShaderNode& node, GenContext& context, Shader& shader) const override;
24
25 void emitFunctionCall(const ShaderNode& node, GenContext& context, ShaderStage& stage) const override;
26
27 virtual void emitLightLoop(const ShaderNode& node, GenContext& context, ShaderStage& stage, const string& outColor) const;
28
29 protected:
32 HwClosureContextPtr _callTransmission;
33 HwClosureContextPtr _callIndirect;
34 HwClosureContextPtr _callEmission;
35};
36
37} // namespace MaterialX
38
39#endif
GLSL shader generator.
shared_ptr< class HwClosureContext > HwClosureContextPtr
Shared pointer to a HwClosureContext.
Definition: HwShaderGenerator.h:229
Macros for declaring imported and exported symbols.
shared_ptr< ShaderNodeImpl > ShaderNodeImplPtr
Shared pointer to a ShaderNodeImpl.
Definition: Library.h:40
A context class for shader generation.
Definition: GenContext.h:27
Base class for common GLSL node implementations.
Definition: GlslShaderGenerator.h:93
Class containing all data needed during shader generation.
Definition: Shader.h:34
Class representing a node in the shader generation DAG.
Definition: ShaderNode.h:326
A shader stage, containing the state and resulting source code for the stage.
Definition: ShaderStage.h:124
Surface node implementation for GLSL.
Definition: SurfaceNodeGlsl.h:17
HwClosureContextPtr _callReflection
Closure contexts for calling closure functions.
Definition: SurfaceNodeGlsl.h:31