NativeTextureView
struct · ferroui-media-opengl · v0.5.0
struct NativeTextureView
An immutable GL_TEXTURE_2D alias of retained native storage. The release callback owns both the alias and its backing, and runs on the owning render context after all consumer leases have finished. None means context loss.
Members
new
unsafe fn new(context: Rc<dyn IGlContext>, texture: u32, release: impl FnOnce(Option<&GlInterface>) -> () + Send + 'static) -> Self
Safety
The texture must be complete RGBA8-compatible immutable storage, readable
by the current context with native producer synchronization established.
release must own the backing, delete the alias only on Some(context),
and safely release native-only resources on None. No borrowed handles may
escape the callback's owned captures. Never delete this texture elsewhere.
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>AnyClassDefaultsErasedDestructorIntoEitherDrop
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.