|
Blender
V2.93
|
#include "MEM_guardedalloc.h"#include "DNA_camera_types.h"#include "DNA_object_types.h"#include "DNA_screen_types.h"#include "DNA_space_types.h"#include "DNA_view3d_types.h"#include "BLI_math_vector.h"#include "BLI_string.h"#include "BKE_context.h"#include "BKE_screen.h"#include "BKE_unit.h"#include "RNA_access.h"#include "UI_interface.h"#include "WM_api.h"#include "WM_types.h"#include "ED_screen.h"#include "ED_space_api.h"#include "ED_view3d.h"#include "interface_eyedropper_intern.h"#include "interface_intern.h"Go to the source code of this file.
Classes | |
| struct | DepthDropper |
Typedefs | |
| typedef struct DepthDropper | DepthDropper |
This file defines an eyedropper for picking 3D depth value (primary use is depth-of-field).
Defines:
Definition in file interface_eyedropper_depth.c.
| typedef struct DepthDropper DepthDropper |
|
static |
Definition at line 251 of file interface_eyedropper_depth.c.
References C, wmOperator::customdata, depthdropper_depth_set(), depthdropper_exit(), DepthDropper::init_depth, and DepthDropper::is_set.
Referenced by depthdropper_modal(), and UI_OT_eyedropper_depth().
|
static |
Definition at line 232 of file interface_eyedropper_depth.c.
References C, depthdropper_depth_sample_pt(), and depthdropper_depth_set().
Referenced by depthdropper_modal().
|
static |
Definition at line 241 of file interface_eyedropper_depth.c.
References DepthDropper::accum_depth, DepthDropper::accum_tot, C, and depthdropper_depth_sample_pt().
Referenced by depthdropper_modal().
|
static |
get the ID from the screen.
Definition at line 152 of file interface_eyedropper_depth.c.
References blender::compositor::area(), B_UNIT_LENGTH, BKE_area_find_region_xy(), BKE_screen_find_area_xy(), BKE_unit_value_as_string(), BLI_strncpy(), C, View3D::camera, CTX_data_depsgraph_pointer(), CTX_data_scene(), CTX_wm_area(), CTX_wm_area_set(), CTX_wm_region(), CTX_wm_region_set(), CTX_wm_screen(), depsgraph, ED_region_tag_redraw(), ED_view3d_autodist(), ED_view3d_win_to_3d(), float(), len_v3v3(), DepthDropper::name, NULL, Object::obmat, ARegion::regiondata, RGN_TYPE_WINDOW, scene, SPACE_TYPE_ANY, SPACE_VIEW3D, Scene::unit, view3d_operator_needs_opengl(), RegionView3D::viewinv, ARegion::winrct, ARegion::winx, ARegion::winy, rcti::xmin, and rcti::ymin.
Referenced by depthdropper_depth_sample(), and depthdropper_depth_sample_accum().
|
static |
Definition at line 214 of file interface_eyedropper_depth.c.
References C, DepthDropper::is_set, DepthDropper::prop, DepthDropper::ptr, RNA_property_float_set(), and RNA_property_update().
Referenced by depthdropper_cancel(), depthdropper_depth_sample(), and depthdropper_depth_set_accum().
|
static |
Definition at line 222 of file interface_eyedropper_depth.c.
References DepthDropper::accum_depth, DepthDropper::accum_tot, C, depthdropper_depth_set(), and float().
Referenced by depthdropper_modal().
Definition at line 78 of file interface_eyedropper_depth.c.
References C, eyedropper_draw_cursor_text_region(), and DepthDropper::name.
Referenced by depthdropper_init().
|
static |
Definition at line 326 of file interface_eyedropper_depth.c.
References C, depthdropper_exit(), depthdropper_init(), OPERATOR_CANCELLED, and OPERATOR_FINISHED.
Referenced by UI_OT_eyedropper_depth().
|
static |
Definition at line 131 of file interface_eyedropper_depth.c.
References DepthDropper::art, C, CTX_wm_window(), wmOperator::customdata, DepthDropper::draw_handle_pixel, ED_region_draw_cb_exit(), if(), MEM_freeN, NULL, and WM_cursor_modal_restore().
Referenced by depthdropper_cancel(), depthdropper_exec(), and depthdropper_modal().
|
static |
Definition at line 84 of file interface_eyedropper_depth.c.
References DepthDropper::art, BKE_regiontype_from_id(), BKE_spacetype_from_id(), C, View3D::camera, CTX_wm_region_view3d(), CTX_wm_view3d(), wmOperator::customdata, Object::data, PointerRNA::data, depthdropper_draw_cb(), Camera::dof, DepthDropper::draw_handle_pixel, ED_region_draw_cb_activate(), Camera::id, ID_IS_LINKED, DepthDropper::init_depth, DepthDropper::is_undo, MEM_callocN, MEM_freeN, NULL, RegionView3D::persp, DepthDropper::prop, PROP_FLOAT, DepthDropper::ptr, REGION_DRAW_POST_PIXEL, RGN_TYPE_WINDOW, RNA_CameraDOFSettings, RNA_pointer_create(), RNA_property_editable(), RNA_property_float_get(), RNA_property_type(), RNA_struct_find_property(), RV3D_CAMOB, SPACE_VIEW3D, UI_but_flag_is_set(), UI_BUT_UNDO, and UI_context_active_but_prop_get().
Referenced by depthdropper_exec(), and depthdropper_invoke().
|
static |
Definition at line 308 of file interface_eyedropper_depth.c.
References C, CTX_wm_region(), CTX_wm_window(), depthdropper_init(), OPERATOR_CANCELLED, OPERATOR_RUNNING_MODAL, UI_context_active_but_clear(), WM_CURSOR_EYEDROPPER, WM_cursor_modal_set(), and WM_event_add_modal_handler().
Referenced by UI_OT_eyedropper_depth().
|
static |
Definition at line 261 of file interface_eyedropper_depth.c.
References DepthDropper::accum_depth, DepthDropper::accum_start, DepthDropper::accum_tot, C, wmOperator::customdata, depthdropper_cancel(), depthdropper_depth_sample(), depthdropper_depth_sample_accum(), depthdropper_depth_set_accum(), depthdropper_exit(), EVT_MODAL_MAP, EYE_MODAL_CANCEL, EYE_MODAL_SAMPLE_BEGIN, EYE_MODAL_SAMPLE_CONFIRM, EYE_MODAL_SAMPLE_RESET, if(), DepthDropper::is_undo, MOUSEMOVE, OPERATOR_CANCELLED, OPERATOR_FINISHED, OPERATOR_RUNNING_MODAL, wmEvent::type, wmEvent::val, wmEvent::x, and wmEvent::y.
Referenced by UI_OT_eyedropper_depth().
|
static |
Definition at line 338 of file interface_eyedropper_depth.c.
References C, View3D::camera, CTX_wm_region_view3d(), CTX_wm_view3d(), CTX_wm_window(), Object::data, ID_IS_LINKED, NULL, RegionView3D::persp, PROP_FLOAT, PROP_UNIT_LENGTH, ptr, RNA_property_array_check(), RNA_property_subtype(), RNA_property_type(), RV3D_CAMOB, uiBut::type, UI_BTYPE_NUM, and UI_context_active_but_prop_get().
Referenced by UI_OT_eyedropper_depth().
| void UI_OT_eyedropper_depth | ( | wmOperatorType * | ot | ) |
Definition at line 368 of file interface_eyedropper_depth.c.
References wmOperatorType::cancel, depthdropper_cancel(), depthdropper_exec(), depthdropper_invoke(), depthdropper_modal(), depthdropper_poll(), wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::modal, wmOperatorType::name, OPTYPE_BLOCKING, OPTYPE_INTERNAL, OPTYPE_UNDO, ot, and wmOperatorType::poll.
Referenced by ED_operatortypes_ui().