Blender V5.3
blender::TransformCoordsOrig Struct Reference

Public Member Functions

Median Utilities
void apply (const float4x4 &mat, float3 &co)

Public Attributes

Array< float3 > coords
float3 dims
float3 pivot
int coords_index = 0
bool is_stored = false

Detailed Description

Coordinates of the selected elements when a dimensions drag began.

Scaling in place would seem simpler, however a dimension set to zero loses the size with no way to scale back up. Only allocated once a dimension is edited.

Definition at line 150 of file view3d_buttons.cc.

Member Function Documentation

◆ apply()

void blender::TransformCoordsOrig::apply ( const float4x4 & mat,
float3 & co )

Scale co from its original, storing it on the first update and reading it back on later ones.

Callers must visit coordinates in the same order every update.

Definition at line 389 of file view3d_buttons.cc.

References blender::dims_apply_restore(), blender::dims_apply_store(), and is_stored.

Referenced by blender::v3d_editvertex_buts().

Member Data Documentation

◆ coords

Array<float3> blender::TransformCoordsOrig::coords

Selected coordinates, in apply-loop visit order.

Definition at line 154 of file view3d_buttons.cc.

Referenced by blender::dims_apply_restore(), blender::dims_apply_store(), and blender::v3d_editvertex_buts().

◆ coords_index

int blender::TransformCoordsOrig::coords_index = 0

Advanced by apply, reset at the start of every update.

Definition at line 162 of file view3d_buttons.cc.

Referenced by blender::dims_apply_restore(), blender::dims_apply_store(), and blender::v3d_editvertex_buts().

◆ dims

float3 blender::TransformCoordsOrig::dims

Size & pivot when the drag began, every scale is relative to these.

Definition at line 156 of file view3d_buttons.cc.

Referenced by blender::v3d_editvertex_buts().

◆ is_stored

bool blender::TransformCoordsOrig::is_stored = false

False until the first update has filled coords.

Definition at line 164 of file view3d_buttons.cc.

Referenced by apply(), and blender::v3d_editvertex_buts().

◆ pivot

float3 blender::TransformCoordsOrig::pivot

Definition at line 157 of file view3d_buttons.cc.

Referenced by blender::v3d_editvertex_buts().


The documentation for this struct was generated from the following file: