Struct winsafe::dshow::IFileSinkFilter[][src]

pub struct IFileSinkFilter { /* fields omitted */ }
Expand description

IFileSinkFilter COM interface over IFileSinkFilterVT. Inherits from IUnknown.

Automatically calls IUnknown::Release when the object goes out of scope.

Implementations

Returns the raw pointer to pointer to the COM virtual table.

IFileSinkFilter::GetCurFile method.

If you pass a AM_MEDIA_TYPE reference to pmt, its pbFormat field may return a valid reference to a format block. If so, you must free it with CoTaskMemFree, or you’ll have a memory leak.

Examples

use winsafe::{CoMemTaskFree, dshow};

let isink: dshow::IFileSinkFilter; // initialized somewhere

let mut ammt = dshow::AM_MEDIA_TYPE::default();
unsafe {
    isink.GetCurFile(Some(&mut ammt))?;
    if let Some(pb_format) = ammt.pbFormat::<dshow::DVINFO>() {
        CoTaskMemFree(pb_format);
    }
}

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

The COM interface ID.

Executes the destructor for this type. Read more

Performs the conversion.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

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

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.