Struct pxtnUnit

Source
#[repr(C)]
pub struct pxtnUnit {
Show 18 fields pub _bOperated: bool, pub _bPlayed: bool, pub _name_buf: [c_char; 17], pub _name_size: i32, pub _key_now: i32, pub _key_start: i32, pub _key_margin: i32, pub _portament_sample_pos: i32, pub _portament_sample_num: i32, pub _pan_vols: [i32; 2], pub _pan_times: [i32; 2], pub _pan_time_bufs: [[i32; 64]; 2], pub _v_VOLUME: i32, pub _v_VELOCITY: i32, pub _v_GROUPNO: i32, pub _v_TUNING: f32, pub _p_woice: *const pxtnWoice, pub _vts: [pxtnVOICETONE; 2],
}

Fields§

§_bOperated: bool§_bPlayed: bool§_name_buf: [c_char; 17]§_name_size: i32§_key_now: i32§_key_start: i32§_key_margin: i32§_portament_sample_pos: i32§_portament_sample_num: i32§_pan_vols: [i32; 2]§_pan_times: [i32; 2]§_pan_time_bufs: [[i32; 64]; 2]§_v_VOLUME: i32§_v_VELOCITY: i32§_v_GROUPNO: i32§_v_TUNING: f32§_p_woice: *const pxtnWoice§_vts: [pxtnVOICETONE; 2]

Implementations§

Source§

impl pxtnUnit

Source

pub unsafe fn Tone_Init(&mut self)

Source

pub unsafe fn Tone_Clear(&mut self)

Source

pub unsafe fn Tone_Reset_and_2prm( &mut self, voice_idx: i32, env_rls_clock: i32, offset_freq: f32, )

Source

pub unsafe fn Tone_Envelope(&mut self)

Source

pub unsafe fn Tone_KeyOn(&mut self)

Source

pub unsafe fn Tone_ZeroLives(&mut self)

Source

pub unsafe fn Tone_Key(&mut self, key: i32)

Source

pub unsafe fn Tone_Pan_Volume(&mut self, ch: i32, pan: i32)

Source

pub unsafe fn Tone_Pan_Time(&mut self, ch: i32, pan: i32, sps: i32)

Source

pub unsafe fn Tone_Velocity(&mut self, val: i32)

Source

pub unsafe fn Tone_Volume(&mut self, val: i32)

Source

pub unsafe fn Tone_Portament(&mut self, val: i32)

Source

pub unsafe fn Tone_GroupNo(&mut self, val: i32)

Source

pub unsafe fn Tone_Tuning(&mut self, val: f32)

Source

pub unsafe fn Tone_Sample( &mut self, b_mute_by_unit: bool, ch_num: i32, time_pan_index: i32, smooth_smp: i32, )

Source

pub unsafe fn Tone_Supple( &self, group_smps: *mut i32, ch_num: i32, time_pan_index: i32, )

Source

pub unsafe fn Tone_Increment_Key(&mut self) -> i32

Source

pub unsafe fn Tone_Increment_Sample(&mut self, freq: f32)

Source

pub unsafe fn set_woice(&mut self, p_woice: *const pxtnWoice) -> bool

Source

pub unsafe fn get_woice(&self) -> *const pxtnWoice

Source

pub unsafe fn set_name_buf( &mut self, name_buf: *const c_char, buf_size: i32, ) -> bool

Source

pub unsafe fn get_name_buf(&self, p_buf_size: *mut i32) -> *const c_char

Source

pub unsafe fn is_name_buf(&self) -> bool

Source

pub unsafe fn get_tone(&mut self, voice_idx: i32) -> *mut pxtnVOICETONE

Source

pub unsafe fn set_operated(&mut self, b: bool)

Source

pub unsafe fn set_played(&mut self, b: bool)

Source

pub unsafe fn get_operated(&self) -> bool

Source

pub unsafe fn get_played(&self) -> bool

Source

pub unsafe fn Read_v3x( &mut self, p_doc: *mut pxtnDescriptor, p_group: *mut i32, ) -> pxtnERR

Source

pub unsafe fn Read_v1x( &mut self, p_doc: *mut pxtnDescriptor, p_group: *mut i32, ) -> bool

Source

pub unsafe fn new() -> Self

Source

pub unsafe fn destruct(&mut self)

Trait Implementations§

Source§

impl Debug for pxtnUnit

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.