IPLOpenCLDeviceSettings

Struct IPLOpenCLDeviceSettings 

Source
#[repr(C)]
pub struct IPLOpenCLDeviceSettings { pub type_: IPLOpenCLDeviceType, pub numCUsToReserve: IPLint32, pub fractionCUsForIRUpdate: IPLfloat32, pub requiresTAN: IPLbool, }
Expand description

Specifies requirements that an OpenCL device must meet in order to be considered when listing OpenCL devices.

Fields§

§type_: IPLOpenCLDeviceType

The type of device. Set to \c IPL_OPENCLDEVICETYPE_ANY to consider all available devices.

§numCUsToReserve: IPLint32

The number of GPU compute units (CUs) that should be reserved for use by Steam Audio. If set to a non-zero value, then a GPU will be included in the device list only if it can reserve at least this many CUs. Set to 0 to indicate that Steam Audio can use the entire GPU, in which case all available GPUs will be considered.

Ignored if \c type is \c IPL_OPENCLDEVICETYPE_CPU.

§fractionCUsForIRUpdate: IPLfloat32

The fraction of reserved CUs that should be used for impulse response (IR) update. IR update includes: a) ray tracing using Radeon Rays to simulate sound propagation, and/or b) pre-transformation of IRs for convolution using TrueAudio Next. Steam Audio will only list GPU devices that are able to subdivide the reserved CUs as per this value. The value must be between 0 and 1.

For example, if \c numCUsToReserve is \c 8, and \c fractionCUsForIRUpdate is \c 0.5f, then 4 CUs will be used for IR update and 4 CUs will be used for convolution. Below are typical scenarios:

  • Using only TrueAudio Next. Set \c fractionCUsForIRUpdate to \c 0.5f. This ensures that reserved CUs are available for IR update as well as convolution.

  • Using TrueAudio Next and Radeon Rays for real-time simulation and rendering. Choosing \c fractionCUsForIRUpdate may require some experimentation to utilize reserved CUs optimally. You can start by setting \c fractionCUsForIRUpdate to \c 0.5f. However, if IR calculation has high latency with these settings, increase \c fractionCUsForIRUpdate to use more CUs for ray tracing.

  • Using only Radeon Rays. Set \c fractionCUsForIRUpdate to \c 1, to make sure all the reserved CUs are used for ray tracing. If using Steam Audio for preprocessing (e.g. baking reverb), then consider setting \c numCUsToReserve to \c 0 to use the entire GPU for accelerated ray tracing.

Ignored if \c type is \c IPL_OPENCLDEVICETYPE_CPU or \c numCUsToReserve is \c 0.

§requiresTAN: IPLbool

If \c IPL_TRUE, then the GPU device must support TrueAudio Next. It is not necessary to set this to \c IPL_TRUE if \c numCUsToReserve or \c fractionCUsForIRUpdate are set to non-zero values.

Trait Implementations§

Source§

impl Clone for IPLOpenCLDeviceSettings

Source§

fn clone(&self) -> IPLOpenCLDeviceSettings

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for IPLOpenCLDeviceSettings

Source§

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

Formats the value using the given formatter. Read more
Source§

impl Copy for IPLOpenCLDeviceSettings

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. 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> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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.