Struct PageTurnSnapshot
- Namespace
- PageCurl.Core
- Assembly
- PageCurl.Core.dll
A read-only snapshot of the page turn controller.
public readonly struct PageTurnSnapshot : IEquatable<PageTurnSnapshot>
- Implements
- Inherited Members
Constructors
PageTurnSnapshot(PageTurnState, PageTurnDirection, Vector2, Vector2, float, float)
A read-only snapshot of the page turn controller.
public PageTurnSnapshot(PageTurnState State, PageTurnDirection Direction, Vector2 DragStartPosition, Vector2 PointerPosition, float Progress, float TargetProgress)
Parameters
StatePageTurnStateDirectionPageTurnDirectionDragStartPositionVector2PointerPositionVector2ProgressfloatTargetProgressfloat
Properties
Direction
public PageTurnDirection Direction { get; init; }
Property Value
DragStartPosition
public Vector2 DragStartPosition { get; init; }
Property Value
FreeEdge
The physical edge or corner the user is pulling from.
public PageEdge FreeEdge { get; init; }
Property Value
HingeEdge
The physical edge currently acting as the stationary hinge.
public PageEdge HingeEdge { get; init; }
Property Value
LockedAnchor
The edge or corner that remains stationary during the turn.
public PageAnchor LockedAnchor { get; init; }
Property Value
PointerPosition
public Vector2 PointerPosition { get; init; }
Property Value
Progress
public float Progress { get; init; }
Property Value
State
public PageTurnState State { get; init; }
Property Value
TargetProgress
public float TargetProgress { get; init; }
Property Value
Methods
Deconstruct(out PageTurnState, out PageTurnDirection, out Vector2, out Vector2, out float, out float)
public void Deconstruct(out PageTurnState State, out PageTurnDirection Direction, out Vector2 DragStartPosition, out Vector2 PointerPosition, out float Progress, out float TargetProgress)
Parameters
StatePageTurnStateDirectionPageTurnDirectionDragStartPositionVector2PointerPositionVector2ProgressfloatTargetProgressfloat
Equals(PageTurnSnapshot)
public bool Equals(PageTurnSnapshot other)
Parameters
otherPageTurnSnapshot
Returns
Equals(object)
public override bool Equals(object obj)
Parameters
objobject
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(PageTurnSnapshot, PageTurnSnapshot)
public static bool operator ==(PageTurnSnapshot left, PageTurnSnapshot right)
Parameters
leftPageTurnSnapshotrightPageTurnSnapshot
Returns
operator !=(PageTurnSnapshot, PageTurnSnapshot)
public static bool operator !=(PageTurnSnapshot left, PageTurnSnapshot right)
Parameters
leftPageTurnSnapshotrightPageTurnSnapshot