Blender  V2.93
Classes | Macros | Typedefs | Enumerations | Functions
DRW_render.h File Reference
#include "DRW_engine_types.h"
#include "BLI_listbase.h"
#include "BLI_math_matrix.h"
#include "BLI_math_vector.h"
#include "BLI_string.h"
#include "BKE_context.h"
#include "BKE_layer.h"
#include "BKE_material.h"
#include "BKE_scene.h"
#include "BLT_translation.h"
#include "DNA_light_types.h"
#include "DNA_material_types.h"
#include "DNA_object_types.h"
#include "DNA_scene_types.h"
#include "DNA_world_types.h"
#include "GPU_framebuffer.h"
#include "GPU_primitive.h"
#include "GPU_shader.h"
#include "GPU_texture.h"
#include "GPU_uniform_buffer.h"
#include "draw_cache.h"
#include "draw_common.h"
#include "draw_view.h"
#include "draw_debug.h"
#include "draw_manager_profiling.h"
#include "MEM_guardedalloc.h"
#include "RE_engine.h"
#include "DEG_depsgraph.h"

Go to the source code of this file.

Classes

struct  BoundSphere
 
struct  DrawEngineDataSize
 
struct  DrawEngineType
 
struct  DRWInstanceAttrFormat
 
struct  DRWContextState
 

Macros

#define DRW_VIEWPORT_LIST_SIZE(list)    (sizeof(list) == sizeof(DRWViewportEmptyList) ? 0 : ((sizeof(list)) / sizeof(void *)))
 
#define DRW_VIEWPORT_DATA_SIZE(ty)
 
#define DRW_TEXTURE_FREE_SAFE(tex)
 
#define DRW_UBO_FREE_SAFE(ubo)
 
#define DRW_shader_create(vert, geom, frag, defines)    DRW_shader_create_ex(vert, geom, frag, defines, __func__)
 
#define DRW_shader_create_with_lib(vert, geom, frag, lib, defines)    DRW_shader_create_with_lib_ex(vert, geom, frag, lib, defines, __func__)
 
#define DRW_shader_create_with_shaderlib(vert, geom, frag, lib, defines)    DRW_shader_create_with_shaderlib_ex(vert, geom, frag, lib, defines, __func__)
 
#define DRW_shader_create_fullscreen(frag, defines)    DRW_shader_create_fullscreen_ex(frag, defines, __func__)
 
#define DRW_shader_create_fullscreen_with_shaderlib(frag, lib, defines)    DRW_shader_create_fullscreen_with_shaderlib_ex(frag, lib, defines, __func__)
 
#define DRW_SHADER_FREE_SAFE(shader)
 
#define DRW_SHADER_LIB_ADD(lib, lib_name)    DRW_shader_library_add_file(lib, datatoc_##lib_name##_glsl, STRINGIFY(lib_name) ".glsl")
 
#define DRW_SHADER_LIB_FREE_SAFE(lib)
 
#define DRW_STATE_DEFAULT    (DRW_STATE_WRITE_DEPTH | DRW_STATE_WRITE_COLOR | DRW_STATE_DEPTH_LESS_EQUAL)
 
#define DRW_STATE_BLEND_ENABLED
 
#define DRW_STATE_RASTERIZER_ENABLED
 
#define DRW_STATE_DEPTH_TEST_ENABLED
 
#define DRW_STATE_STENCIL_TEST_ENABLED    (DRW_STATE_STENCIL_ALWAYS | DRW_STATE_STENCIL_EQUAL | DRW_STATE_STENCIL_NEQUAL)
 
#define DRW_STATE_WRITE_STENCIL_ENABLED
 
#define DRW_shgroup_instance_format(format, ...)
 
#define DRW_shgroup_call(shgroup, geom, ob)    DRW_shgroup_call_ex(shgroup, ob, NULL, geom, false, NULL)
 
#define DRW_shgroup_call_obmat(shgroup, geom, obmat)    DRW_shgroup_call_ex(shgroup, NULL, obmat, geom, false, NULL)
 
#define DRW_shgroup_call_with_callback(shgroup, geom, ob, user_data)    DRW_shgroup_call_ex(shgroup, ob, NULL, geom, false, user_data)
 
#define DRW_shgroup_call_no_cull(shgroup, geom, ob)    DRW_shgroup_call_ex(shgroup, ob, NULL, geom, true, NULL)
 
#define DRW_buffer_add_entry(buffer, ...)
 
#define DRW_PASS_CREATE(pass, state)   (pass = DRW_pass_create(#pass, state))
 
#define DRW_PASS_INSTANCE_CREATE(pass, original, state)    (pass = DRW_pass_create_instance(#pass, (original), state))
 

Typedefs

typedef struct DRWCallBuffer DRWCallBuffer
 
typedef struct DRWInterface DRWInterface
 
typedef struct DRWPass DRWPass
 
typedef struct DRWShaderLibrary DRWShaderLibrary
 
typedef struct DRWShadingGroup DRWShadingGroup
 
typedef struct DRWUniform DRWUniform
 
typedef struct DRWView DRWView
 
typedef struct BoundSphere BoundSphere
 
typedef char DRWViewportEmptyList
 
typedef struct DrawEngineDataSize DrawEngineDataSize
 
typedef struct DrawEngineType DrawEngineType
 
typedef void(* GPUMaterialEvalCallbackFn) (struct GPUMaterial *mat, int options, const char **vert_code, const char **geom_code, const char **frag_lib, const char **defines)
 
typedef struct DRWInstanceAttrFormat DRWInstanceAttrFormat
 
typedef bool() DRWCallVisibilityFn(bool vis_in, void *user_data)
 
typedef struct DRWContextState DRWContextState
 

Enumerations

enum  DRWTextureFlag { DRW_TEX_FILTER = (1 << 0) , DRW_TEX_WRAP = (1 << 1) , DRW_TEX_COMPARE = (1 << 2) , DRW_TEX_MIPMAP = (1 << 3) }
 
enum  DRWState {
  DRW_STATE_WRITE_DEPTH = (1 << 0) , DRW_STATE_WRITE_COLOR = (1 << 1) , DRW_STATE_WRITE_STENCIL = (1 << 2) , DRW_STATE_WRITE_STENCIL_SHADOW_PASS = (2 << 2) ,
  DRW_STATE_WRITE_STENCIL_SHADOW_FAIL = (3 << 2) , DRW_STATE_DEPTH_ALWAYS = (1 << 4) , DRW_STATE_DEPTH_LESS = (2 << 4) , DRW_STATE_DEPTH_LESS_EQUAL = (3 << 4) ,
  DRW_STATE_DEPTH_EQUAL = (4 << 4) , DRW_STATE_DEPTH_GREATER = (5 << 4) , DRW_STATE_DEPTH_GREATER_EQUAL = (6 << 4) , DRW_STATE_CULL_BACK = (1 << 7) ,
  DRW_STATE_CULL_FRONT = (1 << 8) , DRW_STATE_STENCIL_ALWAYS = (1 << 9) , DRW_STATE_STENCIL_EQUAL = (2 << 9) , DRW_STATE_STENCIL_NEQUAL = (3 << 9) ,
  DRW_STATE_BLEND_ADD = (1 << 11) , DRW_STATE_BLEND_ADD_FULL = (2 << 11) , DRW_STATE_BLEND_ALPHA = (3 << 11) , DRW_STATE_BLEND_ALPHA_PREMUL = (4 << 11) ,
  DRW_STATE_BLEND_BACKGROUND = (5 << 11) , DRW_STATE_BLEND_OIT = (6 << 11) , DRW_STATE_BLEND_MUL = (7 << 11) , DRW_STATE_BLEND_SUB = (8 << 11) ,
  DRW_STATE_BLEND_CUSTOM = (9 << 11) , DRW_STATE_LOGIC_INVERT = (10 << 11) , DRW_STATE_BLEND_ALPHA_UNDER_PREMUL = (11 << 11) , DRW_STATE_IN_FRONT_SELECT = (1 << 27) ,
  DRW_STATE_SHADOW_OFFSET = (1 << 28) , DRW_STATE_CLIP_PLANES = (1 << 29) , DRW_STATE_FIRST_VERTEX_CONVENTION = (1 << 30) , DRW_STATE_PROGRAM_POINT_SIZE = (1u << 31)
}
 
enum  eDRWAttrType { DRW_ATTR_INT , DRW_ATTR_FLOAT }
 

Functions

struct GPUTextureDRW_texture_pool_query_2d (int w, int h, eGPUTextureFormat format, DrawEngineType *engine_type)
 
struct GPUTextureDRW_texture_pool_query_fullscreen (eGPUTextureFormat format, DrawEngineType *engine_type)
 
struct GPUTextureDRW_texture_create_1d (int w, eGPUTextureFormat format, DRWTextureFlag flags, const float *fpixels)
 
struct GPUTextureDRW_texture_create_2d (int w, int h, eGPUTextureFormat format, DRWTextureFlag flags, const float *fpixels)
 
struct GPUTextureDRW_texture_create_2d_array (int w, int h, int d, eGPUTextureFormat format, DRWTextureFlag flags, const float *fpixels)
 
struct GPUTextureDRW_texture_create_3d (int w, int h, int d, eGPUTextureFormat format, DRWTextureFlag flags, const float *fpixels)
 
struct GPUTextureDRW_texture_create_cube (int w, eGPUTextureFormat format, DRWTextureFlag flags, const float *fpixels)
 
struct GPUTextureDRW_texture_create_cube_array (int w, int d, eGPUTextureFormat format, DRWTextureFlag flags, const float *fpixels)
 
void DRW_texture_ensure_fullscreen_2d (struct GPUTexture **tex, eGPUTextureFormat format, DRWTextureFlag flags)
 
void DRW_texture_ensure_2d (struct GPUTexture **tex, int w, int h, eGPUTextureFormat format, DRWTextureFlag flags)
 
void DRW_texture_generate_mipmaps (struct GPUTexture *tex)
 
void DRW_texture_free (struct GPUTexture *tex)
 
struct GPUShaderDRW_shader_create_ex (const char *vert, const char *geom, const char *frag, const char *defines, const char *name)
 
struct GPUShaderDRW_shader_create_with_lib_ex (const char *vert, const char *geom, const char *frag, const char *lib, const char *defines, const char *name)
 
struct GPUShaderDRW_shader_create_with_shaderlib_ex (const char *vert, const char *geom, const char *frag, const DRWShaderLibrary *lib, const char *defines, const char *name)
 
struct GPUShaderDRW_shader_create_with_transform_feedback (const char *vert, const char *geom, const char *defines, const eGPUShaderTFBType prim_type, const char **varying_names, const int varying_count)
 
struct GPUShaderDRW_shader_create_fullscreen_ex (const char *frag, const char *defines, const char *name)
 
struct GPUShaderDRW_shader_create_fullscreen_with_shaderlib_ex (const char *frag, const DRWShaderLibrary *lib, const char *defines, const char *name)
 
struct GPUMaterialDRW_shader_find_from_world (struct World *wo, const void *engine_type, const int options, bool deferred)
 
struct GPUMaterialDRW_shader_find_from_material (struct Material *ma, const void *engine_type, const int options, bool deferred)
 
struct GPUMaterialDRW_shader_create_from_world (struct Scene *scene, struct World *wo, struct bNodeTree *ntree, const void *engine_type, const int options, const bool is_volume_shader, const char *vert, const char *geom, const char *frag_lib, const char *defines, bool deferred, GPUMaterialEvalCallbackFn callback)
 
struct GPUMaterialDRW_shader_create_from_material (struct Scene *scene, struct Material *ma, struct bNodeTree *ntree, const void *engine_type, const int options, const bool is_volume_shader, const char *vert, const char *geom, const char *frag_lib, const char *defines, bool deferred, GPUMaterialEvalCallbackFn callback)
 
void DRW_shader_free (struct GPUShader *shader)
 
DRWShaderLibraryDRW_shader_library_create (void)
 
void DRW_shader_library_add_file (DRWShaderLibrary *lib, char *lib_code, const char *lib_name)
 
char * DRW_shader_library_create_shader_string (const DRWShaderLibrary *lib, const char *shader_code)
 
void DRW_shader_library_free (DRWShaderLibrary *lib)
 
struct GPUVertFormatDRW_shgroup_instance_format_array (const DRWInstanceAttrFormat attrs[], int arraysize)
 
DRWShadingGroupDRW_shgroup_create (struct GPUShader *shader, DRWPass *pass)
 
DRWShadingGroupDRW_shgroup_create_sub (DRWShadingGroup *shgroup)
 
DRWShadingGroupDRW_shgroup_material_create (struct GPUMaterial *material, DRWPass *pass)
 
DRWShadingGroupDRW_shgroup_transform_feedback_create (struct GPUShader *shader, DRWPass *pass, struct GPUVertBuf *tf_target)
 
void DRW_shgroup_add_material_resources (DRWShadingGroup *grp, struct GPUMaterial *material)
 
void DRW_shgroup_call_ex (DRWShadingGroup *shgroup, Object *ob, float(*obmat)[4], struct GPUBatch *geom, bool bypass_culling, void *user_data)
 
void DRW_shgroup_call_range (DRWShadingGroup *shgroup, Object *ob, struct GPUBatch *geom, uint v_sta, uint v_ct)
 
void DRW_shgroup_call_instance_range (DRWShadingGroup *shgroup, Object *ob, struct GPUBatch *geom, uint i_sta, uint i_ct)
 
void DRW_shgroup_call_procedural_points (DRWShadingGroup *sh, Object *ob, uint point_count)
 
void DRW_shgroup_call_procedural_lines (DRWShadingGroup *sh, Object *ob, uint line_count)
 
void DRW_shgroup_call_procedural_triangles (DRWShadingGroup *sh, Object *ob, uint tri_count)
 
void DRW_shgroup_call_instances (DRWShadingGroup *shgroup, Object *ob, struct GPUBatch *geom, uint count)
 
void DRW_shgroup_call_instances_with_attrs (DRWShadingGroup *shgroup, Object *ob, struct GPUBatch *geom, struct GPUBatch *inst_attributes)
 
void DRW_shgroup_call_sculpt (DRWShadingGroup *sh, Object *ob, bool wire, bool mask)
 
void DRW_shgroup_call_sculpt_with_materials (DRWShadingGroup **sh, int num_sh, Object *ob)
 
DRWCallBufferDRW_shgroup_call_buffer (DRWShadingGroup *shgroup, struct GPUVertFormat *format, GPUPrimType prim_type)
 
DRWCallBufferDRW_shgroup_call_buffer_instance (DRWShadingGroup *shgroup, struct GPUVertFormat *format, struct GPUBatch *geom)
 
void DRW_buffer_add_entry_struct (DRWCallBuffer *callbuf, const void *data)
 
void DRW_buffer_add_entry_array (DRWCallBuffer *callbuf, const void *attr[], uint attr_len)
 
uint32_t DRW_object_resource_id_get (Object *ob)
 
void DRW_shgroup_state_enable (DRWShadingGroup *shgroup, DRWState state)
 
void DRW_shgroup_state_disable (DRWShadingGroup *shgroup, DRWState state)
 
void DRW_shgroup_stencil_set (DRWShadingGroup *shgroup, uint write_mask, uint reference, uint compare_mask)
 
void DRW_shgroup_stencil_mask (DRWShadingGroup *shgroup, uint mask)
 
void DRW_shgroup_clear_framebuffer (DRWShadingGroup *shgroup, eGPUFrameBufferBits channels, uchar r, uchar g, uchar b, uchar a, float depth, uchar stencil)
 
void DRW_shgroup_uniform_texture_ex (DRWShadingGroup *shgroup, const char *name, const struct GPUTexture *tex, eGPUSamplerState sampler_state)
 
void DRW_shgroup_uniform_texture_ref_ex (DRWShadingGroup *shgroup, const char *name, GPUTexture **tex, eGPUSamplerState sampler_state)
 
void DRW_shgroup_uniform_texture (DRWShadingGroup *shgroup, const char *name, const struct GPUTexture *tex)
 
void DRW_shgroup_uniform_texture_ref (DRWShadingGroup *shgroup, const char *name, struct GPUTexture **tex)
 
void DRW_shgroup_uniform_block (DRWShadingGroup *shgroup, const char *name, const struct GPUUniformBuf *ubo)
 
void DRW_shgroup_uniform_block_ref (DRWShadingGroup *shgroup, const char *name, struct GPUUniformBuf **ubo)
 
void DRW_shgroup_uniform_float (DRWShadingGroup *shgroup, const char *name, const float *value, int arraysize)
 
void DRW_shgroup_uniform_vec2 (DRWShadingGroup *shgroup, const char *name, const float *value, int arraysize)
 
void DRW_shgroup_uniform_vec3 (DRWShadingGroup *shgroup, const char *name, const float *value, int arraysize)
 
void DRW_shgroup_uniform_vec4 (DRWShadingGroup *shgroup, const char *name, const float *value, int arraysize)
 
void DRW_shgroup_uniform_bool (DRWShadingGroup *shgroup, const char *name, const int *value, int arraysize)
 
void DRW_shgroup_uniform_int (DRWShadingGroup *shgroup, const char *name, const int *value, int arraysize)
 
void DRW_shgroup_uniform_ivec2 (DRWShadingGroup *shgroup, const char *name, const int *value, int arraysize)
 
void DRW_shgroup_uniform_ivec3 (DRWShadingGroup *shgroup, const char *name, const int *value, int arraysize)
 
void DRW_shgroup_uniform_ivec4 (DRWShadingGroup *shgroup, const char *name, const int *value, int arraysize)
 
void DRW_shgroup_uniform_mat3 (DRWShadingGroup *shgroup, const char *name, const float(*value)[3])
 
void DRW_shgroup_uniform_mat4 (DRWShadingGroup *shgroup, const char *name, const float(*value)[4])
 
void DRW_shgroup_uniform_image (DRWShadingGroup *shgroup, const char *name, const GPUTexture *tex)
 
void DRW_shgroup_uniform_image_ref (DRWShadingGroup *shgroup, const char *name, GPUTexture **tex)
 
void DRW_shgroup_uniform_int_copy (DRWShadingGroup *shgroup, const char *name, const int value)
 
void DRW_shgroup_uniform_ivec2_copy (DRWShadingGroup *shgroup, const char *name, const int *value)
 
void DRW_shgroup_uniform_ivec3_copy (DRWShadingGroup *shgroup, const char *name, const int *value)
 
void DRW_shgroup_uniform_ivec4_copy (DRWShadingGroup *shgroup, const char *name, const int *value)
 
void DRW_shgroup_uniform_bool_copy (DRWShadingGroup *shgroup, const char *name, const bool value)
 
void DRW_shgroup_uniform_float_copy (DRWShadingGroup *shgroup, const char *name, const float value)
 
void DRW_shgroup_uniform_vec2_copy (DRWShadingGroup *shgroup, const char *name, const float *value)
 
void DRW_shgroup_uniform_vec3_copy (DRWShadingGroup *shgroup, const char *name, const float *value)
 
void DRW_shgroup_uniform_vec4_copy (DRWShadingGroup *shgroup, const char *name, const float *value)
 
void DRW_shgroup_uniform_vec4_array_copy (DRWShadingGroup *shgroup, const char *name, const float(*value)[4], int arraysize)
 
bool DRW_shgroup_is_empty (DRWShadingGroup *shgroup)
 
DRWPassDRW_pass_create (const char *name, DRWState state)
 
DRWPassDRW_pass_create_instance (const char *name, DRWPass *original, DRWState state)
 
void DRW_pass_link (DRWPass *first, DRWPass *second)
 
void DRW_pass_foreach_shgroup (DRWPass *pass, void(*callback)(void *userData, DRWShadingGroup *shgroup), void *userData)
 
void DRW_pass_sort_shgroup_z (DRWPass *pass)
 
void DRW_pass_sort_shgroup_reverse (DRWPass *pass)
 
bool DRW_pass_is_empty (DRWPass *pass)
 
DRWViewDRW_view_create (const float viewmat[4][4], const float winmat[4][4], const float(*culling_viewmat)[4], const float(*culling_winmat)[4], DRWCallVisibilityFn *visibility_fn)
 
DRWViewDRW_view_create_sub (const DRWView *parent_view, const float viewmat[4][4], const float winmat[4][4])
 
void DRW_view_update (DRWView *view, const float viewmat[4][4], const float winmat[4][4], const float(*culling_viewmat)[4], const float(*culling_winmat)[4])
 
void DRW_view_update_sub (DRWView *view, const float viewmat[4][4], const float winmat[4][4])
 
const DRWViewDRW_view_default_get (void)
 
void DRW_view_default_set (DRWView *view)
 
void DRW_view_reset (void)
 
void DRW_view_set_active (DRWView *view)
 
void DRW_view_clip_planes_set (DRWView *view, float(*planes)[4], int plane_len)
 
void DRW_view_camtexco_set (DRWView *view, float texco[4])
 
void DRW_view_winmat_get (const DRWView *view, float mat[4][4], bool inverse)
 
void DRW_view_viewmat_get (const DRWView *view, float mat[4][4], bool inverse)
 
void DRW_view_persmat_get (const DRWView *view, float mat[4][4], bool inverse)
 
void DRW_view_frustum_corners_get (const DRWView *view, BoundBox *corners)
 
void DRW_view_frustum_planes_get (const DRWView *view, float planes[6][4])
 
float DRW_view_near_distance_get (const DRWView *view)
 
float DRW_view_far_distance_get (const DRWView *view)
 
bool DRW_view_is_persp_get (const DRWView *view)
 
bool DRW_culling_sphere_test (const DRWView *view, const BoundSphere *bsphere)
 
bool DRW_culling_box_test (const DRWView *view, const BoundBox *bbox)
 
bool DRW_culling_plane_test (const DRWView *view, const float plane[4])
 
bool DRW_culling_min_max_test (const DRWView *view, float obmat[4][4], float min[3], float max[3])
 
void DRW_culling_frustum_corners_get (const DRWView *view, BoundBox *corners)
 
void DRW_culling_frustum_planes_get (const DRWView *view, float planes[6][4])
 
const floatDRW_viewport_size_get (void)
 
const floatDRW_viewport_invert_size_get (void)
 
const floatDRW_viewport_screenvecs_get (void)
 
const floatDRW_viewport_pixelsize_get (void)
 
struct DefaultFramebufferListDRW_viewport_framebuffer_list_get (void)
 
struct DefaultTextureListDRW_viewport_texture_list_get (void)
 
void DRW_viewport_request_redraw (void)
 
void DRW_render_to_image (struct RenderEngine *engine, struct Depsgraph *depsgraph)
 
void DRW_render_object_iter (void *vedata, struct RenderEngine *engine, struct Depsgraph *depsgraph, void(*callback)(void *vedata, struct Object *ob, struct RenderEngine *engine, struct Depsgraph *depsgraph))
 
void DRW_render_instance_buffer_finish (void)
 
void DRW_render_set_time (struct RenderEngine *engine, struct Depsgraph *depsgraph, int frame, float subframe)
 
void DRW_render_viewport_size_set (const int size[2])
 
void DRW_custom_pipeline (DrawEngineType *draw_engine_type, struct Depsgraph *depsgraph, void(*callback)(void *vedata, void *user_data), void *user_data)
 
void DRW_cache_restart (void)
 
void * DRW_view_layer_engine_data_get (DrawEngineType *engine_type)
 
void ** DRW_view_layer_engine_data_ensure_ex (struct ViewLayer *view_layer, DrawEngineType *engine_type, void(*callback)(void *storage))
 
void ** DRW_view_layer_engine_data_ensure (DrawEngineType *engine_type, void(*callback)(void *storage))
 
DrawDataDRW_drawdata_get (ID *id, DrawEngineType *engine_type)
 
DrawDataDRW_drawdata_ensure (ID *id, DrawEngineType *engine_type, size_t size, DrawDataInitCb init_cb, DrawDataFreeCb free_cb)
 
void ** DRW_duplidata_get (void *vedata)
 
bool DRW_object_is_renderable (const struct Object *ob)
 
bool DRW_object_is_in_edit_mode (const struct Object *ob)
 
int DRW_object_visibility_in_active_context (const struct Object *ob)
 
bool DRW_object_is_flat_normal (const struct Object *ob)
 
bool DRW_object_use_hide_faces (const struct Object *ob)
 
bool DRW_object_is_visible_psys_in_active_context (const struct Object *object, const struct ParticleSystem *psys)
 
struct ObjectDRW_object_get_dupli_parent (const struct Object *ob)
 
struct DupliObjectDRW_object_get_dupli (const struct Object *ob)
 
void DRW_draw_pass (DRWPass *pass)
 
void DRW_draw_pass_subset (DRWPass *pass, DRWShadingGroup *start_group, DRWShadingGroup *end_group)
 
void DRW_draw_callbacks_pre_scene (void)
 
void DRW_draw_callbacks_post_scene (void)
 
void DRW_state_reset_ex (DRWState state)
 
void DRW_state_reset (void)
 
void DRW_state_lock (DRWState state)
 
void DRW_select_load_id (uint id)
 
bool DRW_state_is_fbo (void)
 
bool DRW_state_is_select (void)
 
bool DRW_state_is_depth (void)
 
bool DRW_state_is_image_render (void)
 
bool DRW_state_do_color_management (void)
 
bool DRW_state_is_scene_render (void)
 
bool DRW_state_is_opengl_render (void)
 
bool DRW_state_is_playback (void)
 
bool DRW_state_is_navigating (void)
 
bool DRW_state_show_text (void)
 
bool DRW_state_draw_support (void)
 
bool DRW_state_draw_background (void)
 
const DRWContextStateDRW_context_state_get (void)
 

Macro Definition Documentation

◆ DRW_buffer_add_entry

#define DRW_buffer_add_entry (   buffer,
  ... 
)
Value:
do { \
const void *array[] = {__VA_ARGS__}; \
DRW_buffer_add_entry_array(buffer, array, (sizeof(array) / sizeof(*array))); \
} while (0)
__kernel void ccl_constant KernelData ccl_global void ccl_global char ccl_global int ccl_global char ccl_global unsigned int ccl_global float * buffer

Definition at line 468 of file DRW_render.h.

◆ DRW_PASS_CREATE

#define DRW_PASS_CREATE (   pass,
  state 
)    (pass = DRW_pass_create(#pass, state))

Definition at line 593 of file DRW_render.h.

◆ DRW_PASS_INSTANCE_CREATE

#define DRW_PASS_INSTANCE_CREATE (   pass,
  original,
  state 
)     (pass = DRW_pass_create_instance(#pass, (original), state))

Definition at line 594 of file DRW_render.h.

◆ DRW_shader_create

#define DRW_shader_create (   vert,
  geom,
  frag,
  defines 
)     DRW_shader_create_ex(vert, geom, frag, defines, __func__)

Definition at line 235 of file DRW_render.h.

◆ DRW_shader_create_fullscreen

#define DRW_shader_create_fullscreen (   frag,
  defines 
)     DRW_shader_create_fullscreen_ex(frag, defines, __func__)

Definition at line 241 of file DRW_render.h.

◆ DRW_shader_create_fullscreen_with_shaderlib

#define DRW_shader_create_fullscreen_with_shaderlib (   frag,
  lib,
  defines 
)     DRW_shader_create_fullscreen_with_shaderlib_ex(frag, lib, defines, __func__)

Definition at line 243 of file DRW_render.h.

◆ DRW_shader_create_with_lib

#define DRW_shader_create_with_lib (   vert,
  geom,
  frag,
  lib,
  defines 
)     DRW_shader_create_with_lib_ex(vert, geom, frag, lib, defines, __func__)

Definition at line 237 of file DRW_render.h.

◆ DRW_shader_create_with_shaderlib

#define DRW_shader_create_with_shaderlib (   vert,
  geom,
  frag,
  lib,
  defines 
)     DRW_shader_create_with_shaderlib_ex(vert, geom, frag, lib, defines, __func__)

Definition at line 239 of file DRW_render.h.

◆ DRW_SHADER_FREE_SAFE

#define DRW_SHADER_FREE_SAFE (   shader)
Value:
do { \
if (shader != NULL) { \
DRW_shader_free(shader); \
shader = NULL; \
} \
} while (0)
void KERNEL_FUNCTION_FULL_NAME() shader(KernelGlobals *kg, uint4 *input, float4 *output, int type, int filter, int i, int offset, int sample)

Definition at line 279 of file DRW_render.h.

◆ DRW_SHADER_LIB_ADD

#define DRW_SHADER_LIB_ADD (   lib,
  lib_name 
)     DRW_shader_library_add_file(lib, datatoc_##lib_name##_glsl, STRINGIFY(lib_name) ".glsl")

Definition at line 291 of file DRW_render.h.

◆ DRW_SHADER_LIB_FREE_SAFE

#define DRW_SHADER_LIB_FREE_SAFE (   lib)
Value:
do { \
if (lib != NULL) { \
DRW_shader_library_free(lib); \
lib = NULL; \
} \
} while (0)
DRWShaderLibrary * lib

Definition at line 298 of file DRW_render.h.

◆ DRW_shgroup_call

#define DRW_shgroup_call (   shgroup,
  geom,
  ob 
)     DRW_shgroup_call_ex(shgroup, ob, NULL, geom, false, NULL)

Definition at line 420 of file DRW_render.h.

◆ DRW_shgroup_call_no_cull

#define DRW_shgroup_call_no_cull (   shgroup,
  geom,
  ob 
)     DRW_shgroup_call_ex(shgroup, ob, NULL, geom, true, NULL)

Definition at line 433 of file DRW_render.h.

◆ DRW_shgroup_call_obmat

#define DRW_shgroup_call_obmat (   shgroup,
  geom,
  obmat 
)     DRW_shgroup_call_ex(shgroup, NULL, obmat, geom, false, NULL)

Definition at line 424 of file DRW_render.h.

◆ DRW_shgroup_call_with_callback

#define DRW_shgroup_call_with_callback (   shgroup,
  geom,
  ob,
  user_data 
)     DRW_shgroup_call_ex(shgroup, ob, NULL, geom, false, user_data)

Definition at line 429 of file DRW_render.h.

◆ DRW_shgroup_instance_format

#define DRW_shgroup_instance_format (   format,
  ... 
)
Value:
do { \
if (format == NULL) { \
DRWInstanceAttrFormat drw_format[] = __VA_ARGS__; \
drw_format, (sizeof(drw_format) / sizeof(DRWInstanceAttrFormat))); \
} \
} while (0)
struct GPUVertFormat * DRW_shgroup_instance_format_array(const DRWInstanceAttrFormat attrs[], int arraysize)
format
Definition: logImageCore.h:47

Definition at line 391 of file DRW_render.h.

◆ DRW_STATE_BLEND_ENABLED

#define DRW_STATE_BLEND_ENABLED
Value:
DRW_STATE_BLEND_ALPHA_PREMUL | DRW_STATE_BLEND_BACKGROUND | DRW_STATE_BLEND_OIT | \
@ DRW_STATE_BLEND_ALPHA
Definition: DRW_render.h:340
@ DRW_STATE_BLEND_ADD
Definition: DRW_render.h:336
@ DRW_STATE_BLEND_BACKGROUND
Definition: DRW_render.h:343
@ DRW_STATE_BLEND_SUB
Definition: DRW_render.h:346
@ DRW_STATE_BLEND_OIT
Definition: DRW_render.h:344
@ DRW_STATE_LOGIC_INVERT
Definition: DRW_render.h:349
@ DRW_STATE_BLEND_ADD_FULL
Definition: DRW_render.h:338
@ DRW_STATE_BLEND_CUSTOM
Definition: DRW_render.h:348

Definition at line 362 of file DRW_render.h.

◆ DRW_STATE_DEFAULT

Definition at line 360 of file DRW_render.h.

◆ DRW_STATE_DEPTH_TEST_ENABLED

#define DRW_STATE_DEPTH_TEST_ENABLED
Value:
@ DRW_STATE_DEPTH_LESS
Definition: DRW_render.h:322
@ DRW_STATE_DEPTH_GREATER_EQUAL
Definition: DRW_render.h:326
@ DRW_STATE_DEPTH_LESS_EQUAL
Definition: DRW_render.h:323
@ DRW_STATE_DEPTH_ALWAYS
Definition: DRW_render.h:321
@ DRW_STATE_DEPTH_GREATER
Definition: DRW_render.h:325

Definition at line 369 of file DRW_render.h.

◆ DRW_STATE_RASTERIZER_ENABLED

#define DRW_STATE_RASTERIZER_ENABLED
Value:
DRW_STATE_WRITE_STENCIL_SHADOW_PASS | DRW_STATE_WRITE_STENCIL_SHADOW_FAIL)
@ DRW_STATE_WRITE_STENCIL_SHADOW_FAIL
Definition: DRW_render.h:319
@ DRW_STATE_WRITE_DEPTH
Definition: DRW_render.h:314
@ DRW_STATE_WRITE_COLOR
Definition: DRW_render.h:315
@ DRW_STATE_WRITE_STENCIL
Definition: DRW_render.h:317

Definition at line 366 of file DRW_render.h.

◆ DRW_STATE_STENCIL_TEST_ENABLED

#define DRW_STATE_STENCIL_TEST_ENABLED    (DRW_STATE_STENCIL_ALWAYS | DRW_STATE_STENCIL_EQUAL | DRW_STATE_STENCIL_NEQUAL)

Definition at line 372 of file DRW_render.h.

◆ DRW_STATE_WRITE_STENCIL_ENABLED

#define DRW_STATE_WRITE_STENCIL_ENABLED
Value:
DRW_STATE_WRITE_STENCIL_SHADOW_FAIL)
@ DRW_STATE_WRITE_STENCIL_SHADOW_PASS
Definition: DRW_render.h:318

Definition at line 374 of file DRW_render.h.

◆ DRW_TEXTURE_FREE_SAFE

#define DRW_TEXTURE_FREE_SAFE (   tex)
Value:
do { \
if (tex != NULL) { \
DRW_texture_free(tex); \
tex = NULL; \
} \
} while (0)

Definition at line 180 of file DRW_render.h.

◆ DRW_UBO_FREE_SAFE

#define DRW_UBO_FREE_SAFE (   ubo)
Value:
do { \
if (ubo != NULL) { \
GPU_uniformbuf_free(ubo); \
ubo = NULL; \
} \
} while (0)

Definition at line 188 of file DRW_render.h.

◆ DRW_VIEWPORT_DATA_SIZE

#define DRW_VIEWPORT_DATA_SIZE (   ty)
Value:
{ \
DRW_VIEWPORT_LIST_SIZE(*(((ty *)NULL)->fbl)), DRW_VIEWPORT_LIST_SIZE(*(((ty *)NULL)->txl)), \
DRW_VIEWPORT_LIST_SIZE(*(((ty *)NULL)->psl)), \
DRW_VIEWPORT_LIST_SIZE(*(((ty *)NULL)->stl)), \
}
#define DRW_VIEWPORT_LIST_SIZE(list)
Definition: DRW_render.h:93

Definition at line 97 of file DRW_render.h.

◆ DRW_VIEWPORT_LIST_SIZE

#define DRW_VIEWPORT_LIST_SIZE (   list)     (sizeof(list) == sizeof(DRWViewportEmptyList) ? 0 : ((sizeof(list)) / sizeof(void *)))

Definition at line 93 of file DRW_render.h.

Typedef Documentation

◆ BoundSphere

typedef struct BoundSphere BoundSphere

◆ DrawEngineDataSize

◆ DrawEngineType

◆ DRWCallBuffer

typedef struct DRWCallBuffer DRWCallBuffer

Definition at line 1 of file DRW_render.h.

◆ DRWCallVisibilityFn

typedef bool() DRWCallVisibilityFn(bool vis_in, void *user_data)

Definition at line 410 of file DRW_render.h.

◆ DRWContextState

◆ DRWInstanceAttrFormat

◆ DRWInterface

typedef struct DRWInterface DRWInterface

Definition at line 1 of file DRW_render.h.

◆ DRWPass

typedef struct DRWPass DRWPass

Definition at line 1 of file DRW_render.h.

◆ DRWShaderLibrary

Definition at line 1 of file DRW_render.h.

◆ DRWShadingGroup

Definition at line 1 of file DRW_render.h.

◆ DRWUniform

typedef struct DRWUniform DRWUniform

Definition at line 1 of file DRW_render.h.

◆ DRWView

typedef struct DRWView DRWView

Definition at line 1 of file DRW_render.h.

◆ DRWViewportEmptyList

typedef char DRWViewportEmptyList

Definition at line 91 of file DRW_render.h.

◆ GPUMaterialEvalCallbackFn

typedef void(* GPUMaterialEvalCallbackFn) (struct GPUMaterial *mat, int options, const char **vert_code, const char **geom_code, const char **frag_lib, const char **defines)

Definition at line 200 of file DRW_render.h.

Enumeration Type Documentation

◆ DRWState

enum DRWState
Enumerator
DRW_STATE_WRITE_DEPTH 

Write mask

DRW_STATE_WRITE_COLOR 
DRW_STATE_WRITE_STENCIL 
DRW_STATE_WRITE_STENCIL_SHADOW_PASS 
DRW_STATE_WRITE_STENCIL_SHADOW_FAIL 
DRW_STATE_DEPTH_ALWAYS 

Depth test. These options are mutual exclusive and packed into 3 bits

DRW_STATE_DEPTH_LESS 
DRW_STATE_DEPTH_LESS_EQUAL 
DRW_STATE_DEPTH_EQUAL 
DRW_STATE_DEPTH_GREATER 
DRW_STATE_DEPTH_GREATER_EQUAL 
DRW_STATE_CULL_BACK 

Culling test

DRW_STATE_CULL_FRONT 
DRW_STATE_STENCIL_ALWAYS 

Stencil test . These options are mutually exclusive and packed into 2 bits.

DRW_STATE_STENCIL_EQUAL 
DRW_STATE_STENCIL_NEQUAL 
DRW_STATE_BLEND_ADD 

Blend state. These options are mutual exclusive and packed into 4 bits

DRW_STATE_BLEND_ADD_FULL 

Same as additive but let alpha accumulate without pre-multiply.

DRW_STATE_BLEND_ALPHA 

Standard alpha blending.

DRW_STATE_BLEND_ALPHA_PREMUL 

Use that if color is already premult by alpha.

DRW_STATE_BLEND_BACKGROUND 
DRW_STATE_BLEND_OIT 
DRW_STATE_BLEND_MUL 
DRW_STATE_BLEND_SUB 
DRW_STATE_BLEND_CUSTOM 

Use dual source blending. WARNING: Only one color buffer allowed.

DRW_STATE_LOGIC_INVERT 
DRW_STATE_BLEND_ALPHA_UNDER_PREMUL 
DRW_STATE_IN_FRONT_SELECT 
DRW_STATE_SHADOW_OFFSET 
DRW_STATE_CLIP_PLANES 
DRW_STATE_FIRST_VERTEX_CONVENTION 
DRW_STATE_PROGRAM_POINT_SIZE 

DO NOT USE. Assumed always enabled. Only used internally.

Definition at line 312 of file DRW_render.h.

◆ DRWTextureFlag

Enumerator
DRW_TEX_FILTER 
DRW_TEX_WRAP 
DRW_TEX_COMPARE 
DRW_TEX_MIPMAP 

Definition at line 138 of file DRW_render.h.

◆ eDRWAttrType

Enumerator
DRW_ATTR_INT 
DRW_ATTR_FLOAT 

Definition at line 378 of file DRW_render.h.

Function Documentation

◆ DRW_buffer_add_entry_array()

void DRW_buffer_add_entry_array ( DRWCallBuffer callbuf,
const void *  attr[],
uint  attr_len 
)

◆ DRW_buffer_add_entry_struct()

void DRW_buffer_add_entry_struct ( DRWCallBuffer callbuf,
const void *  data 
)

◆ DRW_cache_restart()

void DRW_cache_restart ( void  )

◆ DRW_context_state_get()

const DRWContextState* DRW_context_state_get ( void  )

Definition at line 2902 of file draw_manager.c.

References DRWManager::draw_ctx, and DST.

Referenced by basic_cache_init(), basic_cache_populate(), basic_engine_init(), camera_view3d_reconstruction(), draw_armature_pose(), drw_batch_cache_generate_requested(), DRW_cache_gpencil_face_wireframe_get(), DRW_draw_cursor(), DRW_draw_cursor_2d(), DRW_draw_gizmo_2d(), DRW_draw_gizmo_3d(), DRW_draw_region_info(), DRW_hair_pos_buffer_get(), DRW_mball_batch_cache_pos_vertbuf_get(), DRW_metaball_batch_cache_get_edge_detection(), DRW_metaball_batch_cache_get_triangles_with_normals(), DRW_metaball_batch_cache_get_wireframes_face(), DRW_object_is_visible_psys_in_active_context(), DRW_object_wire_theme_get(), drw_particle_get_hair_source(), drw_particle_update_ptcache(), drw_particle_update_ptcache_edit(), DRW_render_object_iter(), drw_sculpt_generate_calls(), DRW_shgroup_hair_create_sub(), DRW_volume_batch_cache_get_wireframes_face(), EEVEE_bloom_init(), eevee_cache_finish(), EEVEE_cache_populate(), EEVEE_cryptomatte_cache_populate(), eevee_cryptomatte_download_buffer(), EEVEE_cryptomatte_output_accumulate(), EEVEE_cryptomatte_output_init(), EEVEE_cryptomatte_particle_hair_cache_populate(), eevee_cryptomatte_postprocess_weights(), EEVEE_cryptomatte_render_result(), EEVEE_cryptomatte_renderpasses_init(), eevee_cryptomatte_shading_group_create(), EEVEE_cryptomatte_store_metadata(), EEVEE_depth_of_field_init(), eevee_draw_scene(), eevee_engine_init(), eevee_light_setup(), EEVEE_lightprobes_cache_finish(), EEVEE_lightprobes_cache_init(), EEVEE_lightprobes_init(), EEVEE_lightprobes_refresh(), EEVEE_lookdev_cache_init(), EEVEE_lookdev_draw(), eevee_lookdev_hdri_preview_init(), EEVEE_lookdev_init(), EEVEE_materials_cache_init(), EEVEE_materials_cache_populate(), EEVEE_materials_init(), EEVEE_mist_output_init(), EEVEE_motion_blur_cache_init(), EEVEE_motion_blur_cache_populate(), EEVEE_motion_blur_init(), EEVEE_occlusion_init(), EEVEE_particle_hair_cache_populate(), eevee_render_result_aovs(), eevee_render_to_image(), EEVEE_renderpasses_init(), EEVEE_screen_raytrace_init(), EEVEE_shadows_init(), EEVEE_subsurface_cache_init(), EEVEE_temporal_sampling_init(), EEVEE_temporal_sampling_matrices_calc(), eevee_volume_object_mesh_init(), EEVEE_volumes_cache_init(), EEVEE_volumes_init(), external_cache_init(), external_draw_scene(), external_draw_scene_do(), external_engine_init(), GPENCIL_cache_init(), GPENCIL_cache_populate(), GPENCIL_engine_init(), GPENCIL_render_result_z(), GPENCIL_render_to_image(), gpencil_sbuffer_cache_populate(), gpencil_sbuffer_cache_populate_fast(), gpencil_sbuffer_stroke_ensure(), image_cache_image(), image_cache_image_add(), IMAGE_cache_init(), image_draw_finish(), image_gpu_texture_get(), material_opaque(), material_shadow(), material_transparent(), motion_blur_deform_data_get(), motion_path_cache(), OVERLAY_armature_cache_init(), OVERLAY_armature_cache_populate(), OVERLAY_background_cache_init(), OVERLAY_cache_populate(), OVERLAY_camera_cache_populate(), OVERLAY_edit_curve_cache_init(), OVERLAY_edit_gpencil_cache_init(), OVERLAY_edit_gpencil_cache_populate(), OVERLAY_edit_mesh_cache_init(), OVERLAY_edit_mesh_cache_populate(), OVERLAY_edit_mesh_init(), OVERLAY_edit_particle_cache_init(), OVERLAY_edit_particle_cache_populate(), OVERLAY_edit_text_cache_init(), OVERLAY_edit_uv_cache_init(), overlay_edit_uv_cache_populate(), OVERLAY_edit_uv_init(), OVERLAY_empty_cache_populate(), OVERLAY_engine_init(), OVERLAY_extra_cache_populate(), OVERLAY_facing_cache_populate(), OVERLAY_fade_cache_init(), OVERLAY_fade_cache_populate(), OVERLAY_gpencil_cache_init(), OVERLAY_gpencil_cache_populate(), OVERLAY_gpencil_color_names(), overlay_gpencil_draw_stroke_color_name(), OVERLAY_grid_init(), OVERLAY_image_camera_cache_populate(), OVERLAY_image_empty_cache_populate(), OVERLAY_image_init(), OVERLAY_lattice_cache_populate(), OVERLAY_light_cache_populate(), OVERLAY_lightprobe_cache_populate(), OVERLAY_metaball_cache_populate(), OVERLAY_motion_path_cache_populate(), OVERLAY_outline_cache_populate(), OVERLAY_paint_cache_init(), OVERLAY_paint_init(), OVERLAY_particle_cache_init(), OVERLAY_sculpt_cache_populate(), OVERLAY_shader_armature_degrees_of_freedom_solid(), OVERLAY_shader_armature_degrees_of_freedom_wire(), OVERLAY_shader_armature_envelope(), OVERLAY_shader_armature_shape(), OVERLAY_shader_armature_shape_wire(), OVERLAY_shader_armature_sphere(), OVERLAY_shader_armature_stick(), OVERLAY_shader_armature_wire(), OVERLAY_shader_depth_only(), OVERLAY_shader_edit_curve_handle(), OVERLAY_shader_edit_curve_point(), OVERLAY_shader_edit_curve_wire(), OVERLAY_shader_edit_gpencil_point(), OVERLAY_shader_edit_gpencil_wire(), OVERLAY_shader_edit_lattice_point(), OVERLAY_shader_edit_lattice_wire(), OVERLAY_shader_edit_mesh_analysis(), OVERLAY_shader_edit_mesh_edge(), OVERLAY_shader_edit_mesh_face(), OVERLAY_shader_edit_mesh_facedot(), OVERLAY_shader_edit_mesh_normal(), OVERLAY_shader_edit_mesh_skin_root(), OVERLAY_shader_edit_mesh_vert(), OVERLAY_shader_edit_particle_point(), OVERLAY_shader_edit_particle_strand(), OVERLAY_shader_extra(), OVERLAY_shader_extra_grid(), OVERLAY_shader_extra_groundline(), OVERLAY_shader_extra_loose_point(), OVERLAY_shader_extra_point(), OVERLAY_shader_extra_wire(), OVERLAY_shader_facing(), OVERLAY_shader_image(), OVERLAY_shader_motion_path_line(), OVERLAY_shader_motion_path_vert(), OVERLAY_shader_outline_prepass(), OVERLAY_shader_outline_prepass_gpencil(), OVERLAY_shader_outline_prepass_pointcloud(), OVERLAY_shader_paint_face(), OVERLAY_shader_paint_point(), OVERLAY_shader_paint_texture(), OVERLAY_shader_paint_vertcol(), OVERLAY_shader_paint_weight(), OVERLAY_shader_paint_wire(), OVERLAY_shader_particle_dot(), OVERLAY_shader_particle_shape(), OVERLAY_shader_sculpt_mask(), OVERLAY_shader_uniform_color(), OVERLAY_shader_wireframe(), OVERLAY_shader_wireframe_select(), OVERLAY_speaker_cache_populate(), OVERLAY_wireframe_cache_init(), OVERLAY_wireframe_cache_populate(), OVERLAY_wireframe_init(), particle_batch_cache_ensure_pos(), POSE_is_driven_by_active_armature(), select_cache_init(), select_cache_populate(), select_engine_init(), space_image_gpu_texture_get(), workbench_antialiasing_sample_count_get(), workbench_cache_hair_populate(), workbench_cache_texpaint_populate(), workbench_cavity_data_update(), workbench_cavity_samples_ubo_ensure(), workbench_color_type_get(), workbench_dof_engine_init(), workbench_in_front_history_needed(), workbench_private_data_init(), workbench_render(), workbench_render_result_z(), workbench_shadow_data_update(), and workbench_update_material_ubos().

◆ DRW_culling_box_test()

bool DRW_culling_box_test ( const DRWView view,
const BoundBox bbox 
)

◆ DRW_culling_frustum_corners_get()

void DRW_culling_frustum_corners_get ( const DRWView view,
BoundBox corners 
)

Definition at line 476 of file draw_manager_exec.c.

References DST, view, and DRWManager::view_default.

Referenced by workbench_shadow_update().

◆ DRW_culling_frustum_planes_get()

void DRW_culling_frustum_planes_get ( const DRWView view,
float  planes[6][4] 
)

Definition at line 482 of file draw_manager_exec.c.

References DST, view, and DRWManager::view_default.

Referenced by workbench_shadow_update().

◆ DRW_culling_min_max_test()

bool DRW_culling_min_max_test ( const DRWView view,
float  obmat[4][4],
float  min[3],
float  max[3] 
)

◆ DRW_culling_plane_test()

bool DRW_culling_plane_test ( const DRWView view,
const float  plane[4] 
)

Definition at line 450 of file draw_manager_exec.c.

References draw_culling_plane_test(), DST, view, and DRWManager::view_default.

◆ DRW_culling_sphere_test()

bool DRW_culling_sphere_test ( const DRWView view,
const BoundSphere bsphere 
)

Definition at line 434 of file draw_manager_exec.c.

References draw_culling_sphere_test(), DST, view, and DRWManager::view_default.

Referenced by EEVEE_shadows_draw().

◆ DRW_custom_pipeline()

void DRW_custom_pipeline ( DrawEngineType draw_engine_type,
struct Depsgraph depsgraph,
void(*)(void *vedata, void *user_data callback,
void *  user_data 
)

◆ DRW_draw_callbacks_post_scene()

void DRW_draw_callbacks_post_scene ( void  )

◆ DRW_draw_callbacks_pre_scene()

void DRW_draw_callbacks_pre_scene ( void  )

◆ DRW_draw_pass()

void DRW_draw_pass ( DRWPass pass)

Definition at line 1150 of file draw_manager_exec.c.

References drw_draw_pass_ex(), DRWPass::first, DRWPass::last, DRWPass::next, and DRWPass::shgroups.

Referenced by basic_draw_scene(), dof_dilate_tiles_pass_draw(), dof_recursive_reduce(), downsample_planar(), downsample_radiance_cb(), DRW_hair_update(), EEVEE_bloom_draw(), EEVEE_bloom_output_accumulate(), EEVEE_create_minmax_buffer(), EEVEE_cryptomatte_output_accumulate(), EEVEE_depth_of_field_draw(), eevee_draw_scene(), EEVEE_effects_downsample_radiance_buffer(), EEVEE_lightbake_filter_diffuse(), EEVEE_lightbake_filter_glossy(), EEVEE_lightbake_filter_visibility(), eevee_lightbake_render_world_sample(), EEVEE_lookdev_draw(), EEVEE_lut_update_ggx_brdf(), EEVEE_lut_update_ggx_btdf(), EEVEE_mist_output_accumulate(), EEVEE_motion_blur_draw(), EEVEE_occlusion_compute(), EEVEE_occlusion_draw_debug(), EEVEE_occlusion_output_accumulate(), EEVEE_reflection_compute(), EEVEE_reflection_output_accumulate(), EEVEE_render_draw(), eevee_render_draw_background(), EEVEE_renderpasses_postprocess(), EEVEE_shadow_output_accumulate(), EEVEE_shadows_draw_cascades(), EEVEE_shadows_draw_cubemap(), EEVEE_subsurface_compute(), EEVEE_subsurface_data_render(), EEVEE_subsurface_output_accumulate(), EEVEE_temporal_sampling_draw(), EEVEE_update_noise(), EEVEE_velocity_resolve(), EEVEE_volumes_compute(), EEVEE_volumes_output_accumulate(), EEVEE_volumes_resolve(), external_draw_scene(), GPENCIL_antialiasing_draw(), gpencil_draw_mask(), GPENCIL_draw_object(), GPENCIL_draw_scene_depth_only(), IMAGE_draw_scene(), lightbake_render_scene_face(), lightbake_render_scene_reflected(), lightbake_render_world_face(), material_renderpass_accumulate(), max_downsample_cb(), OVERLAY_antialiasing_end(), OVERLAY_armature_draw(), OVERLAY_armature_in_front_draw(), OVERLAY_background_draw(), OVERLAY_edit_curve_draw(), OVERLAY_edit_gpencil_draw(), OVERLAY_edit_lattice_draw(), OVERLAY_edit_mesh_draw(), overlay_edit_mesh_draw_components(), OVERLAY_edit_particle_draw(), OVERLAY_edit_text_draw(), OVERLAY_edit_uv_draw(), OVERLAY_extra_blend_draw(), OVERLAY_extra_centers_draw(), OVERLAY_extra_draw(), OVERLAY_extra_in_front_draw(), OVERLAY_facing_draw(), OVERLAY_facing_infront_draw(), OVERLAY_fade_draw(), OVERLAY_fade_infront_draw(), OVERLAY_gpencil_draw(), OVERLAY_grid_draw(), OVERLAY_image_background_draw(), OVERLAY_image_draw(), OVERLAY_image_in_front_draw(), OVERLAY_image_scene_background_draw(), OVERLAY_metaball_draw(), OVERLAY_metaball_in_front_draw(), OVERLAY_motion_path_draw(), OVERLAY_outline_draw(), OVERLAY_paint_draw(), OVERLAY_particle_draw(), OVERLAY_pose_draw(), OVERLAY_sculpt_draw(), OVERLAY_volume_draw(), OVERLAY_wireframe_draw(), OVERLAY_wireframe_in_front_draw(), OVERLAY_xray_fade_draw(), select_draw_scene(), simple_downsample_cube_cb(), workbench_antialiasing_draw_pass(), workbench_dof_downsample_level(), workbench_dof_draw_pass(), workbench_draw_sample(), workbench_transparent_draw_depth_pass(), and workbench_volume_draw_pass().

◆ DRW_draw_pass_subset()

void DRW_draw_pass_subset ( DRWPass pass,
DRWShadingGroup start_group,
DRWShadingGroup end_group 
)

Definition at line 1158 of file draw_manager_exec.c.

References drw_draw_pass_ex().

Referenced by DRW_hair_update().

◆ DRW_drawdata_ensure()

DrawData* DRW_drawdata_ensure ( ID id,
DrawEngineType engine_type,
size_t  size,
DrawDataInitCb  init_cb,
DrawDataFreeCb  free_cb 
)

◆ DRW_drawdata_get()

DrawData* DRW_drawdata_get ( ID id,
DrawEngineType engine_type 
)

◆ DRW_duplidata_get()

void** DRW_duplidata_get ( void *  vedata)

◆ DRW_object_get_dupli()

struct DupliObject* DRW_object_get_dupli ( const struct Object ob)

◆ DRW_object_get_dupli_parent()

struct Object* DRW_object_get_dupli_parent ( const struct Object ob)

◆ DRW_object_is_flat_normal()

bool DRW_object_is_flat_normal ( const struct Object ob)

◆ DRW_object_is_in_edit_mode()

bool DRW_object_is_in_edit_mode ( const struct Object ob)

◆ DRW_object_is_renderable()

bool DRW_object_is_renderable ( const struct Object ob)

◆ DRW_object_is_visible_psys_in_active_context()

bool DRW_object_is_visible_psys_in_active_context ( const struct Object object,
const struct ParticleSystem psys 
)

◆ DRW_object_resource_id_get()

uint32_t DRW_object_resource_id_get ( Object ob)

◆ DRW_object_use_hide_faces()

bool DRW_object_use_hide_faces ( const struct Object ob)

◆ DRW_object_visibility_in_active_context()

int DRW_object_visibility_in_active_context ( const struct Object ob)

◆ DRW_pass_create()

DRWPass* DRW_pass_create ( const char *  name,
DRWState  state 
)

◆ DRW_pass_create_instance()

DRWPass* DRW_pass_create_instance ( const char *  name,
DRWPass original,
DRWState  state 
)

Definition at line 1989 of file draw_manager_data.c.

References DRW_pass_create(), DRWPass::original, and state.

Referenced by EEVEE_materials_cache_init().

◆ DRW_pass_foreach_shgroup()

void DRW_pass_foreach_shgroup ( DRWPass pass,
void(*)(void *userData, DRWShadingGroup *shgroup)  callback,
void *  userData 
)

◆ DRW_pass_is_empty()

bool DRW_pass_is_empty ( DRWPass pass)

◆ DRW_pass_link()

void DRW_pass_link ( DRWPass first,
DRWPass second 
)

Definition at line 1998 of file draw_manager_data.c.

References BLI_assert, DRWPass::next, and NULL.

Referenced by EEVEE_materials_cache_init(), and EEVEE_motion_blur_cache_init().

◆ DRW_pass_sort_shgroup_reverse()

void DRW_pass_sort_shgroup_reverse ( DRWPass pass)

Reverse Shading group submission order.

Definition at line 2115 of file draw_manager_data.c.

References BLI_linklist_reverse(), DRWPass::first, DRWPass::last, and DRWPass::shgroups.

◆ DRW_pass_sort_shgroup_z()

void DRW_pass_sort_shgroup_z ( DRWPass pass)

◆ DRW_render_instance_buffer_finish()

void DRW_render_instance_buffer_finish ( void  )

◆ DRW_render_object_iter()

void DRW_render_object_iter ( void *  vedata,
struct RenderEngine engine,
struct Depsgraph depsgraph,
void(*)(void *vedata, struct Object *ob, struct RenderEngine *engine, struct Depsgraph *depsgraph callback 
)

◆ DRW_render_set_time()

void DRW_render_set_time ( struct RenderEngine engine,
struct Depsgraph depsgraph,
int  frame,
float  subframe 
)

◆ DRW_render_to_image()

void DRW_render_to_image ( struct RenderEngine engine,
struct Depsgraph depsgraph 
)

◆ DRW_render_viewport_size_set()

void DRW_render_viewport_size_set ( const int  size[2])

◆ DRW_select_load_id()

void DRW_select_load_id ( uint  id)

◆ DRW_shader_create_ex()

struct GPUShader* DRW_shader_create_ex ( const char *  vert,
const char *  geom,
const char *  frag,
const char *  defines,
const char *  name 
)

Definition at line 332 of file draw_manager_shader.c.

References GPU_shader_create(), and NULL.

◆ DRW_shader_create_from_material()

struct GPUMaterial* DRW_shader_create_from_material ( struct Scene scene,
struct Material ma,
struct bNodeTree ntree,
const void *  engine_type,
const int  options,
const bool  is_volume_shader,
const char *  vert,
const char *  geom,
const char *  frag_lib,
const char *  defines,
bool  deferred,
GPUMaterialEvalCallbackFn  callback 
)

◆ DRW_shader_create_from_world()

struct GPUMaterial* DRW_shader_create_from_world ( struct Scene scene,
struct World wo,
struct bNodeTree ntree,
const void *  engine_type,
const int  options,
const bool  is_volume_shader,
const char *  vert,
const char *  geom,
const char *  frag_lib,
const char *  defines,
bool  deferred,
GPUMaterialEvalCallbackFn  callback 
)

◆ DRW_shader_create_fullscreen_ex()

struct GPUShader* DRW_shader_create_fullscreen_ex ( const char *  frag,
const char *  defines,
const char *  name 
)

◆ DRW_shader_create_fullscreen_with_shaderlib_ex()

struct GPUShader* DRW_shader_create_fullscreen_with_shaderlib_ex ( const char *  frag,
const DRWShaderLibrary lib,
const char *  defines,
const char *  name 
)

◆ DRW_shader_create_with_lib_ex()

struct GPUShader* DRW_shader_create_with_lib_ex ( const char *  vert,
const char *  geom,
const char *  frag,
const char *  lib,
const char *  defines,
const char *  name 
)

Definition at line 338 of file draw_manager_shader.c.

References BLI_string_joinN, GPU_shader_create(), lib, MEM_freeN, and NULL.

◆ DRW_shader_create_with_shaderlib_ex()

struct GPUShader* DRW_shader_create_with_shaderlib_ex ( const char *  vert,
const char *  geom,
const char *  frag,
const DRWShaderLibrary lib,
const char *  defines,
const char *  name 
)

◆ DRW_shader_create_with_transform_feedback()

struct GPUShader* DRW_shader_create_with_transform_feedback ( const char *  vert,
const char *  geom,
const char *  defines,
const eGPUShaderTFBType  prim_type,
const char **  varying_names,
const int  varying_count 
)

◆ DRW_shader_find_from_material()

struct GPUMaterial* DRW_shader_find_from_material ( struct Material ma,
const void *  engine_type,
const int  options,
bool  deferred 
)

◆ DRW_shader_find_from_world()

struct GPUMaterial* DRW_shader_find_from_world ( struct World wo,
const void *  engine_type,
const int  options,
bool  deferred 
)

◆ DRW_shader_free()

void DRW_shader_free ( struct GPUShader shader)

Definition at line 544 of file draw_manager_shader.c.

References GPU_shader_free(), and shader().

◆ DRW_shader_library_add_file()

void DRW_shader_library_add_file ( DRWShaderLibrary lib,
char *  lib_code,
const char *  lib_name 
)

◆ DRW_shader_library_create()

DRWShaderLibrary* DRW_shader_library_create ( void  )

◆ DRW_shader_library_create_shader_string()

char* DRW_shader_library_create_shader_string ( const DRWShaderLibrary lib,
const char *  shader_code 
)

◆ DRW_shader_library_free()

void DRW_shader_library_free ( DRWShaderLibrary lib)

Definition at line 579 of file draw_manager_shader.c.

References lib, and MEM_SAFE_FREE.

◆ DRW_shgroup_add_material_resources()

void DRW_shgroup_add_material_resources ( DRWShadingGroup grp,
struct GPUMaterial material 
)

◆ DRW_shgroup_call_buffer()

DRWCallBuffer* DRW_shgroup_call_buffer ( DRWShadingGroup shgroup,
struct GPUVertFormat format,
GPUPrimType  prim_type 
)

◆ DRW_shgroup_call_buffer_instance()

DRWCallBuffer* DRW_shgroup_call_buffer_instance ( DRWShadingGroup shgroup,
struct GPUVertFormat format,
struct GPUBatch geom 
)

◆ DRW_shgroup_call_ex()

void DRW_shgroup_call_ex ( DRWShadingGroup shgroup,
Object ob,
float(*)  obmat[4],
struct GPUBatch geom,
bool  bypass_culling,
void *  user_data 
)

◆ DRW_shgroup_call_instance_range()

void DRW_shgroup_call_instance_range ( DRWShadingGroup shgroup,
Object ob,
struct GPUBatch geom,
uint  i_sta,
uint  i_ct 
)

◆ DRW_shgroup_call_instances()

void DRW_shgroup_call_instances ( DRWShadingGroup shgroup,
Object ob,
struct GPUBatch geom,
uint  count 
)

◆ DRW_shgroup_call_instances_with_attrs()

void DRW_shgroup_call_instances_with_attrs ( DRWShadingGroup shgroup,
Object ob,
struct GPUBatch geom,
struct GPUBatch inst_attributes 
)

◆ DRW_shgroup_call_procedural_lines()

void DRW_shgroup_call_procedural_lines ( DRWShadingGroup sh,
Object ob,
uint  line_count 
)

◆ DRW_shgroup_call_procedural_points()

void DRW_shgroup_call_procedural_points ( DRWShadingGroup sh,
Object ob,
uint  point_count 
)

◆ DRW_shgroup_call_procedural_triangles()

void DRW_shgroup_call_procedural_triangles ( DRWShadingGroup sh,
Object ob,
uint  tri_count 
)

◆ DRW_shgroup_call_range()

void DRW_shgroup_call_range ( DRWShadingGroup shgroup,
Object ob,
struct GPUBatch geom,
uint  v_sta,
uint  v_ct 
)

◆ DRW_shgroup_call_sculpt()

void DRW_shgroup_call_sculpt ( DRWShadingGroup sh,
Object ob,
bool  wire,
bool  mask 
)

◆ DRW_shgroup_call_sculpt_with_materials()

void DRW_shgroup_call_sculpt_with_materials ( DRWShadingGroup **  sh,
int  num_sh,
Object ob 
)

◆ DRW_shgroup_clear_framebuffer()

void DRW_shgroup_clear_framebuffer ( DRWShadingGroup shgroup,
eGPUFrameBufferBits  channels,
uchar  r,
uchar  g,
uchar  b,
uchar  a,
float  depth,
uchar  stencil 
)

◆ DRW_shgroup_create()

DRWShadingGroup* DRW_shgroup_create ( struct GPUShader shader,
DRWPass pass 
)

Definition at line 1383 of file draw_manager_data.c.

References drw_shgroup_create_ex(), drw_shgroup_init(), and shader().

Referenced by basic_cache_init(), dof_bokeh_pass_init(), dof_dilate_tiles_pass_init(), dof_filter_pass_init(), dof_flatten_tiles_pass_init(), dof_gather_pass_init(), dof_recombine_pass_init(), dof_reduce_pass_init(), dof_scatter_pass_init(), dof_setup_pass_init(), drw_hair_particle_cache_get(), eevee_create_bloom_pass(), eevee_cryptomatte_shading_group_create(), EEVEE_effects_cache_init(), EEVEE_lightbake_cache_init(), EEVEE_lightprobes_cache_finish(), EEVEE_lightprobes_cache_init(), EEVEE_lookdev_cache_init(), eevee_lookdev_hdri_preview_init(), EEVEE_lut_update_ggx_brdf(), EEVEE_lut_update_ggx_btdf(), EEVEE_materials_cache_init(), EEVEE_mist_output_init(), EEVEE_motion_blur_cache_init(), EEVEE_motion_blur_cache_populate(), EEVEE_occlusion_cache_init(), EEVEE_occlusion_output_init(), EEVEE_renderpasses_cache_finish(), EEVEE_screen_raytrace_cache_init(), EEVEE_shadow_output_init(), EEVEE_shadows_cache_init(), EEVEE_subsurface_add_pass(), EEVEE_temporal_sampling_cache_init(), EEVEE_volumes_cache_finish(), EEVEE_volumes_cache_init(), EEVEE_volumes_output_init(), external_cache_init(), GPENCIL_antialiasing_init(), GPENCIL_cache_init(), gpencil_layer_cache_add(), gpencil_vfx_pass_create(), image_cache_image(), material_opaque(), material_shadow(), material_transparent(), OVERLAY_antialiasing_cache_init(), OVERLAY_armature_cache_init(), OVERLAY_background_cache_init(), OVERLAY_edit_curve_cache_init(), OVERLAY_edit_gpencil_cache_init(), OVERLAY_edit_lattice_cache_init(), OVERLAY_edit_mesh_cache_init(), OVERLAY_edit_particle_cache_init(), OVERLAY_edit_text_cache_init(), OVERLAY_edit_uv_cache_init(), OVERLAY_extra_cache_init(), OVERLAY_facing_cache_init(), OVERLAY_fade_cache_init(), OVERLAY_gpencil_cache_init(), OVERLAY_grid_cache_init(), OVERLAY_image_camera_cache_populate(), OVERLAY_image_empty_cache_populate(), OVERLAY_metaball_cache_init(), OVERLAY_motion_path_cache_init(), OVERLAY_outline_cache_init(), OVERLAY_paint_cache_init(), OVERLAY_particle_cache_init(), OVERLAY_sculpt_cache_init(), OVERLAY_volume_cache_init(), OVERLAY_volume_extra(), OVERLAY_wireframe_cache_init(), select_cache_init(), workbench_antialiasing_cache_init(), workbench_cavity_cache_init(), workbench_dof_cache_init(), workbench_opaque_cache_init(), workbench_outline_cache_init(), workbench_shadow_cache_init(), workbench_transparent_cache_init(), workbench_volume_modifier_cache_populate(), and workbench_volume_object_cache_populate().

◆ DRW_shgroup_create_sub()

DRWShadingGroup* DRW_shgroup_create_sub ( DRWShadingGroup shgroup)

◆ DRW_shgroup_instance_format_array()

struct GPUVertFormat* DRW_shgroup_instance_format_array ( const DRWInstanceAttrFormat  attrs[],
int  arraysize 
)

◆ DRW_shgroup_is_empty()

bool DRW_shgroup_is_empty ( DRWShadingGroup shgroup)

◆ DRW_shgroup_material_create()

DRWShadingGroup* DRW_shgroup_material_create ( struct GPUMaterial material,
DRWPass pass 
)

◆ DRW_shgroup_state_disable()

void DRW_shgroup_state_disable ( DRWShadingGroup shgroup,
DRWState  state 
)

◆ DRW_shgroup_state_enable()

void DRW_shgroup_state_enable ( DRWShadingGroup shgroup,
DRWState  state 
)

◆ DRW_shgroup_stencil_mask()

void DRW_shgroup_stencil_mask ( DRWShadingGroup shgroup,
uint  mask 
)

◆ DRW_shgroup_stencil_set()

void DRW_shgroup_stencil_set ( DRWShadingGroup shgroup,
uint  write_mask,
uint  reference,
uint  compare_mask 
)

Definition at line 1415 of file draw_manager_data.c.

References drw_command_set_stencil_mask().

◆ DRW_shgroup_transform_feedback_create()

DRWShadingGroup* DRW_shgroup_transform_feedback_create ( struct GPUShader shader,
DRWPass pass,
struct GPUVertBuf tf_target 
)

◆ DRW_shgroup_uniform_block()

void DRW_shgroup_uniform_block ( DRWShadingGroup shgroup,
const char *  name,
const struct GPUUniformBuf ubo 
)

◆ DRW_shgroup_uniform_block_ref()

void DRW_shgroup_uniform_block_ref ( DRWShadingGroup shgroup,
const char *  name,
struct GPUUniformBuf **  ubo 
)

◆ DRW_shgroup_uniform_bool()

void DRW_shgroup_uniform_bool ( DRWShadingGroup shgroup,
const char *  name,
const int *  value,
int  arraysize 
)

◆ DRW_shgroup_uniform_bool_copy()

void DRW_shgroup_uniform_bool_copy ( DRWShadingGroup shgroup,
const char *  name,
const bool  value 
)

◆ DRW_shgroup_uniform_float()

void DRW_shgroup_uniform_float ( DRWShadingGroup shgroup,
const char *  name,
const float value,
int  arraysize 
)

◆ DRW_shgroup_uniform_float_copy()

void DRW_shgroup_uniform_float_copy ( DRWShadingGroup shgroup,
const char *  name,
const float  value 
)

◆ DRW_shgroup_uniform_image()

void DRW_shgroup_uniform_image ( DRWShadingGroup shgroup,
const char *  name,
const GPUTexture tex 
)

◆ DRW_shgroup_uniform_image_ref()

void DRW_shgroup_uniform_image_ref ( DRWShadingGroup shgroup,
const char *  name,
GPUTexture **  tex 
)

◆ DRW_shgroup_uniform_int()

void DRW_shgroup_uniform_int ( DRWShadingGroup shgroup,
const char *  name,
const int *  value,
int  arraysize 
)

◆ DRW_shgroup_uniform_int_copy()

void DRW_shgroup_uniform_int_copy ( DRWShadingGroup shgroup,
const char *  name,
const int  value 
)

◆ DRW_shgroup_uniform_ivec2()

void DRW_shgroup_uniform_ivec2 ( DRWShadingGroup shgroup,
const char *  name,
const int *  value,
int  arraysize 
)

Definition at line 349 of file draw_manager_data.c.

References drw_shgroup_uniform(), and DRW_UNIFORM_INT.

◆ DRW_shgroup_uniform_ivec2_copy()

void DRW_shgroup_uniform_ivec2_copy ( DRWShadingGroup shgroup,
const char *  name,
const int *  value 
)

Definition at line 389 of file draw_manager_data.c.

References drw_shgroup_uniform(), and DRW_UNIFORM_INT_COPY.

Referenced by EEVEE_motion_blur_cache_init().

◆ DRW_shgroup_uniform_ivec3()

void DRW_shgroup_uniform_ivec3 ( DRWShadingGroup shgroup,
const char *  name,
const int *  value,
int  arraysize 
)

Definition at line 357 of file draw_manager_data.c.

References drw_shgroup_uniform(), and DRW_UNIFORM_INT.

Referenced by EEVEE_lightprobes_cache_init().

◆ DRW_shgroup_uniform_ivec3_copy()

void DRW_shgroup_uniform_ivec3_copy ( DRWShadingGroup shgroup,
const char *  name,
const int *  value 
)

Definition at line 394 of file draw_manager_data.c.

References drw_shgroup_uniform(), and DRW_UNIFORM_INT_COPY.

Referenced by OVERLAY_volume_extra().

◆ DRW_shgroup_uniform_ivec4()

void DRW_shgroup_uniform_ivec4 ( DRWShadingGroup shgroup,
const char *  name,
const int *  value,
int  arraysize 
)

Definition at line 365 of file draw_manager_data.c.

References drw_shgroup_uniform(), and DRW_UNIFORM_INT.

Referenced by OVERLAY_edit_mesh_cache_init().

◆ DRW_shgroup_uniform_ivec4_copy()

void DRW_shgroup_uniform_ivec4_copy ( DRWShadingGroup shgroup,
const char *  name,
const int *  value 
)

Definition at line 399 of file draw_manager_data.c.

References drw_shgroup_uniform(), and DRW_UNIFORM_INT_COPY.

Referenced by motion_path_cache().

◆ DRW_shgroup_uniform_mat3()

void DRW_shgroup_uniform_mat3 ( DRWShadingGroup shgroup,
const char *  name,
const float(*)  value[3] 
)

Definition at line 373 of file draw_manager_data.c.

References drw_shgroup_uniform(), and DRW_UNIFORM_FLOAT.

Referenced by EEVEE_lookdev_cache_init().

◆ DRW_shgroup_uniform_mat4()

void DRW_shgroup_uniform_mat4 ( DRWShadingGroup shgroup,
const char *  name,
const float(*)  value[4] 
)

◆ DRW_shgroup_uniform_texture()

void DRW_shgroup_uniform_texture ( DRWShadingGroup shgroup,
const char *  name,
const struct GPUTexture tex 
)

◆ DRW_shgroup_uniform_texture_ex()

void DRW_shgroup_uniform_texture_ex ( DRWShadingGroup shgroup,
const char *  name,
const struct GPUTexture tex,
eGPUSamplerState  sampler_state 
)

◆ DRW_shgroup_uniform_texture_ref()

void DRW_shgroup_uniform_texture_ref ( DRWShadingGroup shgroup,
const char *  name,
struct GPUTexture **  tex 
)

◆ DRW_shgroup_uniform_texture_ref_ex()

void DRW_shgroup_uniform_texture_ref_ex ( DRWShadingGroup shgroup,
const char *  name,
GPUTexture **  tex,
eGPUSamplerState  sampler_state 
)

◆ DRW_shgroup_uniform_vec2()

void DRW_shgroup_uniform_vec2 ( DRWShadingGroup shgroup,
const char *  name,
const float value,
int  arraysize 
)

◆ DRW_shgroup_uniform_vec2_copy()

void DRW_shgroup_uniform_vec2_copy ( DRWShadingGroup shgroup,
const char *  name,
const float value 
)

◆ DRW_shgroup_uniform_vec3()

void DRW_shgroup_uniform_vec3 ( DRWShadingGroup shgroup,
const char *  name,
const float value,
int  arraysize 
)

◆ DRW_shgroup_uniform_vec3_copy()

void DRW_shgroup_uniform_vec3_copy ( DRWShadingGroup shgroup,
const char *  name,
const float value 
)

◆ DRW_shgroup_uniform_vec4()

void DRW_shgroup_uniform_vec4 ( DRWShadingGroup shgroup,
const char *  name,
const float value,
int  arraysize 
)

◆ DRW_shgroup_uniform_vec4_array_copy()

void DRW_shgroup_uniform_vec4_array_copy ( DRWShadingGroup shgroup,
const char *  name,
const float(*)  value[4],
int  arraysize 
)

◆ DRW_shgroup_uniform_vec4_copy()

void DRW_shgroup_uniform_vec4_copy ( DRWShadingGroup shgroup,
const char *  name,
const float value 
)

◆ DRW_state_do_color_management()

bool DRW_state_do_color_management ( void  )

Whether the view transform should be applied.

Definition at line 2827 of file draw_manager.c.

References DRWManager::do_color_management, DST, and DRWManager::options.

◆ DRW_state_draw_background()

bool DRW_state_draw_background ( void  )

Whether we should render the background

Definition at line 2891 of file draw_manager.c.

References DRWManager::draw_background, DST, and DRWManager::options.

Referenced by eevee_draw_scene(), eevee_engine_init(), EEVEE_render_init(), and OVERLAY_background_cache_init().

◆ DRW_state_draw_support()

bool DRW_state_draw_support ( void  )

Should draw support elements Objects center, selection outline, probe data, ...

Definition at line 2881 of file draw_manager.c.

References DRWManager::draw_ctx, DRW_state_is_scene_render(), DST, View3D::flag2, NULL, DRWContextState::v3d, and V3D_HIDE_OVERLAYS.

Referenced by DRW_draw_depth_loop(), EEVEE_lightprobes_cache_init(), and EEVEE_temporal_sampling_init().

◆ DRW_state_is_depth()

bool DRW_state_is_depth ( void  )

◆ DRW_state_is_fbo()

bool DRW_state_is_fbo ( void  )

◆ DRW_state_is_image_render()

bool DRW_state_is_image_render ( void  )

◆ DRW_state_is_navigating()

bool DRW_state_is_navigating ( void  )

Is the user navigating the region.

Definition at line 2862 of file draw_manager.c.

References DRWManager::draw_ctx, DST, RegionView3D::rflag, DRWContextState::rv3d, RV3D_NAVIGATING, and RV3D_PAINTING.

Referenced by EEVEE_temporal_sampling_init(), and workbench_private_data_init().

◆ DRW_state_is_opengl_render()

bool DRW_state_is_opengl_render ( void  )

◆ DRW_state_is_playback()

bool DRW_state_is_playback ( void  )

◆ DRW_state_is_scene_render()

bool DRW_state_is_scene_render ( void  )

◆ DRW_state_is_select()

bool DRW_state_is_select ( void  )

◆ DRW_state_lock()

void DRW_state_lock ( DRWState  state)

◆ DRW_state_reset()

void DRW_state_reset ( void  )

◆ DRW_state_reset_ex()

void DRW_state_reset_ex ( DRWState  state)

Definition at line 276 of file draw_manager_exec.c.

References drw_state_set(), DST, DRWManager::state, and state.

Referenced by DRW_state_reset(), and external_draw_scene_do().

◆ DRW_state_show_text()

bool DRW_state_show_text ( void  )

◆ DRW_texture_create_1d()

struct GPUTexture* DRW_texture_create_1d ( int  w,
eGPUTextureFormat  format,
DRWTextureFlag  flags,
const float fpixels 
)

◆ DRW_texture_create_2d()

struct GPUTexture* DRW_texture_create_2d ( int  w,
int  h,
eGPUTextureFormat  format,
DRWTextureFlag  flags,
const float fpixels 
)

◆ DRW_texture_create_2d_array()

struct GPUTexture* DRW_texture_create_2d_array ( int  w,
int  h,
int  d,
eGPUTextureFormat  format,
DRWTextureFlag  flags,
const float fpixels 
)

◆ DRW_texture_create_3d()

struct GPUTexture* DRW_texture_create_3d ( int  w,
int  h,
int  d,
eGPUTextureFormat  format,
DRWTextureFlag  flags,
const float fpixels 
)

◆ DRW_texture_create_cube()

struct GPUTexture* DRW_texture_create_cube ( int  w,
eGPUTextureFormat  format,
DRWTextureFlag  flags,
const float fpixels 
)

◆ DRW_texture_create_cube_array()

struct GPUTexture* DRW_texture_create_cube_array ( int  w,
int  d,
eGPUTextureFormat  format,
DRWTextureFlag  flags,
const float fpixels 
)

◆ DRW_texture_ensure_2d()

void DRW_texture_ensure_2d ( struct GPUTexture **  tex,
int  w,
int  h,
eGPUTextureFormat  format,
DRWTextureFlag  flags 
)

◆ DRW_texture_ensure_fullscreen_2d()

void DRW_texture_ensure_fullscreen_2d ( struct GPUTexture **  tex,
eGPUTextureFormat  format,
DRWTextureFlag  flags 
)

◆ DRW_texture_free()

void DRW_texture_free ( struct GPUTexture tex)

Definition at line 185 of file draw_manager_texture.c.

References GPU_texture_free(), and tex.

◆ DRW_texture_generate_mipmaps()

void DRW_texture_generate_mipmaps ( struct GPUTexture tex)

Definition at line 180 of file draw_manager_texture.c.

References GPU_texture_generate_mipmap(), and tex.

◆ DRW_texture_pool_query_2d()

struct GPUTexture* DRW_texture_pool_query_2d ( int  w,
int  h,
eGPUTextureFormat  format,
DrawEngineType engine_type 
)

◆ DRW_texture_pool_query_fullscreen()

struct GPUTexture* DRW_texture_pool_query_fullscreen ( eGPUTextureFormat  format,
DrawEngineType engine_type 
)

◆ DRW_view_camtexco_set()

void DRW_view_camtexco_set ( DRWView view,
float  texco[4] 
)

Definition at line 1893 of file draw_manager_data.c.

References copy_v4_v4(), and view.

Referenced by drw_viewport_var_init(), and EEVEE_render_view_sync().

◆ DRW_view_clip_planes_set()

void DRW_view_clip_planes_set ( DRWView view,
float(*)  planes[4],
int  plane_len 
)

This only works if DRWPasses have been tagged with DRW_STATE_CLIP_PLANES, and if the shaders have support for it (see usage of gl_ClipDistance). NOTE: planes must be in world space.

Definition at line 1884 of file draw_manager_data.c.

References BLI_assert, MAX_CLIP_PLANES, and view.

Referenced by drw_viewport_var_init(), EEVEE_temporal_sampling_create_view(), and lightbake_planar_ensure_view().

◆ DRW_view_create()

DRWView* DRW_view_create ( const float  viewmat[4][4],
const float  winmat[4][4],
const float(*)  culling_viewmat[4],
const float(*)  culling_winmat[4],
DRWCallVisibilityFn visibility_fn 
)

◆ DRW_view_create_sub()

DRWView* DRW_view_create_sub ( const DRWView parent_view,
const float  viewmat[4][4],
const float  winmat[4][4] 
)

◆ DRW_view_default_get()

const DRWView* DRW_view_default_get ( void  )

◆ DRW_view_default_set()

void DRW_view_default_set ( DRWView view)

◆ DRW_view_far_distance_get()

float DRW_view_far_distance_get ( const DRWView view)

◆ DRW_view_frustum_corners_get()

void DRW_view_frustum_corners_get ( const DRWView view,
BoundBox corners 
)

Definition at line 1899 of file draw_manager_data.c.

References view.

◆ DRW_view_frustum_planes_get()

void DRW_view_frustum_planes_get ( const DRWView view,
float  planes[6][4] 
)

Definition at line 1906 of file draw_manager_data.c.

References view.

Referenced by drw_sculpt_get_frustum_planes().

◆ DRW_view_is_persp_get()

bool DRW_view_is_persp_get ( const DRWView view)

◆ DRW_view_layer_engine_data_ensure()

void** DRW_view_layer_engine_data_ensure ( DrawEngineType engine_type,
void(*)(void *storage)  callback 
)

◆ DRW_view_layer_engine_data_ensure_ex()

void** DRW_view_layer_engine_data_ensure_ex ( struct ViewLayer view_layer,
DrawEngineType engine_type,
void(*)(void *storage)  callback 
)

◆ DRW_view_layer_engine_data_get()

void* DRW_view_layer_engine_data_get ( DrawEngineType engine_type)

◆ DRW_view_near_distance_get()

float DRW_view_near_distance_get ( const DRWView view)

◆ DRW_view_persmat_get()

void DRW_view_persmat_get ( const DRWView view,
float  mat[4][4],
bool  inverse 
)

◆ DRW_view_reset()

void DRW_view_reset ( void  )

◆ DRW_view_set_active()

void DRW_view_set_active ( DRWView view)

◆ DRW_view_update()

void DRW_view_update ( DRWView view,
const float  viewmat[4][4],
const float  winmat[4][4],
const float(*)  culling_viewmat[4],
const float(*)  culling_winmat[4] 
)

◆ DRW_view_update_sub()

void DRW_view_update_sub ( DRWView view,
const float  viewmat[4][4],
const float  winmat[4][4] 
)

DRWView Update: This is meant to be done on existing views when rendering in a loop and there is no need to allocate more DRWViews.

Definition at line 1779 of file draw_manager_data.c.

References BLI_assert, draw_view_matrix_state_update(), is_negative_m4(), NULL, and view.

Referenced by DRW_view_create_sub(), EEVEE_lookdev_draw(), EEVEE_temporal_sampling_matrices_calc(), render_cubemap(), and workbench_antialiasing_setup().

◆ DRW_view_viewmat_get()

void DRW_view_viewmat_get ( const DRWView view,
float  mat[4][4],
bool  inverse 
)

◆ DRW_view_winmat_get()

void DRW_view_winmat_get ( const DRWView view,
float  mat[4][4],
bool  inverse 
)

◆ DRW_viewport_framebuffer_list_get()

struct DefaultFramebufferList* DRW_viewport_framebuffer_list_get ( void  )

◆ DRW_viewport_invert_size_get()

const float* DRW_viewport_invert_size_get ( void  )

◆ DRW_viewport_pixelsize_get()

const float* DRW_viewport_pixelsize_get ( void  )

Definition at line 454 of file draw_manager.c.

References DST, and DRWManager::pixsize.

Referenced by DRW_globals_update().

◆ DRW_viewport_request_redraw()

void DRW_viewport_request_redraw ( void  )

◆ DRW_viewport_screenvecs_get()

const float* DRW_viewport_screenvecs_get ( void  )

Definition at line 449 of file draw_manager.c.

References DST, and DRWManager::screenvecs.

Referenced by DRW_globals_update(), and EEVEE_lightprobes_cache_init().

◆ DRW_viewport_size_get()

const float* DRW_viewport_size_get ( void  )

◆ DRW_viewport_texture_list_get()

struct DefaultTextureList* DRW_viewport_texture_list_get ( void  )

Definition at line 702 of file draw_manager.c.

References DST, GPU_viewport_texture_list_get(), and DRWManager::viewport.

Referenced by dof_recombine_pass_init(), dof_setup_pass_init(), EEVEE_cryptomatte_output_init(), eevee_draw_scene(), EEVEE_effects_draw_init(), EEVEE_effects_init(), eevee_engine_init(), EEVEE_material_output_init(), EEVEE_mist_output_init(), EEVEE_motion_blur_cache_init(), EEVEE_occlusion_cache_init(), EEVEE_occlusion_output_accumulate(), EEVEE_occlusion_output_init(), EEVEE_render_draw(), EEVEE_render_init(), EEVEE_renderpasses_cache_finish(), EEVEE_shadow_output_init(), EEVEE_subsurface_add_pass(), EEVEE_subsurface_draw_init(), EEVEE_subsurface_output_init(), EEVEE_temporal_sampling_cache_init(), EEVEE_velocity_resolve(), EEVEE_volumes_resolve(), GPENCIL_engine_init(), OVERLAY_antialiasing_cache_finish(), OVERLAY_antialiasing_cache_init(), OVERLAY_antialiasing_init(), OVERLAY_background_cache_init(), OVERLAY_cache_finish(), OVERLAY_edit_mesh_cache_init(), OVERLAY_extra_cache_init(), OVERLAY_grid_cache_init(), OVERLAY_outline_cache_init(), OVERLAY_outline_init(), OVERLAY_xray_depth_copy(), OVERLAY_xray_depth_infront_copy(), select_engine_framebuffer_setup(), workbench_antialiasing_cache_init(), workbench_antialiasing_draw_pass(), workbench_cache_finish(), workbench_cavity_cache_init(), workbench_dof_cache_init(), workbench_opaque_cache_init(), workbench_opaque_engine_init(), workbench_outline_cache_init(), workbench_render_framebuffers_init(), workbench_transparent_engine_init(), workbench_volume_modifier_cache_populate(), and workbench_volume_object_cache_populate().