Blender
V3.3
|
#include "BLI_blenlib.h"
#include "BLI_math.h"
#include "BLI_utildefines.h"
#include "BKE_camera.h"
#include "BKE_context.h"
#include "BKE_layer.h"
#include "BKE_lib_id.h"
#include "DNA_camera_types.h"
#include "DNA_object_types.h"
#include "ED_armature.h"
#include "ED_gizmo_library.h"
#include "ED_screen.h"
#include "UI_resources.h"
#include "MEM_guardedalloc.h"
#include "RNA_access.h"
#include "WM_api.h"
#include "WM_message.h"
#include "WM_types.h"
#include "DEG_depsgraph.h"
#include "view3d_intern.h"
Go to the source code of this file.
Classes | |
struct | CameraWidgetGroup |
struct | CameraViewWidgetGroup |
|
static |
Definition at line 322 of file view3d_gizmo_camera.c.
References wmGizmoPropertyType::array_length, BLI_assert, BLI_rctf_cent_x(), BLI_rctf_cent_y(), BLI_rctf_size_x(), BLI_rctf_size_y(), border, wmGizmoProperty::custom_func, CameraViewWidgetGroup::edit_border, float(), CameraViewWidgetGroup::state, wmGizmoProperty::type, unit_m4(), and wmGizmoProperty::user_data.
Referenced by WIDGETGROUP_camera_view_refresh().
|
static |
Definition at line 338 of file view3d_gizmo_camera.c.
References wmGizmoPropertyType::array_length, BLI_assert, BLI_rctf_isect(), BLI_rctf_recenter(), BLI_rctf_resize(), border, wmGizmoProperty::custom_func, DEG_id_tag_update(), CameraViewWidgetGroup::edit_border, float(), Scene::id, ID_RECALC_COPY_ON_WRITE, CameraViewWidgetGroup::is_camera, len_v3(), CameraViewWidgetGroup::scene, CameraViewWidgetGroup::state, wmGizmoProperty::type, and wmGizmoProperty::user_data.
Referenced by WIDGETGROUP_camera_view_refresh().
void VIEW3D_GGT_camera | ( | wmGizmoGroupType * | gzgt | ) |
Definition at line 289 of file view3d_gizmo_camera.c.
References wmGizmoGroupType::flag, wmGizmoGroupType::idname, wmGizmoGroupType::message_subscribe, wmGizmoGroupType::name, wmGizmoGroupType::poll, wmGizmoGroupType::refresh, wmGizmoGroupType::setup, wmGizmoGroupType::setup_keymap, WIDGETGROUP_camera_message_subscribe(), WIDGETGROUP_camera_poll(), WIDGETGROUP_camera_refresh(), WIDGETGROUP_camera_setup(), WM_gizmogroup_setup_keymap_generic_maybe_drag(), WM_GIZMOGROUPTYPE_3D, WM_GIZMOGROUPTYPE_DEPTH_3D, and WM_GIZMOGROUPTYPE_PERSISTENT.
Referenced by view3d_widgets().
void VIEW3D_GGT_camera_view | ( | wmGizmoGroupType * | gzgt | ) |
Definition at line 487 of file view3d_gizmo_camera.c.
References wmGizmoGroupType::draw_prepare, wmGizmoGroupType::flag, wmGizmoGroupType::idname, wmGizmoGroupType::name, wmGizmoGroupType::poll, wmGizmoGroupType::refresh, wmGizmoGroupType::setup, WIDGETGROUP_camera_view_draw_prepare(), WIDGETGROUP_camera_view_poll(), WIDGETGROUP_camera_view_refresh(), WIDGETGROUP_camera_view_setup(), WM_GIZMOGROUPTYPE_PERSISTENT, and WM_GIZMOGROUPTYPE_SCALE.
Referenced by view3d_widgets().
|
static |
Definition at line 239 of file view3d_gizmo_camera.c.
References ARRAY_SIZE, C, CTX_data_view_layer(), CTX_wm_region(), Object::data, Camera::id, OBACT, wmMsgSubscribeValue::owner, wmGizmoGroup::parent_gzmap, RNA_id_pointer_create(), WM_gizmo_do_msg_notify_tag_refresh(), WM_msg_subscribe_rna(), and WM_msg_subscribe_rna_anon_prop.
Referenced by VIEW3D_GGT_camera().
|
static |
Definition at line 47 of file view3d_gizmo_camera.c.
References BASACT, BASE_SELECTABLE, BKE_id_is_editable(), C, camera, CTX_data_main(), CTX_data_view_layer(), CTX_wm_view3d(), Object::data, View3D::gizmo_flag, View3D::gizmo_show_camera, OB_CAMERA, Base::object, Object::type, V3D_GIZMO_HIDE, V3D_GIZMO_HIDE_CONTEXT, V3D_GIZMO_SHOW_CAMERA_DOF_DIST, and V3D_GIZMO_SHOW_CAMERA_LENS.
Referenced by VIEW3D_GGT_camera().
|
static |
Definition at line 119 of file view3d_gizmo_camera.c.
References BKE_camera_sensor_fit(), BKE_camera_sensor_size(), C, CAM_ORTHO, CAM_SHOWLIMITS, CAMERA_SENSOR_FIT_HOR, CTX_data_scene(), CTX_data_view_layer(), CTX_wm_view3d(), wmGizmoGroup::customdata, Object::data, Camera::dof, CameraWidgetGroup::dop_dist, Camera::drawsize, ED_gizmo_arrow3d_set_range_fac(), Camera::flag, float(), CameraWidgetGroup::focal_len, View3D::gizmo_show_camera, Camera::id, len_v3(), wmGizmo::matrix_basis, max, min, mul_v3_fl(), negate_v3_v3(), OBACT, Object::obmat, offset, CameraWidgetGroup::ortho_scale, Camera::ortho_scale, wmGizmo::ptr, Scene::r, RNA_float_set_array(), RNA_pointer_create(), RNA_property_float_ui_range(), RNA_struct_find_property(), Object::scale, scene, Camera::sensor_fit, Camera::sensor_x, Camera::sensor_y, Camera::shiftx, Camera::shifty, Camera::type, wmGizmo::type, unit_m4(), V3D_GIZMO_SHOW_CAMERA_DOF_DIST, V3D_GIZMO_SHOW_CAMERA_LENS, WM_GIZMO_HIDDEN, WM_gizmo_set_flag(), WM_gizmo_set_matrix_location(), WM_gizmo_set_matrix_offset_location(), WM_gizmo_set_matrix_rotation_from_yz_axis(), WM_gizmo_set_scale(), WM_gizmo_target_property_clear_rna_ptr(), WM_gizmo_target_property_def_rna(), WM_gizmo_target_property_def_rna_ptr(), WM_gizmotype_target_property_find(), RenderData::xasp, RenderData::xsch, RenderData::yasp, and RenderData::ysch.
Referenced by VIEW3D_GGT_camera().
|
static |
Definition at line 73 of file view3d_gizmo_camera.c.
References C, wmGizmo::color, wmGizmo::color_hi, CTX_data_view_layer(), wmGizmoGroup::customdata, CameraWidgetGroup::dop_dist, ED_GIZMO_ARROW_STYLE_CONE, ED_GIZMO_ARROW_STYLE_CROSS, ED_GIZMO_ARROW_XFORM_FLAG_CONSTRAINED, wmGizmo::flag, CameraWidgetGroup::focal_len, MEM_callocN, negate_v3_v3(), NULL, OBACT, Object::obmat, CameraWidgetGroup::ortho_scale, wmGizmo::ptr, RNA_enum_set(), TH_GIZMO_A, TH_GIZMO_HI, TH_GIZMO_PRIMARY, UI_GetThemeColor3fv(), WM_GIZMO_DRAW_HOVER, WM_GIZMO_DRAW_NO_SCALE, WM_gizmo_new_ptr(), WM_gizmo_set_flag(), and WM_gizmotype_find().
Referenced by VIEW3D_GGT_camera().
|
static |
Definition at line 417 of file view3d_gizmo_camera.c.
References BLI_rctf_size_x(), BLI_rctf_size_y(), CameraViewWidgetGroup::border, C, CTX_data_expect_evaluated_depsgraph(), CTX_data_scene(), CTX_wm_region(), CTX_wm_view3d(), wmGizmoGroup::customdata, depsgraph, ED_view3d_calc_camera_border(), wmGizmo::matrix_space, mul_v3_fl(), RegionView3D::persp, ARegion::regiondata, RV3D_CAMOB, scene, CameraViewWidgetGroup::state, unit_m4(), CameraViewWidgetGroup::view_border, ARegion::winx, ARegion::winy, rctf::xmin, and rctf::ymin.
Referenced by VIEW3D_GGT_camera_view().
|
static |
Definition at line 364 of file view3d_gizmo_camera.c.
References BKE_id_is_editable(), C, Scene::camera, CTX_data_main(), CTX_data_scene(), CTX_data_view_layer(), CTX_wm_region(), CTX_wm_view3d(), View3D::flag2, View3D::gizmo_flag, Scene::id, RenderData::mode, OBACT, RegionView3D::persp, Scene::r, R_BORDER, ARegion::regiondata, RV3D_CAMOB, scene, V3D_GIZMO_HIDE, V3D_GIZMO_HIDE_CONTEXT, and V3D_RENDER_BORDER.
Referenced by VIEW3D_GGT_camera_view().
|
static |
Definition at line 448 of file view3d_gizmo_camera.c.
References CameraViewWidgetGroup::border, RenderData::border, C, CTX_data_scene(), CTX_wm_region(), CTX_wm_view3d(), wmGizmoGroup::customdata, ED_GIZMO_CAGE2D_XFORM_FLAG_SCALE, ED_GIZMO_CAGE2D_XFORM_FLAG_TRANSLATE, CameraViewWidgetGroup::edit_border, gizmo_render_border_prop_matrix_get(), gizmo_render_border_prop_matrix_set(), CameraViewWidgetGroup::is_camera, NULL, RegionView3D::persp, wmGizmo::ptr, Scene::r, ARegion::regiondata, View3D::render_border, RNA_enum_set(), RV3D_CAMOB, scene, CameraViewWidgetGroup::scene, CameraViewWidgetGroup::state, WM_GIZMO_HIDDEN, WM_gizmo_set_flag(), and WM_gizmo_target_property_def_func().
Referenced by VIEW3D_GGT_camera_view().
|
static |
Definition at line 399 of file view3d_gizmo_camera.c.
References CameraViewWidgetGroup::border, wmGizmoGroup::customdata, ED_GIZMO_CAGE2D_STYLE_BOX, ED_GIZMO_CAGE2D_XFORM_FLAG_SCALE, ED_GIZMO_CAGE2D_XFORM_FLAG_TRANSLATE, MEM_mallocN, NULL, wmGizmo::ptr, RNA_enum_set(), WM_gizmo_new(), and WM_gizmo_set_scale().
Referenced by VIEW3D_GGT_camera_view().