Struct transform_gizmo::config::GizmoConfig
source · pub struct GizmoConfig {
pub view_matrix: RowMatrix4<f64>,
pub projection_matrix: RowMatrix4<f64>,
pub viewport: Rect,
pub modes: EnumSet<GizmoMode>,
pub orientation: GizmoOrientation,
pub snapping: bool,
pub snap_angle: f32,
pub snap_distance: f32,
pub snap_scale: f32,
pub visuals: GizmoVisuals,
pub pixels_per_point: f32,
}
Expand description
Configuration of a [Gizmo
].
Defines how the gizmo is drawn to the screen and how it can be interacted with.
Fields§
§view_matrix: RowMatrix4<f64>
View matrix for the gizmo, aligning it with the camera’s viewpoint.
projection_matrix: RowMatrix4<f64>
Projection matrix for the gizmo, determining how it is projected onto the screen.
viewport: Rect
Screen area where the gizmo is displayed.
modes: EnumSet<GizmoMode>
The gizmo’s operation modes.
orientation: GizmoOrientation
Determines the gizmo’s orientation relative to global or local axes.
snapping: bool
Toggles snapping to predefined increments during transformations for precision.
snap_angle: f32
Angle increment for snapping rotations, in radians.
snap_distance: f32
Distance increment for snapping translations.
snap_scale: f32
Scale increment for snapping scalings.
visuals: GizmoVisuals
Visual settings for the gizmo, affecting appearance and visibility.
pixels_per_point: f32
Ratio of window’s physical size to logical size.
Trait Implementations§
source§impl Clone for GizmoConfig
impl Clone for GizmoConfig
source§fn clone(&self) -> GizmoConfig
fn clone(&self) -> GizmoConfig
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for GizmoConfig
impl Debug for GizmoConfig
source§impl Default for GizmoConfig
impl Default for GizmoConfig
impl Copy for GizmoConfig
Auto Trait Implementations§
impl Freeze for GizmoConfig
impl RefUnwindSafe for GizmoConfig
impl Send for GizmoConfig
impl Sync for GizmoConfig
impl Unpin for GizmoConfig
impl UnwindSafe for GizmoConfig
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more