pub struct MorphOf<const BITS: u32> { /* private fields */ }Expand description
The value a performance control morphs its parent parameter to.
Every morphable parameter has three of these beside it — _wheel, _aftertouch and
_ctrl_pedal — and together they are half of every Stage body’s field count. They are
not controls of their own: an interface shows them on the parent’s knob, as a
second handle, which is what ControlKind::Morph tells it to do.
BITS is the slot’s width, which tracks the parent’s: eight beside a 0..=127 knob,
five beside a drawbar, three beside a switch.
⚠️ The encoding is not established. Stage 4 specimens use the whole byte,
with 127 predominant. It may be a signed delta biased by 127 or a destination at
twice the parent’s resolution. Inferred from specimens; not confirmed on hardware.
Self::is_neutral is the only interpretation exposed.
The experiment that settles it: assign one morph at a known depth, store, and diff the slot against its parent’s value.
Implementations§
Trait Implementations§
impl<const BITS: u32> Copy for MorphOf<BITS>
Source§impl<const BITS: u32> Debug for MorphOf<BITS>
The stored value — the encoding is unconfirmed, so this prints what is there.
impl<const BITS: u32> Debug for MorphOf<BITS>
The stored value — the encoding is unconfirmed, so this prints what is there.
impl<const BITS: u32> Eq for MorphOf<BITS>
Source§impl<const BITS: u32> Ord for MorphOf<BITS>
impl<const BITS: u32> Ord for MorphOf<BITS>
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl<const BITS: u32> Packed for MorphOf<BITS>
impl<const BITS: u32> Packed for MorphOf<BITS>
Source§const CONTROL: ControlKind
const CONTROL: ControlKind
The parent is the declaration site’s business, not the type’s — every morph slot
shares this type and each names a different parameter — so #[bitbody] fills it
in from the field’s name.
Source§const MAX_BITS: u32
const MAX_BITS: u32
Source§const DECODE_BITS: u32 = u8::BITS
const DECODE_BITS: u32 = u8::BITS
Source§type Error = !
type Error = !
Infallible when every pattern is.Source§impl<const BITS: u32> PartialOrd for MorphOf<BITS>
impl<const BITS: u32> PartialOrd for MorphOf<BITS>
impl<const BITS: u32> StructuralPartialEq for MorphOf<BITS>
Auto Trait Implementations§
impl<const BITS: u32> Freeze for MorphOf<BITS>
impl<const BITS: u32> RefUnwindSafe for MorphOf<BITS>
impl<const BITS: u32> Send for MorphOf<BITS>
impl<const BITS: u32> Sync for MorphOf<BITS>
impl<const BITS: u32> Unpin for MorphOf<BITS>
impl<const BITS: u32> UnsafeUnpin for MorphOf<BITS>
impl<const BITS: u32> UnwindSafe for MorphOf<BITS>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.