pub struct Chunk {
pub in_start: usize,
pub in_end: usize,
pub out_start: usize,
}Expand description
One unit of independently scoreable work within a piece.
Chunks can be scored with fresh state and their results concatenated, because
curvature is a distance between local averages: a chunk that starts partway into a
piece has the wrong starting coordinate and the wrong accumulated twist, but the first
is a translation of the traced path and the second a rotation of it, and neither
changes the distances the scores are made of. Each chunk therefore reads lead_in
bases of context beyond its output range at each end.
Fields§
§in_start: usizeOffset into the piece where this chunk starts reading.
in_end: usizeOffset into the piece where this chunk stops reading, exclusive.
out_start: usizeIndex into the piece’s scores of this chunk’s first score.
Trait Implementations§
impl Copy for Chunk
impl Eq for Chunk
impl StructuralPartialEq for Chunk
Auto Trait Implementations§
impl Freeze for Chunk
impl RefUnwindSafe for Chunk
impl Send for Chunk
impl Sync for Chunk
impl Unpin for Chunk
impl UnsafeUnpin for Chunk
impl UnwindSafe for Chunk
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more