Skip to main content

SfxBackend

Trait SfxBackend 

Source
pub trait SfxBackend {
    // Required methods
    fn name(&self) -> &'static str;
    fn generate_to(
        &mut self,
        out_path: &Path,
        prompt: Option<&str>,
        duration_seconds: f64,
        prompt_influence: f64,
    ) -> Result<()>;

    // Provided methods
    fn asset_comment(&self) -> Option<&'static str> { ... }
    fn close(&mut self) -> Result<()> { ... }
}
Expand description

SfxBackend: generate_to(out_path, prompt, duration, influence) + close().

Required Methods§

Source

fn name(&self) -> &'static str

Source

fn generate_to( &mut self, out_path: &Path, prompt: Option<&str>, duration_seconds: f64, prompt_influence: f64, ) -> Result<()>

Provided Methods§

Source

fn asset_comment(&self) -> Option<&'static str>

asset_comment, when the backend attaches a provenance note.

Source

fn close(&mut self) -> Result<()>

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§