FrameRange
struct FrameRangeimport FrameRange from Wax::Recording;A range of absolute recording frames in the Wax::Recording namespace. Keeps recording
selections distinct from application counters.
import Frame from Wax::Recording;
import FrameRange from Wax::Recording;
api fn Main() : int32 {
var range = FrameRange.Through(new Frame(3), new Frame(5));
return range.count as int32;
}
Members
fromfield
public readonly Frame fromThe inclusive first frame.
tofield
public readonly Frame toThe exclusive end frame.
constructorconstructor
public constructor (Frame from, Frame to)Creates [from, to). An end before the start panics; equal endpoints form an empty range.
countgetter
public get count() : int64The number of frames in the half-open range.
isEmptygetter
public get isEmpty() : boolTests whether the endpoints are equal.
Containsmethod
public fn Contains(Frame frame) : boolTests from <= frame < to.
Throughmethod
public static fn Through(Frame from, Frame toInclusive) : FrameRangeCreates a range including both supplied endpoints. Reversed bounds or an inclusive end at the maximum frame panic.
StartingAtmethod
public static fn StartingAt(Frame from, int64 count) : FrameRangeCreates count frames beginning at from. Negative count or end overflow panics; zero count is allowed.
EndingAtmethod
public static fn EndingAt(Frame to, int64 count) : FrameRangeCreates count frames before the exclusive end to. Negative count or a start before frame zero panics; zero count is allowed.
EndingThroughmethod
public static fn EndingThrough(Frame toInclusive, int64 count) : FrameRangeCreates a positive number of frames ending at the inclusive endpoint. Nonpositive count, a start before zero, or end overflow panics.
UpToEndingThroughmethod
public static fn UpToEndingThrough(Frame toInclusive, int64 maxCount) : FrameRangeCreates up to maxCount frames ending at the inclusive endpoint, shortening at frame zero. Nonpositive maxCount or end overflow panics.
GetHashCodemethod
public fn GetHashCode() : uint32Hashes both range endpoints.
Equalsmethod
public fn Equals(FrameRange other) : boolTests both endpoints for exact equality.
ToStringmethod
public fn ToString() : stringProvided by the compiler.
ToStringBuffermethod
public fn ToStringBuffer(StringBuilder builder) : int32Provided by the compiler.