|
Blender V5.3
|
#include <shader_nodes.h>
Public Types | |
| enum | Type { POINT = 0 , TEXTURE = 1 , VECTOR = 2 , NORMAL = 3 } |
| enum | Mapping { NONE = 0 , X = 1 , Y = 2 , Z = 3 } |
| enum | Projection { FLAT , CUBE , TUBE , SPHERE } |
Public Member Functions | |
| TextureMapping () | |
| Transform | compute_transform () |
| bool | skip () |
| void | compile (SVMCompiler &compiler, const SVMStackOffset offset_in, const SVMStackOffset offset_out, ShaderNode *node) |
| int | compile (SVMCompiler &compiler, ShaderInput *vector_in) |
| void | compile (OSLCompiler &compiler) |
| SVMStackOffset | compile_begin (SVMCompiler &compiler, ShaderInput *vector_in, ShaderNode *node) |
| void | compile_end (SVMCompiler &compiler, ShaderInput *vector_in, const SVMStackOffset vector_offset) |
Public Attributes | |
| float3 | translation |
| float3 | rotation |
| float3 | scale |
| float3 | min |
| float3 | max |
| bool | use_minmax |
| Type | type |
| Mapping | x_mapping |
| Mapping | y_mapping |
| Mapping | z_mapping |
| Projection | projection |
Definition at line 27 of file shader_nodes.h.
| Enumerator | |
|---|---|
| NONE | |
| X | |
| Y | |
| Z | |
Definition at line 54 of file shader_nodes.h.
| Enumerator | |
|---|---|
| FLAT | |
| CUBE | |
| TUBE | |
| SPHERE | |
Definition at line 57 of file shader_nodes.h.
| enum TextureMapping::Type |
| Enumerator | |
|---|---|
| POINT | |
| TEXTURE | |
| VECTOR | |
| NORMAL | |
Definition at line 51 of file shader_nodes.h.
|
default |
References compile(), compute_transform(), node, and skip().
| void TextureMapping::compile | ( | OSLCompiler & | compiler | ) |
Definition at line 236 of file shader_nodes.cpp.
References compute_transform(), OSLCompiler::parameter(), and skip().
| void TextureMapping::compile | ( | SVMCompiler & | compiler, |
| const SVMStackOffset | offset_in, | ||
| const SVMStackOffset | offset_out, | ||
| ShaderNode * | node ) |
Definition at line 168 of file shader_nodes.cpp.
References SVMCompiler::add_node(), compute_transform(), SVMCompiler::input_float3_from_offset(), max, min, node, NODE_VECTOR_MATH_NORMALIZE, NORMAL, SVM_STACK_INVALID, type, and use_minmax.
Referenced by compile(), compile_begin(), and TextureMapping().
| int TextureMapping::compile | ( | SVMCompiler & | compiler, |
| ShaderInput * | vector_in ) |
References compile(), compile_begin(), compile_end(), and node.
| SVMStackOffset TextureMapping::compile_begin | ( | SVMCompiler & | compiler, |
| ShaderInput * | vector_in, | ||
| ShaderNode * | node ) |
Definition at line 210 of file shader_nodes.cpp.
References assert, compile(), node, SocketType::POINT, skip(), SVMCompiler::stack_assign(), SVMCompiler::stack_find_offset(), ShaderIO::type(), and SocketType::VECTOR.
Referenced by compile().
| void TextureMapping::compile_end | ( | SVMCompiler & | compiler, |
| ShaderInput * | vector_in, | ||
| const SVMStackOffset | vector_offset ) |
Definition at line 227 of file shader_nodes.cpp.
References skip(), and SVMCompiler::stack_clear_offset().
Referenced by compile().
| Transform TextureMapping::compute_transform | ( | ) |
Definition at line 83 of file shader_nodes.cpp.
References fabsf, NONE, NORMAL, POINT, rotation, scale, signf(), TEXTURE, transform_euler(), transform_inverse(), transform_scale(), transform_translate(), transform_transposed_inverse(), translation, type, VECTOR, float3::x, x_mapping, float3::y, y_mapping, float3::z, z_mapping, and zero_float3().
Referenced by compile(), compile(), LightManager::device_update_background(), and TextureMapping().
| bool TextureMapping::skip | ( | ) |
Definition at line 146 of file shader_nodes.cpp.
References one_float3(), rotation, scale, translation, use_minmax, X, x_mapping, Y, y_mapping, Z, z_mapping, and zero_float3().
Referenced by compile(), compile_begin(), compile_end(), and TextureMapping().
| float3 TextureMapping::max |
Definition at line 48 of file shader_nodes.h.
Referenced by compile().
| float3 TextureMapping::min |
Definition at line 48 of file shader_nodes.h.
Referenced by compile().
| Projection TextureMapping::projection |
Definition at line 58 of file shader_nodes.h.
| float3 TextureMapping::rotation |
Definition at line 45 of file shader_nodes.h.
Referenced by compute_transform(), and skip().
| float3 TextureMapping::scale |
Definition at line 46 of file shader_nodes.h.
Referenced by compute_transform(), and skip().
| float3 TextureMapping::translation |
Definition at line 44 of file shader_nodes.h.
Referenced by compute_transform(), and skip().
| Type TextureMapping::type |
Definition at line 52 of file shader_nodes.h.
Referenced by compile(), and compute_transform().
| bool TextureMapping::use_minmax |
Definition at line 49 of file shader_nodes.h.
| Mapping TextureMapping::x_mapping |
Definition at line 55 of file shader_nodes.h.
Referenced by compute_transform(), and skip().
| Mapping TextureMapping::y_mapping |
Definition at line 55 of file shader_nodes.h.
Referenced by compute_transform(), and skip().
| Mapping TextureMapping::z_mapping |
Definition at line 55 of file shader_nodes.h.
Referenced by compute_transform(), and skip().