Blender
V3.3
|
#include "DNA_screen_types.h"
#include "UI_resources.h"
#include "DRW_engine.h"
#include "DRW_select_buffer.h"
#include "draw_cache_impl.h"
#include "draw_manager.h"
#include "select_engine.h"
#include "select_private.h"
Go to the source code of this file.
Macros | |
#define | SELECT_ENGINE "SELECT_ENGINE" |
Functions | |
Utils | |
static void | select_engine_framebuffer_setup (void) |
Engine Functions | |
static void | select_engine_init (void *vedata) |
static void | select_cache_init (void *vedata) |
static void | select_cache_populate (void *vedata, Object *ob) |
static void | select_draw_scene (void *vedata) |
static void | select_engine_free (void) |
Exposed <tt>select_private.h</tt> functions | |
struct SELECTID_Context * | DRW_select_engine_context_get (void) |
GPUFrameBuffer * | DRW_engine_select_framebuffer_get (void) |
GPUTexture * | DRW_engine_select_texture_get (void) |
Variables | |
struct { | |
struct GPUFrameBuffer * framebuffer_select_id | |
struct GPUTexture * texture_u32 | |
SELECTID_Shaders sh_data [GPU_SHADER_CFG_LEN] | |
struct SELECTID_Context context | |
uint runtime_new_objects | |
} | e_data = {NULL} |
Engine Type | |
static const DrawEngineDataSize | select_data_size = DRW_VIEWPORT_DATA_SIZE(SELECTID_Data) |
DrawEngineType | draw_engine_select_type |
RenderEngineType | DRW_engine_viewport_select_type |
Engine for drawing a selection map where the pixels indicate the selection indices.
Definition in file select_engine.c.
#define SELECT_ENGINE "SELECT_ENGINE" |
Definition at line 23 of file select_engine.c.
GPUFrameBuffer* DRW_engine_select_framebuffer_get | ( | void | ) |
Definition at line 375 of file select_engine.c.
References e_data.
Referenced by DRW_select_buffer_read().
GPUTexture* DRW_engine_select_texture_get | ( | void | ) |
Definition at line 380 of file select_engine.c.
References e_data.
Referenced by DRW_select_buffer_read(), and select_debug_engine_init().
struct SELECTID_Context* DRW_select_engine_context_get | ( | void | ) |
Definition at line 370 of file select_engine.c.
References e_data.
Referenced by DRW_draw_select_id(), DRW_select_buffer_bitmap_from_circle(), DRW_select_buffer_bitmap_from_poly(), DRW_select_buffer_bitmap_from_rect(), DRW_select_buffer_context_create(), DRW_select_buffer_context_offset_for_object_elem(), DRW_select_buffer_elem_get(), and DRW_select_buffer_read().
Definition at line 122 of file select_engine.c.
References BLI_assert, DRW_Global::block, compare_m4m4(), copy_m4_m4(), data, SELECTID_PassList::depth_only_pass, draw_engine_select_type, DRW_context_state_get(), DRW_drawdata_get(), DRW_PASS_CREATE, DRW_shgroup_create(), DRW_shgroup_uniform_float_copy(), DRW_shgroup_uniform_int_copy(), DRW_STATE_CLIP_PLANES, DRW_STATE_DEFAULT, DRW_STATE_FIRST_VERTEX_CONVENTION, e_data, float(), SELECTID_StorageList::g_data, G_draw, GPU_framebuffer_bind(), ID_RECALC_TRANSFORM, DRWContextState::obact, SELECTID_Context::persmat, RegionView3D::persmat, DRWContextState::rv3d, RV3D_CLIPPING_ENABLED, SCE_SELECT_EDGE, SCE_SELECT_FACE, SCE_SELECT_VERTEX, DRWContextState::scene, select_engine_framebuffer_setup(), SELECTID_PassList::select_id_edge_pass, SELECTID_PassList::select_id_face_pass, select_id_get_object_select_mode(), SELECTID_PassList::select_id_vert_pass, sh, DRWContextState::sh_cfg, SELECTID_PrivateData::shgrp_depth_only, SELECTID_PrivateData::shgrp_edge, SELECTID_PrivateData::shgrp_face_flat, SELECTID_PrivateData::shgrp_face_unif, SELECTID_PrivateData::shgrp_vert, GlobalsUboStorage::size_vertex, state, and DRWContextState::v3d.
Definition at line 194 of file select_engine.c.
References Object::data, SELECTID_ObjectData::dd, draw_engine_select_type, SELECTID_ObjectData::drawn_index, DRW_context_state_get(), DRW_culling_min_max_test(), DRW_drawdata_ensure(), DRW_drawdata_get(), DRW_mesh_batch_cache_get_edges_with_select_id(), DRW_mesh_batch_cache_get_surface(), DRW_mesh_batch_cache_get_triangles_with_select_id(), DRW_mesh_batch_cache_get_verts_with_select_id(), DRW_shgroup_call_obmat, Object::dt, e_data, ObjectOffsets::edge, ObjectOffsets::face, SELECTID_StorageList::g_data, GPUBatch, Object::id, SELECTID_ObjectData::is_drawn, max, min, NULL, OB_SOLID, Object::obmat, offset, ObjectOffsets::offset, DrawData::recalc, SCE_SELECT_EDGE, SCE_SELECT_FACE, SCE_SELECT_VERTEX, select_id_draw_object(), select_id_object_min_max(), SELECTID_PrivateData::shgrp_depth_only, DRWContextState::v3d, ObjectOffsets::vert, and SELECTID_PrivateData::view_subregion.
Definition at line 267 of file select_engine.c.
References DefaultFramebufferList::depth_only_fb, SELECTID_PassList::depth_only_pass, DRW_draw_pass(), DRW_pass_is_empty(), DRW_view_set_active(), DRW_viewport_framebuffer_list_get(), e_data, SELECTID_StorageList::g_data, GPU_framebuffer_bind(), SCE_SELECT_EDGE, SCE_SELECT_VERTEX, SELECTID_PassList::select_id_edge_pass, SELECTID_PassList::select_id_face_pass, SELECTID_PassList::select_id_vert_pass, SELECTID_PrivateData::view_edges, SELECTID_PrivateData::view_faces, and SELECTID_PrivateData::view_verts.
Definition at line 40 of file select_engine.c.
References DefaultTextureList::depth, DRW_viewport_texture_list_get(), e_data, GPU_framebuffer_check_valid(), GPU_framebuffer_create(), GPU_framebuffer_texture_attach(), GPU_R32UI, GPU_texture_create_2d(), GPU_texture_free(), GPU_texture_height(), GPU_texture_width(), NULL, and size().
Referenced by select_cache_init().
Definition at line 302 of file select_engine.c.
References ARRAY_SIZE, DRW_SHADER_FREE_SAFE, DRW_TEXTURE_FREE_SAFE, e_data, MEM_SAFE_FREE, SELECTID_Shaders::select_id_flat, SELECTID_Shaders::select_id_uniform, and sh_data.
Definition at line 76 of file select_engine.c.
References DRW_context_state_get(), DRW_view_create(), DRW_view_create_with_zoffset(), DRW_view_default_get(), DRW_view_viewmat_get(), DRW_view_winmat_get(), e_data, SELECTID_StorageList::g_data, GPU_SHADER_CFG_CLIPPED, GPU_shader_create_from_info_name(), MEM_mallocN, NULL, projmat_from_subregion(), DRWContextState::region, DRWContextState::rv3d, SELECTID_Shaders::select_id_flat, SELECTID_Shaders::select_id_uniform, DRWContextState::sh_cfg, sh_data, SELECTID_PrivateData::view_edges, SELECTID_PrivateData::view_faces, SELECTID_PrivateData::view_subregion, SELECTID_PrivateData::view_verts, ARegion::winx, and ARegion::winy.
struct SELECTID_Context context |
Definition at line 31 of file select_engine.c.
DrawEngineType draw_engine_select_type |
Definition at line 325 of file select_engine.c.
Referenced by DRW_draw_select_id(), DRW_engines_register(), DRW_select_buffer_context_offset_for_object_elem(), select_cache_init(), and select_cache_populate().
RenderEngineType DRW_engine_viewport_select_type |
struct { ... } e_data |
struct GPUFrameBuffer* framebuffer_select_id |
Definition at line 28 of file select_engine.c.
uint runtime_new_objects |
Definition at line 33 of file select_engine.c.
|
static |
Definition at line 323 of file select_engine.c.
SELECTID_Shaders sh_data[GPU_SHADER_CFG_LEN] |
Definition at line 31 of file select_engine.c.
Referenced by select_engine_free(), and select_engine_init().
struct GPUTexture* texture_u32 |
Definition at line 29 of file select_engine.c.
Referenced by select_debug_engine_init().