147 cagzgroup->
dop_dist,
"offset", &camera_dof_ptr,
"focus_distance", -1);
188 const float ob_scale_inv[3] = {
193 const float ob_scale_uniform_inv = (ob_scale_inv[0] + ob_scale_inv[1] + ob_scale_inv[2]) /
195 scale_matrix = (ca->
drawsize * 0.5f) / ob_scale_uniform_inv;
207 const char *propname = is_ortho ?
"ortho_scale" :
"lens";
215 float step, precision;
225 (scale_matrix * range /
227 (0.5f * sensor_size)));
256 &rna_CameraDOFSettings_focus_distance,
257 &rna_Camera_display_size,
258 &rna_Camera_ortho_scale,
259 &rna_Camera_sensor_fit,
260 &rna_Camera_sensor_width,
261 &rna_Camera_sensor_height,
279 mbus, RenderSettings, resolution_x, &msg_sub_value_gz_tag_refresh);
281 mbus, RenderSettings, resolution_y, &msg_sub_value_gz_tag_refresh);
283 mbus, RenderSettings, pixel_aspect_x, &msg_sub_value_gz_tag_refresh);
285 mbus, RenderSettings, pixel_aspect_y, &msg_sub_value_gz_tag_refresh);
291 gzgt->
name =
"Camera Widgets";
292 gzgt->
idname =
"VIEW3D_GGT_camera";
326 float(*matrix)[4] = value_p;
342 const float(*matrix)[4] = value_p;
435 .xmax = region->
winx,
436 .ymax = region->
winy,
481 .range_get_fn =
NULL,
482 .user_data = viewgroup,
489 gzgt->
name =
"Camera View Widgets";
490 gzgt->
idname =
"VIEW3D_GGT_camera_view";
typedef float(TangentPoint)[2]
Camera data-block and utility functions.
float BKE_camera_sensor_size(int sensor_fit, float sensor_x, float sensor_y)
int BKE_camera_sensor_fit(int sensor_fit, float sizex, float sizey)
struct Scene * CTX_data_scene(const bContext *C)
struct ViewLayer * CTX_data_view_layer(const bContext *C)
struct View3D * CTX_wm_view3d(const bContext *C)
struct Depsgraph * CTX_data_expect_evaluated_depsgraph(const bContext *C)
struct ARegion * CTX_wm_region(const bContext *C)
struct Main * CTX_data_main(const bContext *C)
bool BKE_id_is_editable(const struct Main *bmain, const struct ID *id)
void unit_m4(float m[4][4])
MINLINE void mul_v3_fl(float r[3], float f)
MINLINE void negate_v3_v3(float r[3], const float a[3])
MINLINE float len_v3(const float a[3]) ATTR_WARN_UNUSED_RESULT
BLI_INLINE float BLI_rctf_cent_y(const struct rctf *rct)
bool BLI_rctf_isect(const struct rctf *src1, const struct rctf *src2, struct rctf *dest)
BLI_INLINE float BLI_rctf_cent_x(const struct rctf *rct)
void BLI_rctf_recenter(struct rctf *rect, float x, float y)
BLI_INLINE float BLI_rctf_size_x(const struct rctf *rct)
void BLI_rctf_resize(struct rctf *rect, float x, float y)
BLI_INLINE float BLI_rctf_size_y(const struct rctf *rct)
struct Depsgraph Depsgraph
void DEG_id_tag_update(struct ID *id, int flag)
@ ID_RECALC_COPY_ON_WRITE
Object is a sort of wrapper for general info.
#define BASACT(_view_layer)
#define OBACT(_view_layer)
@ V3D_GIZMO_SHOW_CAMERA_DOF_DIST
@ V3D_GIZMO_SHOW_CAMERA_LENS
#define V3D_RENDER_BORDER
@ ED_GIZMO_CAGE2D_STYLE_BOX
@ ED_GIZMO_ARROW_XFORM_FLAG_CONSTRAINED
@ ED_GIZMO_CAGE2D_XFORM_FLAG_TRANSLATE
@ ED_GIZMO_CAGE2D_XFORM_FLAG_SCALE
@ ED_GIZMO_ARROW_STYLE_CROSS
@ ED_GIZMO_ARROW_STYLE_CONE
void ED_view3d_calc_camera_border(const struct Scene *scene, struct Depsgraph *depsgraph, const struct ARegion *region, const struct View3D *v3d, const struct RegionView3D *rv3d, struct rctf *r_viewborder, bool no_shift)
Read Guarded memory(de)allocation.
in reality light always falls off quadratically Particle Retrieve the data of the particle that spawned the object for example to give variation to multiple instances of an object Point Retrieve information about points in a point cloud Retrieve the edges of an object as it appears to Cycles topology will always appear triangulated Convert a blackbody temperature to an RGB value Normal Generate a perturbed normal from an RGB normal map image Typically used for faking highly detailed surfaces Generate an OSL shader from a file or text data block Image Sample an image file as a texture Sky Generate a procedural sky texture Noise Generate fractal Perlin noise Wave Generate procedural bands or rings with noise Voronoi Generate Worley noise based on the distance to random points Typically used to generate textures such as or biological cells Brick Generate a procedural texture producing bricks Texture Retrieve multiple types of texture coordinates nTypically used as inputs for texture nodes Vector Convert a or normal between camera
void UI_GetThemeColor3fv(int colorid, float col[3])
@ WM_GIZMOGROUPTYPE_SCALE
@ WM_GIZMOGROUPTYPE_DEPTH_3D
@ WM_GIZMOGROUPTYPE_PERSISTENT
void ED_gizmo_arrow3d_set_range_fac(wmGizmo *gz, const float range_fac)
const Depsgraph * depsgraph
IconTextureDrawCall border
ccl_gpu_kernel_postfix ccl_global float int int int int float bool int offset
void *(* MEM_callocN)(size_t len, const char *str)
void *(* MEM_mallocN)(size_t len, const char *str)
void RNA_pointer_create(ID *id, StructRNA *type, void *data, PointerRNA *r_ptr)
void RNA_id_pointer_create(ID *id, PointerRNA *r_ptr)
void RNA_property_float_ui_range(PointerRNA *ptr, PropertyRNA *prop, float *softmin, float *softmax, float *step, float *precision)
PropertyRNA * RNA_struct_find_property(PointerRNA *ptr, const char *identifier)
void RNA_enum_set(PointerRNA *ptr, const char *name, int value)
void RNA_float_set_array(PointerRNA *ptr, const char *name, const float *values)
struct CameraDOFSettings dof
wmGizmoGroupFnSetupKeymap setup_keymap
wmGizmoGroupFnMsgBusSubscribe message_subscribe
wmGizmoGroupFnRefresh refresh
eWM_GizmoFlagGroupTypeFlag flag
wmGizmoGroupFnDrawPrepare draw_prepare
struct wmGizmoMap * parent_gzmap
const struct wmGizmoPropertyType * type
struct wmGizmoProperty::@1185 custom_func
const struct wmGizmoType * type
static void WIDGETGROUP_camera_setup(const bContext *C, wmGizmoGroup *gzgroup)
static void WIDGETGROUP_camera_message_subscribe(const bContext *C, wmGizmoGroup *gzgroup, struct wmMsgBus *mbus)
static void WIDGETGROUP_camera_view_setup(const bContext *UNUSED(C), wmGizmoGroup *gzgroup)
void VIEW3D_GGT_camera(wmGizmoGroupType *gzgt)
static bool WIDGETGROUP_camera_view_poll(const bContext *C, wmGizmoGroupType *UNUSED(gzgt))
static void gizmo_render_border_prop_matrix_get(const wmGizmo *UNUSED(gz), wmGizmoProperty *gz_prop, void *value_p)
static void WIDGETGROUP_camera_view_refresh(const bContext *C, wmGizmoGroup *gzgroup)
static void WIDGETGROUP_camera_view_draw_prepare(const bContext *C, wmGizmoGroup *gzgroup)
void VIEW3D_GGT_camera_view(wmGizmoGroupType *gzgt)
static void gizmo_render_border_prop_matrix_set(const wmGizmo *UNUSED(gz), wmGizmoProperty *gz_prop, const void *value_p)
static bool WIDGETGROUP_camera_poll(const bContext *C, wmGizmoGroupType *UNUSED(gzgt))
static void WIDGETGROUP_camera_refresh(const bContext *C, wmGizmoGroup *gzgroup)
void WM_gizmo_set_matrix_offset_location(wmGizmo *gz, const float offset[3])
void WM_gizmo_set_matrix_rotation_from_yz_axis(wmGizmo *gz, const float y_axis[3], const float z_axis[3])
wmGizmo * WM_gizmo_new_ptr(const wmGizmoType *gzt, wmGizmoGroup *gzgroup, PointerRNA *properties)
void WM_gizmo_set_scale(wmGizmo *gz, const float scale)
void WM_gizmo_set_matrix_location(wmGizmo *gz, const float origin[3])
void WM_gizmo_set_flag(wmGizmo *gz, const int flag, const bool enable)
wmGizmo * WM_gizmo_new(const char *idname, wmGizmoGroup *gzgroup, PointerRNA *properties)
wmKeyMap * WM_gizmogroup_setup_keymap_generic_maybe_drag(const wmGizmoGroupType *UNUSED(gzgt), wmKeyConfig *kc)
void WM_gizmo_do_msg_notify_tag_refresh(bContext *UNUSED(C), wmMsgSubscribeKey *UNUSED(msg_key), wmMsgSubscribeValue *msg_val)
void WM_gizmo_target_property_clear_rna_ptr(wmGizmo *gz, const wmGizmoPropertyType *gz_prop_type)
void WM_gizmo_target_property_def_rna(wmGizmo *gz, const char *idname, PointerRNA *ptr, const char *propname, int index)
void WM_gizmo_target_property_def_rna_ptr(wmGizmo *gz, const wmGizmoPropertyType *gz_prop_type, PointerRNA *ptr, PropertyRNA *prop, int index)
void WM_gizmo_target_property_def_func(wmGizmo *gz, const char *idname, const wmGizmoPropertyFnParams *params)
const wmGizmoPropertyType * WM_gizmotype_target_property_find(const wmGizmoType *gzt, const char *idname)
const wmGizmoType * WM_gizmotype_find(const char *idname, bool quiet)
#define WM_msg_subscribe_rna_anon_prop(mbus, type_, prop_, value)
void WM_msg_subscribe_rna(struct wmMsgBus *mbus, PointerRNA *ptr, const PropertyRNA *prop, const wmMsgSubscribeValue *msg_val_params, const char *id_repr)