Blender V4.3
GPU_material.hh File Reference
#include <string>
#include "DNA_customdata_types.h"
#include "DNA_image_types.h"
#include "DNA_listBase.h"
#include "BLI_sys_types.h"
#include "GPU_shader.hh"
#include "GPU_texture.hh"

Go to the source code of this file.

Classes

struct  GPUNodeStack
 
struct  GPUCodegenOutput
 
struct  GPUMaterialAttribute
 
struct  GPUMaterialTexture
 
struct  GPUUniformAttr
 
struct  GPUUniformAttrList
 
struct  GPULayerAttr
 

Typedefs

using GPUCodegenCallbackFn = void (*)(void *thunk, GPUMaterial *mat, GPUCodegenOutput *codegen)
 
using GPUMaterialPassReplacementCallbackFn = GPUPass *(*)(void *thunk, GPUMaterial *mat)
 
using ConstructGPUMaterialFn = void (*)(void *thunk, GPUMaterial *material)
 

Enumerations

enum  eGPUType {
  GPU_NONE = 0 , GPU_FLOAT = 1 , GPU_VEC2 = 2 , GPU_VEC3 = 3 ,
  GPU_VEC4 = 4 , GPU_MAT3 = 9 , GPU_MAT4 = 16 , GPU_MAX_CONSTANT_DATA = GPU_MAT4 ,
  GPU_TEX1D_ARRAY = 1001 , GPU_TEX2D = 1002 , GPU_TEX2D_ARRAY = 1003 , GPU_TEX3D = 1004 ,
  GPU_CLOSURE = 1007 , GPU_ATTR = 3001
}
 
enum  eGPUMaterialFlag {
  GPU_MATFLAG_DIFFUSE = (1 << 0) , GPU_MATFLAG_SUBSURFACE = (1 << 1) , GPU_MATFLAG_GLOSSY = (1 << 2) , GPU_MATFLAG_REFRACT = (1 << 3) ,
  GPU_MATFLAG_EMISSION = (1 << 4) , GPU_MATFLAG_TRANSPARENT = (1 << 5) , GPU_MATFLAG_HOLDOUT = (1 << 6) , GPU_MATFLAG_SHADER_TO_RGBA = (1 << 7) ,
  GPU_MATFLAG_AO = (1 << 8) , GPU_MATFLAG_COAT = (1 << 9) , GPU_MATFLAG_TRANSLUCENT = (1 << 10) , GPU_MATFLAG_VOLUME_SCATTER = (1 << 16) ,
  GPU_MATFLAG_VOLUME_ABSORPTION = (1 << 17) , GPU_MATFLAG_OBJECT_INFO = (1 << 18) , GPU_MATFLAG_AOV = (1 << 19) , GPU_MATFLAG_BARYCENTRIC = (1 << 20) ,
  GPU_MATFLAG_UPDATED = (1 << 29) , GPU_MATFLAG_LOOKDEV_HACK = (1 << 30)
}
 
enum  eGPUMaterialStatus { GPU_MAT_FAILED = 0 , GPU_MAT_CREATED , GPU_MAT_QUEUED , GPU_MAT_SUCCESS }
 
enum  eGPUMaterialOptimizationStatus { GPU_MAT_OPTIMIZATION_SKIP = 0 , GPU_MAT_OPTIMIZATION_READY , GPU_MAT_OPTIMIZATION_QUEUED , GPU_MAT_OPTIMIZATION_SUCCESS }
 
enum  eGPUDefaultValue { GPU_DEFAULT_0 = 0 , GPU_DEFAULT_1 }
 
enum  eGPUMaterialEngine { GPU_MAT_EEVEE_LEGACY = 0 , GPU_MAT_EEVEE , GPU_MAT_COMPOSITOR }
 

Functions

 ENUM_OPERATORS (eGPUMaterialFlag, GPU_MATFLAG_LOOKDEV_HACK)
 
GPUNodeLinkGPU_constant (const float *num)
 
GPUNodeLinkGPU_uniform (const float *num)
 
GPUNodeLinkGPU_attribute (GPUMaterial *mat, eCustomDataType type, const char *name)
 
GPUNodeLinkGPU_attribute_default_color (GPUMaterial *mat)
 
GPUNodeLinkGPU_attribute_hair_length (GPUMaterial *mat)
 
GPUNodeLinkGPU_attribute_with_default (GPUMaterial *mat, eCustomDataType type, const char *name, eGPUDefaultValue default_value)
 
GPUNodeLinkGPU_uniform_attribute (GPUMaterial *mat, const char *name, bool use_dupli, uint32_t *r_hash)
 
GPUNodeLinkGPU_layer_attribute (GPUMaterial *mat, const char *name)
 
GPUNodeLinkGPU_image (GPUMaterial *mat, Image *ima, ImageUser *iuser, GPUSamplerState sampler_state)
 
void GPU_image_tiled (GPUMaterial *mat, Image *ima, ImageUser *iuser, GPUSamplerState sampler_state, GPUNodeLink **r_image_tiled_link, GPUNodeLink **r_image_tiled_mapping_link)
 
GPUNodeLinkGPU_image_sky (GPUMaterial *mat, int width, int height, const float *pixels, float *layer, GPUSamplerState sampler_state)
 
GPUNodeLinkGPU_color_band (GPUMaterial *mat, int size, float *pixels, float *r_row)
 
GPUNodeLinkGPU_differentiate_float_function (const char *function_name)
 
bool GPU_link (GPUMaterial *mat, const char *name,...)
 
bool GPU_stack_link (GPUMaterial *mat, const bNode *node, const char *name, GPUNodeStack *in, GPUNodeStack *out,...)
 
void GPU_material_output_surface (GPUMaterial *material, GPUNodeLink *link)
 
void GPU_material_output_volume (GPUMaterial *material, GPUNodeLink *link)
 
void GPU_material_output_displacement (GPUMaterial *material, GPUNodeLink *link)
 
void GPU_material_output_thickness (GPUMaterial *material, GPUNodeLink *link)
 
void GPU_material_add_output_link_aov (GPUMaterial *material, GPUNodeLink *link, int hash)
 
void GPU_material_add_output_link_composite (GPUMaterial *material, GPUNodeLink *link)
 
char * GPU_material_split_sub_function (GPUMaterial *material, eGPUType return_type, GPUNodeLink **link)
 
bool GPU_material_sss_profile_create (GPUMaterial *material, float radii[3])
 
GPUMaterialGPU_material_from_nodetree (Scene *scene, Material *ma, bNodeTree *ntree, ListBase *gpumaterials, const char *name, eGPUMaterialEngine engine, uint64_t shader_uuid, bool is_volume_shader, bool is_lookdev, GPUCodegenCallbackFn callback, void *thunk, GPUMaterialPassReplacementCallbackFn pass_replacement_cb=nullptr)
 
void GPU_material_compile (GPUMaterial *mat)
 
void GPU_material_free_single (GPUMaterial *material)
 
void GPU_material_free (ListBase *gpumaterial)
 
void GPU_material_async_compile (GPUMaterial *mat)
 
bool GPU_material_async_try_finalize (GPUMaterial *mat)
 
void GPU_material_acquire (GPUMaterial *mat)
 
void GPU_material_release (GPUMaterial *mat)
 
void GPU_materials_free (Main *bmain)
 
SceneGPU_material_scene (GPUMaterial *material)
 
GPUPassGPU_material_get_pass (GPUMaterial *material)
 
GPUShaderGPU_material_get_shader (GPUMaterial *material)
 
GPUShaderGPU_material_get_shader_base (GPUMaterial *material)
 
const char * GPU_material_get_name (GPUMaterial *material)
 
void GPU_material_optimize (GPUMaterial *mat)
 
MaterialGPU_material_get_material (GPUMaterial *material)
 
eGPUMaterialStatus GPU_material_status (GPUMaterial *mat)
 
void GPU_material_status_set (GPUMaterial *mat, eGPUMaterialStatus status)
 
eGPUMaterialOptimizationStatus GPU_material_optimization_status (GPUMaterial *mat)
 
void GPU_material_optimization_status_set (GPUMaterial *mat, eGPUMaterialOptimizationStatus status)
 
bool GPU_material_optimization_ready (GPUMaterial *mat)
 
void GPU_material_set_default (GPUMaterial *material, GPUMaterial *default_material)
 
GPUUniformBuf * GPU_material_uniform_buffer_get (GPUMaterial *material)
 
void GPU_material_uniform_buffer_create (GPUMaterial *material, ListBase *inputs)
 
bool GPU_material_has_surface_output (GPUMaterial *mat)
 
bool GPU_material_has_volume_output (GPUMaterial *mat)
 
bool GPU_material_has_displacement_output (GPUMaterial *mat)
 
void GPU_material_flag_set (GPUMaterial *mat, eGPUMaterialFlag flag)
 
bool GPU_material_flag_get (const GPUMaterial *mat, eGPUMaterialFlag flag)
 
eGPUMaterialFlag GPU_material_flag (const GPUMaterial *mat)
 
bool GPU_material_recalc_flag_get (GPUMaterial *mat)
 
uint64_t GPU_material_uuid_get (GPUMaterial *mat)
 
void GPU_pass_cache_init ()
 
void GPU_pass_cache_garbage_collect ()
 
void GPU_pass_cache_free ()
 
ListBase GPU_material_attributes (const GPUMaterial *material)
 
ListBase GPU_material_textures (GPUMaterial *material)
 
const GPUUniformAttrListGPU_material_uniform_attributes (const GPUMaterial *material)
 
GHashGPU_uniform_attr_list_hash_new (const char *info)
 
void GPU_uniform_attr_list_copy (GPUUniformAttrList *dest, const GPUUniformAttrList *src)
 
void GPU_uniform_attr_list_free (GPUUniformAttrList *set)
 
const ListBaseGPU_material_layer_attributes (const GPUMaterial *material)
 
GPUMaterialGPU_material_from_callbacks (eGPUMaterialEngine engine, ConstructGPUMaterialFn construct_function_cb, GPUCodegenCallbackFn generate_code_function_cb, void *thunk)
 

Typedef Documentation

◆ ConstructGPUMaterialFn

using ConstructGPUMaterialFn = void (*)(void *thunk, GPUMaterial *material)

Definition at line 415 of file GPU_material.hh.

◆ GPUCodegenCallbackFn

using GPUCodegenCallbackFn = void (*)(void *thunk, GPUMaterial *mat, GPUCodegenOutput *codegen)

Definition at line 140 of file GPU_material.hh.

◆ GPUMaterialPassReplacementCallbackFn

using GPUMaterialPassReplacementCallbackFn = GPUPass *(*)(void *thunk, GPUMaterial *mat)

Should return an already compiled pass if it's functionally equivalent to the one being compiled.

Definition at line 145 of file GPU_material.hh.

Enumeration Type Documentation

◆ eGPUDefaultValue

Enumerator
GPU_DEFAULT_0 
GPU_DEFAULT_1 

Definition at line 122 of file GPU_material.hh.

◆ eGPUMaterialEngine

High level functions to create and use GPU materials.

Enumerator
GPU_MAT_EEVEE_LEGACY 
GPU_MAT_EEVEE 
GPU_MAT_COMPOSITOR 

Definition at line 227 of file GPU_material.hh.

◆ eGPUMaterialFlag

Enumerator
GPU_MATFLAG_DIFFUSE 
GPU_MATFLAG_SUBSURFACE 
GPU_MATFLAG_GLOSSY 
GPU_MATFLAG_REFRACT 
GPU_MATFLAG_EMISSION 
GPU_MATFLAG_TRANSPARENT 
GPU_MATFLAG_HOLDOUT 
GPU_MATFLAG_SHADER_TO_RGBA 
GPU_MATFLAG_AO 
GPU_MATFLAG_COAT 
GPU_MATFLAG_TRANSLUCENT 
GPU_MATFLAG_VOLUME_SCATTER 
GPU_MATFLAG_VOLUME_ABSORPTION 
GPU_MATFLAG_OBJECT_INFO 
GPU_MATFLAG_AOV 
GPU_MATFLAG_BARYCENTRIC 
GPU_MATFLAG_UPDATED 
GPU_MATFLAG_LOOKDEV_HACK 

Definition at line 65 of file GPU_material.hh.

◆ eGPUMaterialOptimizationStatus

Enumerator
GPU_MAT_OPTIMIZATION_SKIP 
GPU_MAT_OPTIMIZATION_READY 
GPU_MAT_OPTIMIZATION_QUEUED 
GPU_MAT_OPTIMIZATION_SUCCESS 

Definition at line 115 of file GPU_material.hh.

◆ eGPUMaterialStatus

Enumerator
GPU_MAT_FAILED 
GPU_MAT_CREATED 
GPU_MAT_QUEUED 
GPU_MAT_SUCCESS 

Definition at line 106 of file GPU_material.hh.

◆ eGPUType

enum eGPUType
Enumerator
GPU_NONE 
GPU_FLOAT 
GPU_VEC2 
GPU_VEC3 
GPU_VEC4 
GPU_MAT3 
GPU_MAT4 
GPU_MAX_CONSTANT_DATA 
GPU_TEX1D_ARRAY 
GPU_TEX2D 
GPU_TEX2D_ARRAY 
GPU_TEX3D 
GPU_CLOSURE 
GPU_ATTR 

Definition at line 40 of file GPU_material.hh.

Function Documentation

◆ ENUM_OPERATORS()

◆ GPU_attribute()

◆ GPU_attribute_default_color()

GPUNodeLink * GPU_attribute_default_color ( GPUMaterial * mat)

Add a GPU attribute that refers to the default color attribute on a geometry. The name, type, and domain are unknown and do not depend on the material.

Definition at line 549 of file gpu_node_graph.cc.

References GPUNodeLink::attr, CD_AUTO_FROM_NAME, GPU_constant(), gpu_material_node_graph(), GPU_MAX_CONSTANT_DATA, gpu_node_graph_add_attribute(), GPU_NODE_LINK_ATTR, gpu_node_link_create(), GPUMaterialAttribute::is_default_color, and GPUNodeLink::link_type.

Referenced by blender::nodes::node_shader_vertex_color_cc::node_shader_gpu_vertex_color().

◆ GPU_attribute_hair_length()

◆ GPU_attribute_with_default()

◆ GPU_color_band()

◆ GPU_constant()

GPUNodeLink * GPU_constant ( const float * num)

Definition at line 625 of file gpu_node_graph.cc.

References GPUNodeLink::data, GPU_NODE_LINK_CONSTANT, gpu_node_link_create(), and GPUNodeLink::link_type.

Referenced by blender::nodes::node_composite_brightness_cc::BrightContrastShaderNode::compile(), blender::nodes::node_composite_channel_matte_cc::ChannelMatteShaderNode::compile(), blender::nodes::node_composite_color_ramp_cc::ColorRampShaderNode::compile(), blender::nodes::node_composite_color_spill_cc::ColorSpillShaderNode::compile(), blender::nodes::node_composite_colorcorrection_cc::ColorCorrectionShaderNode::compile(), blender::nodes::node_composite_huecorrect_cc::HueCorrectShaderNode::compile(), blender::nodes::node_composite_invert_cc::InvertShaderNode::compile(), blender::nodes::node_composite_luma_matte_cc::LuminanceMatteShaderNode::compile(), blender::nodes::node_composite_map_range_cc::MapRangeShaderNode::compile(), blender::nodes::node_composite_map_value_cc::MapValueShaderNode::compile(), blender::nodes::node_composite_math_cc::MathShaderNode::compile(), blender::nodes::node_composite_mixrgb_cc::MixRGBShaderNode::compile(), blender::nodes::node_composite_rgb_curves_cc::RGBCurvesShaderNode::compile(), blender::nodes::node_composite_rgb_to_bw_cc::RGBToBWShaderNode::compile(), blender::nodes::node_composite_vector_curves_cc::VectorCurvesShaderNode::compile(), GPU_attribute(), GPU_attribute_default_color(), GPU_attribute_hair_length(), gpu_node_input_socket(), blender::nodes::node_shader_bump_cc::gpu_shader_bump(), blender::nodes::node_shader_curves_cc::flt::gpu_shader_curve_float(), blender::nodes::node_shader_curves_cc::rgb::gpu_shader_curve_rgb(), blender::nodes::node_shader_curves_cc::vec::gpu_shader_curve_vec(), blender::nodes::node_shader_map_range_cc::gpu_shader_map_range(), blender::nodes::node_shader_math_cc::gpu_shader_math(), blender::nodes::node_sh_mix_cc::gpu_shader_mix(), blender::nodes::node_shader_mix_rgb_cc::gpu_shader_mix_rgb(), blender::nodes::node_shader_normal_map_cc::gpu_shader_normal_map(), blender::nodes::node_shader_color_ramp_cc::gpu_shader_valtorgb(), blender::nodes::node_shader_vector_transform_cc::gpu_shader_vect_transform(), blender::nodes::node_shader_vector_rotate_cc::gpu_shader_vector_rotate(), GPU_uniform_attribute(), blender::nodes::node_shader_ambient_occlusion_cc::node_shader_gpu_ambient_occlusion(), blender::nodes::node_shader_attribute_cc::node_shader_gpu_attribute(), blender::nodes::node_shader_blackbody_cc::node_shader_gpu_blackbody(), blender::nodes::node_shader_bsdf_glass_cc::node_shader_gpu_bsdf_glass(), blender::nodes::node_shader_bsdf_glossy_cc::node_shader_gpu_bsdf_glossy(), blender::nodes::node_shader_bsdf_metallic_cc::node_shader_gpu_bsdf_metallic(), blender::nodes::node_shader_bsdf_principled_cc::node_shader_gpu_bsdf_principled(), blender::nodes::node_shader_eevee_specular_cc::node_shader_gpu_eevee_specular(), blender::nodes::node_shader_geometry_cc::node_shader_gpu_geometry(), blender::nodes::node_shader_hair_info_cc::node_shader_gpu_hair_info(), blender::nodes::node_shader_object_info_cc::node_shader_gpu_object_info(), blender::nodes::node_shader_output_aov_cc::node_shader_gpu_output_aov(), blender::nodes::node_shader_subsurface_scattering_cc::node_shader_gpu_subsurface_scattering(), blender::nodes::node_shader_tex_brick_cc::node_shader_gpu_tex_brick(), blender::nodes::node_shader_tex_coord_cc::node_shader_gpu_tex_coord(), blender::nodes::node_shader_tex_gabor_cc::node_shader_gpu_tex_gabor(), blender::nodes::node_shader_tex_gradient_cc::node_shader_gpu_tex_gradient(), blender::nodes::node_shader_tex_magic_cc::node_shader_gpu_tex_magic(), blender::nodes::node_shader_tex_noise_cc::node_shader_gpu_tex_noise(), blender::nodes::node_shader_tex_sky_cc::node_shader_gpu_tex_sky(), blender::nodes::node_shader_tex_voronoi_cc::node_shader_gpu_tex_voronoi(), blender::nodes::node_shader_tex_wave_cc::node_shader_gpu_tex_wave(), blender::nodes::node_shader_volume_principled_cc::node_shader_gpu_volume_principled(), and blender::nodes::node_shader_wavelength_cc::node_shader_gpu_wavelength().

◆ GPU_differentiate_float_function()

GPUNodeLink * GPU_differentiate_float_function ( const char * function_name)

Create an implementation defined differential calculation of a float function. The given function should return a float. The result will be a vec2 containing dFdx and dFdy result of that function.

Definition at line 641 of file gpu_node_graph.cc.

References GPUNodeLink::function_name, gpu_node_link_create(), GPU_NODE_LINK_DIFFERENTIATE_FLOAT_FN, and GPUNodeLink::link_type.

Referenced by blender::nodes::node_shader_bump_cc::gpu_shader_bump().

◆ GPU_image()

◆ GPU_image_sky()

◆ GPU_image_tiled()

void GPU_image_tiled ( GPUMaterial * mat,
Image * ima,
ImageUser * iuser,
GPUSamplerState sampler_state,
GPUNodeLink ** r_image_tiled_link,
GPUNodeLink ** r_image_tiled_mapping_link )

◆ GPU_layer_attribute()

◆ GPU_link()

bool GPU_link ( GPUMaterial * mat,
const char * name,
... )

Definition at line 714 of file gpu_node_graph.cc.

References BLI_addtail(), FUNCTION_QUAL_OUT, gpu_material_library_use_function(), gpu_material_node_graph(), gpu_node_create(), gpu_node_input_link(), gpu_node_output(), node, and params.

Referenced by blender::nodes::node_shader_volume_principled_cc::attribute_post_process(), blender::nodes::node_composite_math_cc::MathShaderNode::compile(), blender::nodes::node_composite_mixrgb_cc::MixRGBShaderNode::compile(), blender::nodes::node_composite_rgb_curves_cc::RGBCurvesShaderNode::compile(), GPU_material_split_sub_function(), blender::nodes::node_shader_bevel_cc::gpu_shader_bevel(), blender::nodes::node_shader_bump_cc::gpu_shader_bump(), blender::nodes::node_shader_displacement_cc::gpu_shader_displacement(), blender::nodes::node_shader_map_range_cc::gpu_shader_map_range(), blender::nodes::node_shader_math_cc::gpu_shader_math(), blender::nodes::node_sh_mix_cc::gpu_shader_mix(), blender::nodes::node_shader_mix_rgb_cc::gpu_shader_mix_rgb(), blender::nodes::node_shader_normal_map_cc::gpu_shader_normal_map(), blender::nodes::node_shader_rgb_cc::gpu_shader_rgb(), blender::nodes::node_shader_value_cc::gpu_shader_value(), blender::nodes::node_shader_vector_transform_cc::gpu_shader_vect_transform(), gpu_uniformbuffer_link(), blender::nodes::node_shader_ambient_occlusion_cc::node_shader_gpu_ambient_occlusion(), blender::nodes::node_shader_attribute_cc::node_shader_gpu_attribute(), blender::nodes::node_shader_bsdf_diffuse_cc::node_shader_gpu_bsdf_diffuse(), blender::nodes::node_shader_bsdf_glass_cc::node_shader_gpu_bsdf_glass(), blender::nodes::node_shader_bsdf_glossy_cc::node_shader_gpu_bsdf_glossy(), blender::nodes::node_shader_bsdf_metallic_cc::node_shader_gpu_bsdf_metallic(), blender::nodes::node_shader_bsdf_principled_cc::node_shader_gpu_bsdf_principled(), blender::nodes::node_shader_bsdf_refraction_cc::node_shader_gpu_bsdf_refraction(), blender::nodes::node_shader_bsdf_sheen_cc::node_shader_gpu_bsdf_sheen(), blender::nodes::node_shader_bsdf_toon_cc::node_shader_gpu_bsdf_toon(), blender::nodes::node_shader_bsdf_translucent_cc::node_shader_gpu_bsdf_translucent(), node_shader_gpu_bump_tex_coord(), blender::nodes::node_shader_eevee_specular_cc::node_shader_gpu_eevee_specular(), blender::nodes::node_shader_fresnel_cc::node_shader_gpu_fresnel(), blender::nodes::node_shader_geometry_cc::node_shader_gpu_geometry(), blender::nodes::node_shader_layer_weight_cc::node_shader_gpu_layer_weight(), blender::nodes::node_shader_output_light_cc::node_shader_gpu_output_light(), blender::nodes::node_shader_output_material_cc::node_shader_gpu_output_material(), blender::nodes::node_shader_output_world_cc::node_shader_gpu_output_world(), blender::nodes::node_shader_subsurface_scattering_cc::node_shader_gpu_subsurface_scattering(), blender::nodes::node_shader_tangent_cc::node_shader_gpu_tangent(), blender::nodes::node_shader_tex_coord_cc::node_shader_gpu_tex_coord(), blender::nodes::node_shader_tex_environment_cc::node_shader_gpu_tex_environment(), blender::nodes::node_shader_tex_image_cc::node_shader_gpu_tex_image(), node_shader_gpu_tex_mapping(), and blender::nodes::node_shader_volume_info_cc::node_shader_gpu_volume_info().

◆ GPU_material_acquire()

void GPU_material_acquire ( GPUMaterial * mat)

◆ GPU_material_add_output_link_aov()

void GPU_material_add_output_link_aov ( GPUMaterial * material,
GPUNodeLink * link,
int hash )

◆ GPU_material_add_output_link_composite()

void GPU_material_add_output_link_composite ( GPUMaterial * material,
GPUNodeLink * link )

Definition at line 452 of file gpu_material.cc.

References BLI_addtail(), MEM_callocN, and GPUNodeGraphOutputLink::outlink.

◆ GPU_material_async_compile()

◆ GPU_material_async_try_finalize()

bool GPU_material_async_try_finalize ( GPUMaterial * mat)

◆ GPU_material_attributes()

◆ GPU_material_compile()

◆ GPU_material_flag()

eGPUMaterialFlag GPU_material_flag ( const GPUMaterial * mat)

Definition at line 569 of file gpu_material.cc.

References GPUMaterial::flag.

Referenced by GPUCodegen::GPUCodegen().

◆ GPU_material_flag_get()

◆ GPU_material_flag_set()

void GPU_material_flag_set ( GPUMaterial * mat,
eGPUMaterialFlag flag )

Definition at line 555 of file gpu_material.cc.

References flag, GPUMaterial::flag, GPU_MATFLAG_COAT, and GPU_MATFLAG_GLOSSY.

Referenced by GPU_attribute(), blender::nodes::node_shader_normal_map_cc::gpu_shader_normal_map(), blender::nodes::node_shader_particle_info_cc::gpu_shader_particle_info(), blender::nodes::node_shader_ambient_occlusion_cc::node_shader_gpu_ambient_occlusion(), blender::nodes::node_shader_bsdf_diffuse_cc::node_shader_gpu_bsdf_diffuse(), blender::nodes::node_shader_bsdf_glass_cc::node_shader_gpu_bsdf_glass(), blender::nodes::node_shader_bsdf_glossy_cc::node_shader_gpu_bsdf_glossy(), blender::nodes::node_shader_bsdf_hair_cc::node_shader_gpu_bsdf_hair(), blender::nodes::node_shader_bsdf_metallic_cc::node_shader_gpu_bsdf_metallic(), blender::nodes::node_shader_bsdf_principled_cc::node_shader_gpu_bsdf_principled(), blender::nodes::node_shader_bsdf_ray_portal_cc::node_shader_gpu_bsdf_ray_portal(), blender::nodes::node_shader_bsdf_refraction_cc::node_shader_gpu_bsdf_refraction(), blender::nodes::node_shader_bsdf_sheen_cc::node_shader_gpu_bsdf_sheen(), blender::nodes::node_shader_bsdf_toon_cc::node_shader_gpu_bsdf_toon(), blender::nodes::node_shader_bsdf_translucent_cc::node_shader_gpu_bsdf_translucent(), blender::nodes::node_shader_bsdf_transparent_cc::node_shader_gpu_bsdf_transparent(), blender::nodes::node_shader_eevee_specular_cc::node_shader_gpu_eevee_specular(), blender::nodes::node_shader_emission_cc::node_shader_gpu_emission(), blender::nodes::node_shader_geometry_cc::node_shader_gpu_geometry(), blender::nodes::node_shader_bsdf_hair_principled_cc::node_shader_gpu_hair_principled(), blender::nodes::node_shader_object_info_cc::node_shader_gpu_object_info(), blender::nodes::node_shader_output_aov_cc::node_shader_gpu_output_aov(), blender::nodes::node_shader_shader_to_rgb_cc::node_shader_gpu_shadertorgb(), blender::nodes::node_shader_subsurface_scattering_cc::node_shader_gpu_subsurface_scattering(), blender::nodes::node_shader_volume_absorption_cc::node_shader_gpu_volume_absorption(), blender::nodes::node_shader_volume_principled_cc::node_shader_gpu_volume_principled(), blender::nodes::node_shader_volume_scatter_cc::node_shader_gpu_volume_scatter(), and blender::nodes::node_shader_wireframe_cc::node_shader_gpu_wireframe().

◆ GPU_material_free()

◆ GPU_material_free_single()

◆ GPU_material_from_callbacks()

◆ GPU_material_from_nodetree()

GPUMaterial * GPU_material_from_nodetree ( Scene * scene,
Material * ma,
bNodeTree * ntree,
ListBase * gpumaterials,
const char * name,
eGPUMaterialEngine engine,
uint64_t shader_uuid,
bool is_volume_shader,
bool is_lookdev,
GPUCodegenCallbackFn callback,
void * thunk,
GPUMaterialPassReplacementCallbackFn pass_replacement_cb = nullptr )

WORKAROUND: The node tree code is never executed in default replaced passes, but the GPU validation will still complain if the node tree UBO is not bound. So we create a dummy UBO with (at least) the size of the default material one (192 bytes). We allocate 256 bytes to leave some room for future changes.

Definition at line 588 of file gpu_material.cc.

References BLI_addtail(), BLI_assert, BLI_ghashutil_ptrcmp(), BLI_ghashutil_ptrhash(), BLI_gset_new(), callback, LinkData::data, GPUMaterial::default_mat, GPUMaterial::engine, GPUMaterial::flag, GPU_generate_pass(), GPU_MAT_CREATED, GPU_MAT_FAILED, GPU_MAT_OPTIMIZATION_READY, GPU_MAT_OPTIMIZATION_SKIP, GPU_MAT_OPTIMIZATION_SUCCESS, GPU_MAT_SUCCESS, GPU_material_optimization_status_set(), gpu_material_ramp_texture_build(), gpu_material_sky_texture_build(), GPU_MATFLAG_LOOKDEV_HACK, GPU_MATFLAG_UPDATED, gpu_node_graph_free(), gpu_node_graph_free_nodes(), GPU_pass_acquire(), GPU_pass_shader_get(), GPU_pass_should_optimize(), GPU_uniformbuf_create_ex(), GPUMaterial::graph, bNodeTree::id, GPUMaterial::is_volume_shader, LISTBASE_FOREACH, GPUMaterial::ma, MEM_callocN, MEM_freeN(), GPUMaterial::name, blender::bke::node_tree_free_local_tree(), blender::bke::node_tree_localize(), ntreeGPUMaterialNodes, GPUMaterial::optimization_status, GPUMaterial::optimized_pass, GPUMaterial::pass, ID::py_instance, GPUMaterial::refcount, GPUMaterial::scene, scene, GPUMaterial::status, STRNCPY, GPUMaterial::ubo, GPUNodeGraph::used_libraries, and GPUMaterial::uuid.

Referenced by DRW_shader_from_material(), DRW_shader_from_world(), and blender::eevee::ShaderModule::material_shader_get().

◆ GPU_material_get_material()

◆ GPU_material_get_name()

◆ GPU_material_get_pass()

◆ GPU_material_get_shader()

GPUShader * GPU_material_get_shader ( GPUMaterial * material)

Return the most optimal shader configuration for the given material.

Definition at line 316 of file gpu_material.cc.

References GPU_MAT_OPTIMIZATION_SUCCESS, GPU_material_optimization_status(), and GPU_pass_shader_get().

Referenced by blender::realtime_compositor::ShaderOperation::execute(), and blender::eevee::ShaderKey::ShaderKey().

◆ GPU_material_get_shader_base()

GPUShader * GPU_material_get_shader_base ( GPUMaterial * material)

Return the base un-optimized shader.

Definition at line 328 of file gpu_material.cc.

References GPU_pass_shader_get().

◆ GPU_material_has_displacement_output()

◆ GPU_material_has_surface_output()

bool GPU_material_has_surface_output ( GPUMaterial * mat)

Definition at line 540 of file gpu_material.cc.

References GPUMaterial::has_surface_output.

◆ GPU_material_has_volume_output()

◆ GPU_material_layer_attributes()

const ListBase * GPU_material_layer_attributes ( const GPUMaterial * material)

◆ GPU_material_optimization_ready()

bool GPU_material_optimization_ready ( GPUMaterial * mat)

◆ GPU_material_optimization_status()

eGPUMaterialOptimizationStatus GPU_material_optimization_status ( GPUMaterial * mat)

Return status for asynchronous optimization jobs.

Definition at line 504 of file gpu_material.cc.

References GPUMaterial::optimization_status.

Referenced by drw_deferred_queue_append(), DRW_shader_queue_optimize_material(), GPU_material_get_pass(), and GPU_material_get_shader().

◆ GPU_material_optimization_status_set()

◆ GPU_material_optimize()

void GPU_material_optimize ( GPUMaterial * mat)

Material Optimization.

Note
Compiles optimal version of shader graph, populating mat->optimized_pass. This operation should always be deferred until existing compilations have completed. Default un-optimized materials will still exist for interactive material editing performance.

Perform asynchronous Render Pipeline State Object (PSO) compilation.

Warm PSO cache within asynchronous compilation thread for optimized materials. This setup assigns the original unoptimized shader as a "parent" shader for the optimized version. This then allows the associated GPU backend to compile PSOs within this asynchronous pass, using the identical PSO descriptors of the parent shader.

This eliminates all run-time stuttering associated with material optimization and ensures realtime material editing and animation remains seamless, while retaining optimal realtime performance.

Definition at line 813 of file gpu_material.cc.

References BLI_assert, ELEM, GPUMaterial::engine, GPU_generate_pass(), GPU_MAT_OPTIMIZATION_READY, GPU_MAT_OPTIMIZATION_SKIP, GPU_MAT_OPTIMIZATION_SUCCESS, GPU_MAT_SUCCESS, GPU_material_optimization_status_set(), gpu_node_graph_free_nodes(), GPU_pass_compile(), GPU_pass_release(), GPU_pass_shader_get(), GPU_shader_set_parent(), GPU_shader_warm_cache(), GPUMaterial::graph, GPUMaterial::name, GPUMaterial::optimization_status, GPUMaterial::optimized_pass, GPUMaterial::pass, and GPUMaterial::status.

Referenced by drw_deferred_shader_compilation_exec().

◆ GPU_material_output_displacement()

void GPU_material_output_displacement ( GPUMaterial * material,
GPUNodeLink * link )

◆ GPU_material_output_surface()

◆ GPU_material_output_thickness()

void GPU_material_output_thickness ( GPUMaterial * material,
GPUNodeLink * link )

◆ GPU_material_output_volume()

◆ GPU_material_recalc_flag_get()

bool GPU_material_recalc_flag_get ( GPUMaterial * mat)

Definition at line 574 of file gpu_material.cc.

References GPUMaterial::flag, and GPU_MATFLAG_UPDATED.

◆ GPU_material_release()

void GPU_material_release ( GPUMaterial * mat)

Definition at line 716 of file gpu_material.cc.

References GPU_material_free_single().

Referenced by drw_deferred_shader_compilation_exec().

◆ GPU_material_scene()

Scene * GPU_material_scene ( GPUMaterial * material)

Definition at line 301 of file gpu_material.cc.

◆ GPU_material_set_default()

void GPU_material_set_default ( GPUMaterial * material,
GPUMaterial * default_material )

Store reference to a similar default material for asynchronous PSO cache warming.

This function expects material to have not yet been compiled and for default_material to be ready. When compiling material as part of an asynchronous shader compilation job, use existing PSO descriptors from default_material's shader to also compile PSOs for this new material asynchronously, rather than at runtime.

The default_material options should match this new materials options in order for PSO descriptors to match those needed by the new material.

NOTE: default_material must exist when GPU_material_compile(..) is called for material.

See GPU_shader_warm_cache(..) for more information.

Definition at line 531 of file gpu_material.cc.

◆ GPU_material_split_sub_function()

char * GPU_material_split_sub_function ( GPUMaterial * material,
eGPUType return_type,
GPUNodeLink ** link )

Wrap a part of the material graph into a function. You need then need to call the function by using something like GPU_differentiate_float_function.

Note
This replace the link by a constant to break the link with the main graph.
Parameters
return_typesub function return type. Output is cast to this type.
linklink to use as the sub function output.
Returns
the name of the generated function.

Definition at line 460 of file gpu_material.cc.

References BLI_addtail(), BLI_assert, GPU_FLOAT, GPU_link(), GPU_VEC3, GPU_VEC4, MEM_callocN, GPUNodeGraphFunctionLink::name, GPUNodeGraphFunctionLink::outlink, and SNPRINTF.

Referenced by blender::nodes::node_shader_bump_cc::gpu_shader_bump().

◆ GPU_material_sss_profile_create()

◆ GPU_material_status()

eGPUMaterialStatus GPU_material_status ( GPUMaterial * mat)

Return true if the material compilation has not yet begin or begin.

Definition at line 494 of file gpu_material.cc.

References GPUMaterial::status.

Referenced by drw_deferred_shader_add(), DRW_shader_queue_optimize_material(), and blender::eevee::WorldVolumePipeline::sync().

◆ GPU_material_status_set()

◆ GPU_material_textures()

◆ GPU_material_uniform_attributes()

◆ GPU_material_uniform_buffer_create()

void GPU_material_uniform_buffer_create ( GPUMaterial * material,
ListBase * inputs )

Create dynamic UBO from parameters

Parameters
inputsItems are LinkData, data is GPUInput (BLI_genericNodeN(GPUInput)).

Definition at line 348 of file gpu_material.cc.

References GPU_uniformbuf_create_from_list().

Referenced by GPUCodegen::generate_uniform_buffer().

◆ GPU_material_uniform_buffer_get()

GPUUniformBuf * GPU_material_uniform_buffer_get ( GPUMaterial * material)

◆ GPU_material_uuid_get()

◆ GPU_materials_free()

◆ GPU_pass_cache_free()

void GPU_pass_cache_free ( )

◆ GPU_pass_cache_garbage_collect()

void GPU_pass_cache_garbage_collect ( )

◆ GPU_pass_cache_init()

void GPU_pass_cache_init ( )

Definition at line 1019 of file gpu_codegen.cc.

References BLI_spin_init(), and pass_cache_spin.

Referenced by WM_init_gpu().

◆ GPU_stack_link()

bool GPU_stack_link ( GPUMaterial * mat,
const bNode * node,
const char * name,
GPUNodeStack * in,
GPUNodeStack * out,
... )

Definition at line 821 of file gpu_node_graph.cc.

References gpu_stack_link_v(), and params.

Referenced by blender::nodes::node_composite_alpha_over_cc::AlphaOverShaderNode::compile(), blender::nodes::node_composite_brightness_cc::BrightContrastShaderNode::compile(), blender::nodes::node_composite_channel_matte_cc::ChannelMatteShaderNode::compile(), blender::nodes::node_composite_chroma_matte_cc::ChromaMatteShaderNode::compile(), blender::nodes::node_composite_color_matte_cc::ColorMatteShaderNode::compile(), blender::nodes::node_composite_color_ramp_cc::ColorRampShaderNode::compile(), blender::nodes::node_composite_color_spill_cc::ColorSpillShaderNode::compile(), blender::nodes::node_composite_colorbalance_cc::ColorBalanceShaderNode::compile(), blender::nodes::node_composite_colorcorrection_cc::ColorCorrectionShaderNode::compile(), blender::nodes::node_composite_combine_color_cc::CombineColorShaderNode::compile(), blender::nodes::node_composite_combine_hsva_cc::CombineHSVAShaderNode::compile(), blender::nodes::node_composite_combine_rgba_cc::CombineRGBAShaderNode::compile(), blender::nodes::node_composite_combine_xyz_cc::CombineXYZShaderNode::compile(), blender::nodes::node_composite_combine_ycca_cc::CombineYCCAShaderNode::compile(), blender::nodes::node_composite_combine_yuva_cc::CombineYUVAShaderNode::compile(), blender::nodes::node_composite_diff_matte_cc::DifferenceMatteShaderNode::compile(), blender::nodes::node_composite_distance_matte_cc::DistanceMatteShaderNode::compile(), blender::nodes::node_composite_exposure_cc::ExposureShaderNode::compile(), blender::nodes::node_composite_gamma_cc::GammaShaderNode::compile(), blender::nodes::node_composite_hue_sat_val_cc::HueSaturationValueShaderNode::compile(), blender::nodes::node_composite_huecorrect_cc::HueCorrectShaderNode::compile(), blender::nodes::node_composite_invert_cc::InvertShaderNode::compile(), blender::nodes::node_composite_luma_matte_cc::LuminanceMatteShaderNode::compile(), blender::nodes::node_composite_map_range_cc::MapRangeShaderNode::compile(), blender::nodes::node_composite_map_value_cc::MapValueShaderNode::compile(), blender::nodes::node_composite_math_cc::MathShaderNode::compile(), blender::nodes::node_composite_mixrgb_cc::MixRGBShaderNode::compile(), blender::nodes::node_composite_normal_cc::NormalShaderNode::compile(), blender::nodes::node_composite_posterize_cc::PosterizeShaderNode::compile(), blender::nodes::node_composite_premulkey_cc::AlphaConvertShaderNode::compile(), blender::nodes::node_composite_rgb_curves_cc::RGBCurvesShaderNode::compile(), blender::nodes::node_composite_rgb_to_bw_cc::RGBToBWShaderNode::compile(), blender::nodes::node_composite_separate_color_cc::SeparateColorShaderNode::compile(), blender::nodes::node_composite_separate_hsva_cc::SeparateHSVAShaderNode::compile(), blender::nodes::node_composite_separate_rgba_cc::SeparateRGBAShaderNode::compile(), blender::nodes::node_composite_separate_xyz_cc::SeparateXYZShaderNode::compile(), blender::nodes::node_composite_separate_ycca_cc::SeparateYCCAShaderNode::compile(), blender::nodes::node_composite_separate_yuva_cc::SeparateYUVAShaderNode::compile(), blender::nodes::node_composite_setalpha_cc::SetAlphaShaderNode::compile(), blender::nodes::node_composite_vector_curves_cc::VectorCurvesShaderNode::compile(), blender::nodes::node_shader_bevel_cc::gpu_shader_bevel(), blender::nodes::node_shader_brightness_cc::gpu_shader_brightcontrast(), blender::nodes::node_shader_bump_cc::gpu_shader_bump(), blender::nodes::node_shader_camera_cc::gpu_shader_camera(), blender::nodes::node_shader_clamp_cc::gpu_shader_clamp(), blender::nodes::node_shader_combine_color_cc::gpu_shader_combcolor(), blender::nodes::node_shader_sepcomb_hsv_cc::gpu_shader_combhsv(), blender::nodes::node_shader_sepcomb_rgb_cc::gpu_shader_combrgb(), blender::nodes::node_shader_sepcomb_xyz_cc::comb::gpu_shader_combxyz(), blender::nodes::node_shader_curves_cc::flt::gpu_shader_curve_float(), blender::nodes::node_shader_curves_cc::rgb::gpu_shader_curve_rgb(), blender::nodes::node_shader_curves_cc::vec::gpu_shader_curve_vec(), blender::nodes::node_shader_displacement_cc::gpu_shader_displacement(), blender::nodes::node_shader_hueSatVal_cc::gpu_shader_hue_sat(), blender::nodes::node_shader_invert_cc::gpu_shader_invert(), blender::nodes::node_shader_map_range_cc::gpu_shader_map_range(), blender::nodes::node_shader_mapping_cc::gpu_shader_mapping(), blender::nodes::node_shader_math_cc::gpu_shader_math(), blender::nodes::node_sh_mix_cc::gpu_shader_mix(), blender::nodes::node_shader_mix_rgb_cc::gpu_shader_mix_rgb(), blender::nodes::node_shader_normal_cc::gpu_shader_normal(), blender::nodes::node_shader_particle_info_cc::gpu_shader_particle_info(), blender::nodes::node_shader_holdout_cc::gpu_shader_rgb(), blender::nodes::node_shader_rgb_to_bw_cc::gpu_shader_rgbtobw(), blender::nodes::node_shader_separate_color_cc::gpu_shader_sepcolor(), blender::nodes::node_shader_sepcomb_hsv_cc::gpu_shader_sephsv(), blender::nodes::node_shader_sepcomb_rgb_cc::gpu_shader_seprgb(), blender::nodes::node_shader_sepcomb_xyz_cc::sep::gpu_shader_sepxyz(), blender::nodes::node_shader_squeeze_cc::gpu_shader_squeeze(), blender::nodes::node_shader_tex_white_noise_cc::gpu_shader_tex_white_noise(), blender::nodes::node_shader_color_ramp_cc::gpu_shader_valtorgb(), blender::nodes::node_shader_vector_displacement_cc::gpu_shader_vector_displacement(), blender::nodes::node_shader_vector_math_cc::gpu_shader_vector_math(), blender::nodes::node_shader_vector_rotate_cc::gpu_shader_vector_rotate(), blender::nodes::node_shader_add_shader_cc::node_shader_gpu_add_shader(), blender::nodes::node_shader_ambient_occlusion_cc::node_shader_gpu_ambient_occlusion(), blender::nodes::node_shader_attribute_cc::node_shader_gpu_attribute(), blender::nodes::node_shader_background_cc::node_shader_gpu_background(), blender::nodes::node_shader_blackbody_cc::node_shader_gpu_blackbody(), blender::nodes::node_shader_bsdf_diffuse_cc::node_shader_gpu_bsdf_diffuse(), blender::nodes::node_shader_bsdf_glass_cc::node_shader_gpu_bsdf_glass(), blender::nodes::node_shader_bsdf_glossy_cc::node_shader_gpu_bsdf_glossy(), blender::nodes::node_shader_bsdf_hair_cc::node_shader_gpu_bsdf_hair(), blender::nodes::node_shader_bsdf_metallic_cc::node_shader_gpu_bsdf_metallic(), blender::nodes::node_shader_bsdf_principled_cc::node_shader_gpu_bsdf_principled(), blender::nodes::node_shader_bsdf_ray_portal_cc::node_shader_gpu_bsdf_ray_portal(), blender::nodes::node_shader_bsdf_refraction_cc::node_shader_gpu_bsdf_refraction(), blender::nodes::node_shader_bsdf_sheen_cc::node_shader_gpu_bsdf_sheen(), blender::nodes::node_shader_bsdf_toon_cc::node_shader_gpu_bsdf_toon(), blender::nodes::node_shader_bsdf_translucent_cc::node_shader_gpu_bsdf_translucent(), blender::nodes::node_shader_bsdf_transparent_cc::node_shader_gpu_bsdf_transparent(), blender::nodes::node_shader_eevee_specular_cc::node_shader_gpu_eevee_specular(), blender::nodes::node_shader_emission_cc::node_shader_gpu_emission(), blender::nodes::node_shader_fresnel_cc::node_shader_gpu_fresnel(), blender::nodes::node_shader_gamma_cc::node_shader_gpu_gamma(), blender::nodes::node_shader_geometry_cc::node_shader_gpu_geometry(), blender::nodes::node_shader_hair_info_cc::node_shader_gpu_hair_info(), blender::nodes::node_shader_bsdf_hair_principled_cc::node_shader_gpu_hair_principled(), blender::nodes::node_shader_layer_weight_cc::node_shader_gpu_layer_weight(), blender::nodes::node_shader_light_falloff_cc::node_shader_gpu_light_falloff(), blender::nodes::node_shader_light_path_cc::node_shader_gpu_light_path(), blender::nodes::node_shader_mix_shader_cc::node_shader_gpu_mix_shader(), blender::nodes::node_shader_object_info_cc::node_shader_gpu_object_info(), blender::nodes::node_shader_output_aov_cc::node_shader_gpu_output_aov(), blender::nodes::node_shader_point_info_cc::node_shader_gpu_point_info(), blender::nodes::node_shader_shader_to_rgb_cc::node_shader_gpu_shadertorgb(), blender::nodes::node_shader_subsurface_scattering_cc::node_shader_gpu_subsurface_scattering(), blender::nodes::node_shader_tangent_cc::node_shader_gpu_tangent(), blender::nodes::node_shader_tex_brick_cc::node_shader_gpu_tex_brick(), blender::nodes::node_shader_tex_checker_cc::node_shader_gpu_tex_checker(), blender::nodes::node_shader_tex_coord_cc::node_shader_gpu_tex_coord(), blender::nodes::node_shader_tex_environment_cc::node_shader_gpu_tex_environment(), blender::nodes::node_shader_tex_gabor_cc::node_shader_gpu_tex_gabor(), blender::nodes::node_shader_tex_gradient_cc::node_shader_gpu_tex_gradient(), blender::nodes::node_shader_tex_image_cc::node_shader_gpu_tex_image(), blender::nodes::node_shader_tex_magic_cc::node_shader_gpu_tex_magic(), blender::nodes::node_shader_tex_noise_cc::node_shader_gpu_tex_noise(), blender::nodes::node_shader_tex_sky_cc::node_shader_gpu_tex_sky(), blender::nodes::node_shader_tex_voronoi_cc::node_shader_gpu_tex_voronoi(), blender::nodes::node_shader_tex_wave_cc::node_shader_gpu_tex_wave(), blender::nodes::node_shader_uvmap_cc::node_shader_gpu_uvmap(), blender::nodes::node_shader_vertex_color_cc::node_shader_gpu_vertex_color(), blender::nodes::node_shader_volume_absorption_cc::node_shader_gpu_volume_absorption(), blender::nodes::node_shader_volume_principled_cc::node_shader_gpu_volume_principled(), blender::nodes::node_shader_volume_scatter_cc::node_shader_gpu_volume_scatter(), blender::nodes::node_shader_wavelength_cc::node_shader_gpu_wavelength(), and blender::nodes::node_shader_wireframe_cc::node_shader_gpu_wireframe().

◆ GPU_uniform()

GPUNodeLink * GPU_uniform ( const float * num)

Definition at line 633 of file gpu_node_graph.cc.

References GPUNodeLink::data, gpu_node_link_create(), GPU_NODE_LINK_UNIFORM, and GPUNodeLink::link_type.

Referenced by blender::nodes::node_composite_alpha_over_cc::AlphaOverShaderNode::compile(), blender::nodes::node_composite_channel_matte_cc::ChannelMatteShaderNode::compile(), blender::nodes::node_composite_chroma_matte_cc::ChromaMatteShaderNode::compile(), blender::nodes::node_composite_color_matte_cc::ColorMatteShaderNode::compile(), blender::nodes::node_composite_color_ramp_cc::ColorRampShaderNode::compile(), blender::nodes::node_composite_color_spill_cc::ColorSpillShaderNode::compile(), blender::nodes::node_composite_colorbalance_cc::ColorBalanceShaderNode::compile(), blender::nodes::node_composite_colorcorrection_cc::ColorCorrectionShaderNode::compile(), blender::nodes::node_composite_diff_matte_cc::DifferenceMatteShaderNode::compile(), blender::nodes::node_composite_distance_matte_cc::DistanceMatteShaderNode::compile(), blender::nodes::node_composite_huecorrect_cc::HueCorrectShaderNode::compile(), blender::nodes::node_composite_luma_matte_cc::LuminanceMatteShaderNode::compile(), blender::nodes::node_composite_map_value_cc::MapValueShaderNode::compile(), blender::nodes::node_composite_normal_cc::NormalShaderNode::compile(), blender::nodes::node_composite_rgb_curves_cc::RGBCurvesShaderNode::compile(), blender::nodes::node_composite_vector_curves_cc::VectorCurvesShaderNode::compile(), blender::realtime_compositor::ShaderNode::get_input_link(), blender::nodes::node_shader_curves_cc::flt::gpu_shader_curve_float(), blender::nodes::node_shader_curves_cc::rgb::gpu_shader_curve_rgb(), blender::nodes::node_shader_curves_cc::vec::gpu_shader_curve_vec(), blender::nodes::node_sh_mix_cc::gpu_shader_mix(), blender::nodes::node_shader_mix_rgb_cc::gpu_shader_mix_rgb(), blender::nodes::node_shader_normal_cc::gpu_shader_normal(), blender::nodes::node_shader_normal_map_cc::gpu_shader_normal_map(), blender::nodes::node_shader_rgb_cc::gpu_shader_rgb(), blender::nodes::node_shader_color_ramp_cc::gpu_shader_valtorgb(), blender::nodes::node_shader_value_cc::gpu_shader_value(), gpu_uniformbuffer_link(), blender::nodes::node_shader_tex_brick_cc::node_shader_gpu_tex_brick(), blender::nodes::node_shader_tex_coord_cc::node_shader_gpu_tex_coord(), blender::nodes::node_shader_tex_image_cc::node_shader_gpu_tex_image(), node_shader_gpu_tex_mapping(), and blender::nodes::node_shader_tex_sky_cc::node_shader_gpu_tex_sky().

◆ GPU_uniform_attr_list_copy()

void GPU_uniform_attr_list_copy ( GPUUniformAttrList * dest,
const GPUUniformAttrList * src )

◆ GPU_uniform_attr_list_free()

void GPU_uniform_attr_list_free ( GPUUniformAttrList * set)

Definition at line 320 of file gpu_node_graph.cc.

References BLI_freelistN().

Referenced by drw_uniform_attrs_pool_free_cb(), and gpu_node_graph_free().

◆ GPU_uniform_attr_list_hash_new()

GHash * GPU_uniform_attr_list_hash_new ( const char * info)

◆ GPU_uniform_attribute()