Data Structures | Functions
Shader Globals API

AtShaderGlobals structure contains data accessible during the shading process. More...

Data Structures

struct  AtShaderGlobals
 Shader globals data structure. More...
 

Functions

AI_API AtShaderGlobalsAiShaderGlobals ()
 Allocate and initialize an AtShaderGlobals structure (a shading context) More...
 
AI_API void AiShaderGlobalsDestroy (AtShaderGlobals *sg)
 Deallocate an AtShaderGlobals struct. More...
 

Shading Contexts

These macros let you determine the purpose that the shader globals were defined for.

#define AI_CONTEXT_SURFACE   0x00
 for ray-surface intersections
 
#define AI_CONTEXT_VOLUME   0x01
 for volume points during ray-marching
 
#define AI_CONTEXT_BACKGROUND   0x02
 for rays that don't hit any geometry
 
#define AI_CONTEXT_DISPLACEMENT   0x03
 for each vertex to be displaced
 
#define AI_CONTEXT_IMPORTANCE   0x05
 for importance sample table evaluations
 

Detailed Description

AtShaderGlobals structure contains data accessible during the shading process.

Function Documentation

AI_API AtShaderGlobals* AiShaderGlobals ( )

Allocate and initialize an AtShaderGlobals structure (a shading context)

Returns
a new AtShaderGlobals object
AI_API void AiShaderGlobalsDestroy ( AtShaderGlobals sg)

Deallocate an AtShaderGlobals struct.

Parameters
sga shader globals context

© 2020 Autodesk, Inc. · All rights reserved · www.arnoldrenderer.com