Struct DspDescription

Source
pub struct DspDescription {
Show 14 fields pub name: String, pub version: u32, pub channels: i32, pub create: DspCreateCallback, pub release: DspReleaseCallback, pub reset: DspResetCallback, pub read: DspReadCallback, pub set_position: DspSetPositionCallback, pub num_parameters: i32, pub param_desc: DspParameterDesc, pub set_parameter: DspSetParamCallback, pub get_parameter: DspGetParamCallback, pub config_width: i32, pub config_height: i32, /* private fields */
}
Expand description

When creating a DSP unit, declare one of these and provide the relevant callbacks and name for FMOD to use when it creates and uses a DSP unit of this type.

Fields§

§name: String

[w] Name of the unit to be displayed in the network.

§version: u32

[w] Plugin writer’s version number.

§channels: i32

[w] Number of channels. Use 0 to process whatever number of channels is currently in the network. > 0 would be mostly used if the unit is a unit that only generates sound.

§create: DspCreateCallback

[w] Create callback. This is called when DSP unit is created. Can be null.

§release: DspReleaseCallback

[w] Release callback. This is called just before the unit is freed so the user can do any cleanup needed for the unit. Can be null.

§reset: DspResetCallback

[w] Reset callback. This is called by the user to reset any history buffers that may need resetting for a filter, when it is to be used or re-used for the first time to its initial clean state. Use to avoid clicks or artifacts.

§read: DspReadCallback

[w] Read callback. Processing is done here. Can be null.

§set_position: DspSetPositionCallback

[w] Set position callback. This is called if the unit wants to update its position info but not process data, or reset a cursor position internally if it is reading data from a certain source. Can be null.

§num_parameters: i32

[w] Number of parameters used in this filter. The user finds this with DSP::getNumParameters

§param_desc: DspParameterDesc

[w] Variable number of parameter structures.

§set_parameter: DspSetParamCallback

[w] This is called when the user calls DSP::setParameter. Can be null.

§get_parameter: DspGetParamCallback

[w] This is called when the user calls DSP::getParameter. Can be null.

§config_width: i32

[w] Width of config dialog graphic if there is one. 0 otherwise.

§config_height: i32

[w] Height of config dialog graphic if there is one. 0 otherwise.

Trait Implementations§

Source§

impl Default for DspDescription

Source§

fn default() -> DspDescription

Returns the “default value” for a type. 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.