ManipulationTransformHandler
AUTO-GENERATED FILE – DO NOT EDIT MANUALLY
This page documents the supported public API surface only. Private, internal, benchmark, test, and implementation-detail types are intentionally omitted.
Declaration
Summary
Core transform operations for manipulated objects (engine-agnostic). Handles rotation, flip, and other transform operations without engine dependencies.
Responsibilities:
- Apply rotation transformations
- Apply horizontal/vertical flips
- Preserve transform state
- Provide rotation utility functions
Metadata
Namespace: GridPlacement.Core.Services.Manipulation
Source File: cs/Core/Services/Manipulation/ManipulationTransformHandler.cs
Assembly: GridPlacement.Core
Type: class
Methods
ApplyRotation
Applies rotation to target transform.
Parameters
| Name | Description |
|---|---|
currentRotation | Current rotation in degrees |
degrees | Rotation amount in degrees (0-360) |
Returns
New rotation in degrees
ApplyFlipHorizontal
Applies horizontal flip (mirror across Y axis).
Parameters
| Name | Description |
|---|---|
currentScale | Current scale vector |
Returns
Scale magnitude normalized without encoding flip in scale X
ApplyFlipVertical
Applies vertical flip (mirror across X axis).
Parameters
| Name | Description |
|---|---|
currentScale | Current scale vector |
Returns
Scale magnitude normalized without encoding flip in scale Y
ApplyFlipHorizontal
Applies a horizontal flip by toggling explicit flip state while preserving scale magnitude.
Parameters
| Name | Description |
|---|---|
currentState | Current transform state |
Returns
Updated transform state with horizontal flip state toggled
ApplyFlipVertical
Applies a vertical flip by toggling explicit flip state while preserving scale magnitude.
Parameters
| Name | Description |
|---|---|
currentState | Current transform state |
Returns
Updated transform state with vertical flip state toggled
ApplyRotationRadians
Applies rotation in radians to target transform.
Parameters
| Name | Description |
|---|---|
currentRotation | Current rotation in radians |
radians | Rotation amount in radians |
Returns
New rotation in radians
SetRotation
Sets absolute rotation.
Parameters
| Name | Description |
|---|---|
degrees | Absolute rotation in degrees |
Returns
Rotation in degrees
SetRotationRadians
Sets absolute rotation in radians.
Parameters
| Name | Description |
|---|---|
radians | Absolute rotation in radians |
Returns
Rotation in radians
ResetRotation
Resets rotation to identity (0 degrees).
Returns
Identity rotation (0 degrees)
ResetScale
Resets scale to identity (1, 1).
Returns
Identity scale
IsFlippedHorizontal
Checks if the scale is flipped horizontally.
Parameters
| Name | Description |
|---|---|
scale | Scale vector to check |
Returns
Always false because flip state is no longer encoded in scale X
IsFlippedVertical
Checks if the scale is flipped vertically.
Parameters
| Name | Description |
|---|---|
scale | Scale vector to check |
Returns
Always false because flip state is no longer encoded in scale Y
NormalizeRotation
Normalizes rotation to 0-360 degree range.
Parameters
| Name | Description |
|---|---|
degrees | Rotation to normalize |
Returns
Normalized rotation in degrees
NormalizeRotationRadians
Normalizes rotation to 0-2π radian range.
Parameters
| Name | Description |
|---|---|
radians | Rotation to normalize |
Returns
Normalized rotation in radians
DegreesToRadians
Converts degrees to radians.
Parameters
| Name | Description |
|---|---|
degrees | Angle in degrees |
Returns
Angle in radians
RadiansToDegrees
Converts radians to degrees.
Parameters
| Name | Description |
|---|---|
radians | Angle in radians |
Returns
Angle in degrees
ApplySnappedRotation
Applies a rotation that snaps to the nearest increment.
Parameters
| Name | Description |
|---|---|
currentRotation | Current rotation in degrees |
degrees | Desired rotation in degrees |
increment | Snap increment in degrees |
Returns
Snapped rotation in degrees