|
Blender V4.3
|
#include "DRW_engine.hh"#include "DRW_render.hh"#include "DEG_depsgraph_query.hh"#include "ED_view3d.hh"#include "UI_interface.hh"#include "BKE_duplilist.hh"#include "BKE_object.hh"#include "BKE_paint.hh"#include "GPU_capabilities.hh"#include "DNA_space_types.h"#include "draw_manager.hh"#include "overlay_next_instance.hh"#include "overlay_engine.h"#include "overlay_private.hh"Go to the source code of this file.
Typedefs | |
| using | Instance = blender::draw::overlay::Instance |
Functions | |
Engine Callbacks | |
| static void | OVERLAY_engine_init (void *vedata) |
| static void | OVERLAY_cache_init (void *vedata) |
| BLI_INLINE OVERLAY_DupliData * | OVERLAY_duplidata_get (Object *ob, void *vedata, bool *r_do_init) |
| static bool | overlay_object_is_edit_mode (const OVERLAY_PrivateData *pd, const Object *ob) |
| static bool | overlay_object_is_paint_mode (const DRWContextState *draw_ctx, const Object *ob) |
| static bool | overlay_should_fade_object (Object *ob, Object *active_object) |
| static void | OVERLAY_cache_populate (void *vedata, Object *ob) |
| static void | OVERLAY_cache_finish (void *vedata) |
| static void | OVERLAY_draw_scene (void *vedata) |
| static void | OVERLAY_engine_free () |
| static void | OVERLAY_instance_free (void *instance_) |
Variables | |
Engine Type | |
| static const DrawEngineDataSize | overlay_data_size = DRW_VIEWPORT_DATA_SIZE(OVERLAY_Data) |
| DrawEngineType | draw_engine_overlay_type |
Engine for drawing a selection map where the pixels indicate the selection indices.
Definition in file overlay_engine.cc.
Definition at line 36 of file overlay_engine.cc.
|
static |
Definition at line 566 of file overlay_engine.cc.
References DefaultTextureList::depth_in_front, DRW_texture_ensure_fullscreen_2d(), DRW_viewport_framebuffer_list_get(), DRW_viewport_texture_list_get(), ELEM, GPU_DEPTH24_STENCIL8, GPU_framebuffer_ensure_config, DefaultFramebufferList::in_front_fb, OVERLAY_antialiasing_cache_finish(), OVERLAY_armature_cache_finish(), OVERLAY_edit_uv_cache_finish(), OVERLAY_image_cache_finish(), OVERLAY_mode_transfer_cache_finish(), SPACE_IMAGE, SPACE_NODE, and OVERLAY_PrivateData::space_type.
|
static |
Definition at line 143 of file overlay_engine.cc.
References BLI_assert_msg, OVERLAY_PrivateData::ctx_mode, CTX_MODE_EDIT_ARMATURE, CTX_MODE_EDIT_CURVE, CTX_MODE_EDIT_CURVES, CTX_MODE_EDIT_GPENCIL_LEGACY, CTX_MODE_EDIT_GREASE_PENCIL, CTX_MODE_EDIT_LATTICE, CTX_MODE_EDIT_MESH, CTX_MODE_EDIT_METABALL, CTX_MODE_EDIT_POINT_CLOUD, CTX_MODE_EDIT_SURFACE, CTX_MODE_EDIT_TEXT, CTX_MODE_OBJECT, CTX_MODE_PAINT_GPENCIL_LEGACY, CTX_MODE_PAINT_GREASE_PENCIL, CTX_MODE_PAINT_TEXTURE, CTX_MODE_PAINT_VERTEX, CTX_MODE_PAINT_WEIGHT, CTX_MODE_PARTICLE, CTX_MODE_POSE, CTX_MODE_SCULPT, CTX_MODE_SCULPT_CURVES, CTX_MODE_SCULPT_GPENCIL_LEGACY, CTX_MODE_SCULPT_GREASE_PENCIL, CTX_MODE_VERTEX_GPENCIL_LEGACY, CTX_MODE_VERTEX_GREASE_PENCIL, CTX_MODE_WEIGHT_GPENCIL_LEGACY, CTX_MODE_WEIGHT_GREASE_PENCIL, OVERLAY_PrivateData::edit_mesh, OVERLAY_PrivateData::flag, OVERLAY_antialiasing_cache_init(), OVERLAY_armature_cache_init(), OVERLAY_background_cache_init(), OVERLAY_edit_curve_cache_init(), OVERLAY_edit_curves_cache_init(), OVERLAY_edit_gpencil_legacy_cache_init(), OVERLAY_edit_grease_pencil_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_legacy_cache_init(), OVERLAY_grease_pencil_cache_init(), OVERLAY_grid_cache_init(), OVERLAY_image_cache_init(), OVERLAY_metaball_cache_init(), OVERLAY_mode_transfer_cache_init(), OVERLAY_motion_path_cache_init(), OVERLAY_outline_cache_init(), OVERLAY_paint_cache_init(), OVERLAY_particle_cache_init(), OVERLAY_sculpt_cache_init(), OVERLAY_sculpt_curves_cache_init(), OVERLAY_viewer_attribute_cache_init(), OVERLAY_volume_cache_init(), OVERLAY_wireframe_cache_init(), OVERLAY_StorageList::pd, SPACE_IMAGE, SPACE_NODE, OVERLAY_PrivateData::space_type, and V3D_OVERLAY_EDIT_WEIGHT.
|
static |
Definition at line 327 of file overlay_engine.cc.
References OVERLAY_PrivateData::armature, Object::base_flag, OVERLAY_DupliData::base_flag, BASE_FROM_DUPLI, BASE_SELECTED, BLI_listbase_is_empty(), View3D::camera, OVERLAY_PrivateData::ctx_mode, CTX_MODE_PARTICLE, OVERLAY_PrivateData::do_pose_fade_geom, DRW_context_state_get(), DRW_object_get_dupli(), DRW_object_get_dupli_parent(), DRW_object_is_renderable(), DRW_state_is_select(), Object::dt, OVERLAY_PrivateData::edit_mesh, ELEM, OVERLAY_PrivateData::flag, View3DOverlay::flag, OVERLAY_PrivateData::hide_overlays, Object::id, Object::mode, SculptSession::mode_type, OB_ARMATURE, OB_BOUNDBOX, OB_CAMERA, OB_CURVES, OB_CURVES_LEGACY, OB_EMPTY, OB_FONT, OB_GPENCIL_LEGACY, OB_GREASE_PENCIL, OB_LAMP, OB_LATTICE, OB_LIGHTPROBE, OB_MBALL, OB_MESH, OB_MODE_PARTICLE_EDIT, OB_MODE_SCULPT, OB_MODE_SCULPT_CURVES, OB_MODE_SCULPT_GREASE_PENCIL, OB_MODE_TEXTURE_PAINT, OB_MODE_VERTEX_GREASE_PENCIL, OB_MODE_VERTEX_PAINT, OB_MODE_WEIGHT_GREASE_PENCIL, OB_MODE_WEIGHT_PAINT, OB_POINTCLOUD, OB_SOLID, OB_SPEAKER, OB_SURF, OB_VOLUME, OB_WIRE, DRWContextState::obact, DRWContextState::object_mode, ID::orig_id, OVERLAY_PrivateData::overlay, OVERLAY_armature_cache_populate(), OVERLAY_armature_is_pose_mode(), OVERLAY_camera_cache_populate(), OVERLAY_duplidata_get(), OVERLAY_edit_armature_cache_populate(), OVERLAY_edit_curve_cache_populate(), OVERLAY_edit_curves_cache_populate(), OVERLAY_edit_grease_pencil_cache_populate(), OVERLAY_edit_lattice_cache_populate(), OVERLAY_edit_mesh_cache_populate(), OVERLAY_edit_metaball_cache_populate(), OVERLAY_edit_particle_cache_populate(), OVERLAY_edit_surf_cache_populate(), OVERLAY_edit_text_cache_populate(), OVERLAY_empty_cache_populate(), OVERLAY_extra_cache_populate(), OVERLAY_facing_cache_populate(), OVERLAY_fade_cache_populate(), OVERLAY_lattice_cache_populate(), OVERLAY_light_cache_populate(), OVERLAY_lightprobe_cache_populate(), OVERLAY_metaball_cache_populate(), OVERLAY_mode_transfer_cache_populate(), OVERLAY_motion_path_cache_populate(), overlay_object_is_edit_mode(), overlay_object_is_paint_mode(), OVERLAY_outline_cache_populate(), OVERLAY_paint_texture_cache_populate(), OVERLAY_paint_vertex_cache_populate(), OVERLAY_paint_weight_cache_populate(), OVERLAY_particle_cache_populate(), OVERLAY_pose_armature_cache_populate(), OVERLAY_pose_cache_populate(), OVERLAY_sculpt_cache_populate(), OVERLAY_sculpt_curves_cache_populate(), OVERLAY_sculpt_grease_pencil_cache_populate(), overlay_should_fade_object(), OVERLAY_speaker_cache_populate(), OVERLAY_vertex_grease_pencil_cache_populate(), OVERLAY_viewer_attribute_cache_populate(), OVERLAY_viewer_attribute_text(), OVERLAY_volume_cache_populate(), OVERLAY_weight_grease_pencil_cache_populate(), OVERLAY_wireframe_cache_populate(), Object::particlesystem, RegionView3D::persp, DupliObject::preview_base_geometry, DRWContextState::rv3d, RV3D_CAMOB, Object::sculpt, SPACE_IMAGE, OVERLAY_PrivateData::space_type, Object::type, DRWContextState::v3d, OVERLAY_PrivateData::v3d_flag, V3D_OVERLAY_EDIT_WEIGHT, V3D_OVERLAY_FACE_ORIENTATION, V3D_OVERLAY_FADE_INACTIVE, V3D_OVERLAY_HIDE_BONES, V3D_OVERLAY_HIDE_MOTION_PATHS, V3D_OVERLAY_HIDE_OBJECT_XTRAS, V3D_OVERLAY_VIEWER_ATTRIBUTE, V3D_OVERLAY_VIEWER_ATTRIBUTE_TEXT, V3D_SELECT_OUTLINE, and OVERLAY_PrivateData::wireframe_mode.
|
static |
Definition at line 599 of file overlay_engine.cc.
References OVERLAY_PrivateData::ctx_mode, CTX_MODE_EDIT_CURVE, CTX_MODE_EDIT_CURVES, CTX_MODE_EDIT_GPENCIL_LEGACY, CTX_MODE_EDIT_GREASE_PENCIL, CTX_MODE_EDIT_LATTICE, CTX_MODE_EDIT_MESH, CTX_MODE_EDIT_SURFACE, CTX_MODE_EDIT_TEXT, CTX_MODE_PAINT_GPENCIL_LEGACY, CTX_MODE_PAINT_TEXTURE, CTX_MODE_PAINT_VERTEX, CTX_MODE_PAINT_WEIGHT, CTX_MODE_PARTICLE, CTX_MODE_POSE, CTX_MODE_SCULPT, CTX_MODE_SCULPT_CURVES, CTX_MODE_SCULPT_GPENCIL_LEGACY, CTX_MODE_SCULPT_GREASE_PENCIL, CTX_MODE_VERTEX_GPENCIL_LEGACY, CTX_MODE_VERTEX_GREASE_PENCIL, CTX_MODE_WEIGHT_GPENCIL_LEGACY, CTX_MODE_WEIGHT_GREASE_PENCIL, DRW_context_state_get(), DRW_state_is_depth(), DRW_state_is_fbo(), DRW_state_is_select(), DRW_view_set_active(), DRW_viewport_framebuffer_list_get(), View3DOverlay::flag, View3D::flag2, GPU_framebuffer_bind(), GPU_framebuffer_clear_color(), OVERLAY_PrivateData::overlay, OVERLAY_antialiasing_end(), OVERLAY_antialiasing_start(), OVERLAY_armature_draw(), OVERLAY_armature_in_front_draw(), OVERLAY_background_draw(), OVERLAY_FramebufferList::overlay_color_only_fb, OVERLAY_FramebufferList::overlay_default_fb, OVERLAY_edit_curve_draw(), OVERLAY_edit_curves_draw(), OVERLAY_edit_gpencil_legacy_draw(), OVERLAY_edit_grease_pencil_draw(), OVERLAY_edit_lattice_draw(), OVERLAY_edit_mesh_draw(), 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(), DefaultFramebufferList::overlay_fb, OVERLAY_gpencil_legacy_draw(), OVERLAY_grease_pencil_draw(), OVERLAY_grid_draw(), OVERLAY_image_background_draw(), OVERLAY_image_draw(), OVERLAY_image_in_front_draw(), OVERLAY_image_scene_background_draw(), OVERLAY_FramebufferList::overlay_in_front_fb, OVERLAY_FramebufferList::overlay_line_fb, OVERLAY_FramebufferList::overlay_line_in_front_fb, OVERLAY_metaball_draw(), OVERLAY_metaball_in_front_draw(), OVERLAY_mode_transfer_draw(), OVERLAY_mode_transfer_infront_draw(), OVERLAY_motion_path_draw(), DefaultFramebufferList::overlay_only_fb, OVERLAY_outline_draw(), OVERLAY_paint_draw(), OVERLAY_particle_draw(), OVERLAY_pose_draw(), OVERLAY_sculpt_curves_draw(), OVERLAY_sculpt_curves_draw_wires(), OVERLAY_sculpt_draw(), OVERLAY_viewer_attribute_draw(), OVERLAY_volume_draw(), OVERLAY_wireframe_draw(), OVERLAY_wireframe_in_front_draw(), OVERLAY_xray_depth_copy(), OVERLAY_xray_depth_infront_copy(), OVERLAY_xray_fade_draw(), SPACE_IMAGE, SPACE_NODE, OVERLAY_PrivateData::space_type, SPACE_VIEW3D, DRWContextState::v3d, OVERLAY_PrivateData::v3d_flag, V3D_OVERLAY_VIEWER_ATTRIBUTE, V3D_XR_SESSION_SURFACE, and V3D_XR_SHOW_PASSTHROUGH.
| BLI_INLINE OVERLAY_DupliData * OVERLAY_duplidata_get | ( | Object * | ob, |
| void * | vedata, | ||
| bool * | r_do_init ) |
Definition at line 245 of file overlay_engine.cc.
References Object::base_flag, DRW_duplidata_get(), ELEM, MEM_callocN, OB_CURVES_LEGACY, OB_FONT, OB_LATTICE, OB_MESH, OB_SURF, and Object::type.
Referenced by OVERLAY_cache_populate().
|
static |
Definition at line 797 of file overlay_engine.cc.
References blender::draw::overlay::ShaderModule::module_free(), and OVERLAY_shader_free().
|
static |
Definition at line 42 of file overlay_engine.cc.
References BKE_scene_uses_blender_workbench(), OVERLAY_PrivateData::cfra, OVERLAY_PrivateData::clear_in_front, OVERLAY_PrivateData::clipping_state, CTX_data_mode_enum_ex(), OVERLAY_PrivateData::ctx_mode, CTX_MODE_EDIT_CURVES, CTX_MODE_EDIT_MESH, DEG_get_ctime(), DRWContextState::depsgraph, DRW_context_state_get(), DRW_STATE_CLIP_PLANES, SpaceImageOverlay::flag, View3D::flag, View3DOverlay::flag, View3D::flag2, View3D::gridflag, OVERLAY_PrivateData::hide_overlays, int, MEM_callocN, OB_SOLID, OB_WIRE, DRWContextState::obact, DRWContextState::object_edit, DRWContextState::object_mode, OVERLAY_PrivateData::overlay, SpaceImage::overlay, View3D::overlay, OVERLAY_antialiasing_init(), OVERLAY_edit_curves_init(), OVERLAY_edit_mesh_init(), OVERLAY_edit_uv_init(), OVERLAY_facing_init(), OVERLAY_grid_init(), OVERLAY_image_init(), OVERLAY_outline_init(), OVERLAY_paint_init(), OVERLAY_wireframe_init(), OVERLAY_StorageList::pd, DRWContextState::rv3d, RV3D_CLIPPING_ENABLED, DRWContextState::scene, ToolSettings::sculpt, View3DOverlay::sculpt_mode_face_sets_opacity, View3DOverlay::sculpt_mode_mask_opacity, View3D::shading, SI_OVERLAY_SHOW_OVERLAYS, DRWContextState::space_data, SPACE_IMAGE, SPACE_NODE, OVERLAY_PrivateData::space_type, SPACE_VIEW3D, SpaceLink::spacetype, View3DShading::type, OVERLAY_PrivateData::use_in_front, DRWContextState::v3d, OVERLAY_PrivateData::v3d_flag, OVERLAY_PrivateData::v3d_gridflag, V3D_HIDE_OVERLAYS, V3D_OVERLAY_HIDE_BONES, V3D_OVERLAY_HIDE_MOTION_PATHS, V3D_OVERLAY_HIDE_OBJECT_ORIGINS, V3D_OVERLAY_HIDE_OBJECT_XTRAS, V3D_OVERLAY_HIDE_TEXT, V3D_OVERLAY_SCULPT_SHOW_FACE_SETS, V3D_OVERLAY_SCULPT_SHOW_MASK, V3D_OVERLAY_WIREFRAMES, OVERLAY_PrivateData::wireframe_mode, View3DOverlay::wireframe_opacity, View3DOverlay::wireframe_threshold, XRAY_ACTIVE, XRAY_ALPHA, OVERLAY_PrivateData::xray_enabled, OVERLAY_PrivateData::xray_enabled_and_not_wire, and OVERLAY_PrivateData::xray_opacity.
|
static |
Definition at line 803 of file overlay_engine.cc.
References instance.
|
static |
Definition at line 268 of file overlay_engine.cc.
References OVERLAY_PrivateData::ctx_mode, CTX_MODE_EDIT_ARMATURE, CTX_MODE_EDIT_CURVE, CTX_MODE_EDIT_CURVES, CTX_MODE_EDIT_GREASE_PENCIL, CTX_MODE_EDIT_LATTICE, CTX_MODE_EDIT_MESH, CTX_MODE_EDIT_METABALL, CTX_MODE_EDIT_SURFACE, CTX_MODE_EDIT_TEXT, DRW_object_is_in_edit_mode(), OB_ARMATURE, OB_CURVES, OB_CURVES_LEGACY, OB_FONT, OB_GREASE_PENCIL, OB_LATTICE, OB_MBALL, OB_MESH, OB_POINTCLOUD, OB_SURF, OB_VOLUME, and Object::type.
Referenced by OVERLAY_cache_populate().
|
static |
Definition at line 300 of file overlay_engine.cc.
References OB_GREASE_PENCIL, OB_MODE_ALL_PAINT, OB_MODE_VERTEX_GREASE_PENCIL, OB_MODE_WEIGHT_GREASE_PENCIL, DRWContextState::obact, DRWContextState::object_mode, and Object::type.
Referenced by OVERLAY_cache_populate().
Definition at line 310 of file overlay_engine.cc.
References ELEM, Object::mode, OB_MODE_OBJECT, and OB_MODE_POSE.
Referenced by OVERLAY_cache_populate().
| DrawEngineType draw_engine_overlay_type |
Definition at line 817 of file overlay_engine.cc.
Referenced by drw_engine_enable_image_editor(), drw_engines_enable_editors(), drw_engines_enable_overlays(), and DRW_engines_register().
|
static |
Definition at line 815 of file overlay_engine.cc.