Struct Context

Source
#[repr(C)]
pub struct Context { /* private fields */ }

Implementations§

Source§

impl Context

Source

pub fn deviceId(&self) -> u32

Source§

impl Context

Source

pub fn createJob(self: Pin<&mut Self>) -> *mut Job

Source§

impl Context

Source

pub unsafe fn destroyJob(self: Pin<&mut Self>, job: *mut Job) -> PxlResult

Source§

impl Context

Source

pub fn stream(&self) -> *mut Stream

Source§

impl Context

Source

pub fn availableSubCount(&self) -> u32

Source§

impl Context

Source

pub fn availableMemSize(&self) -> u64

Source§

impl Context

Source

pub fn availableIoMemSize(&self) -> u64

Source§

impl Context

Source

pub fn getAttribute(&self, attr: DeviceAttr, value: &mut u64) -> PxlResult

Source§

impl Context

Source

pub fn memAlloc(self: Pin<&mut Self>, size: usize) -> *mut c_void

Source§

impl Context

Source

pub fn memCalloc(self: Pin<&mut Self>, num: usize, size: usize) -> *mut c_void

Source§

impl Context

Source

pub fn ioMemAlloc(self: Pin<&mut Self>, size: usize) -> *mut c_void

Source§

impl Context

Source

pub unsafe fn memFree(self: Pin<&mut Self>, ptr: *const c_void)

Source§

impl Context

Source

pub unsafe fn copyToDevice( self: Pin<&mut Self>, device_ptr: *const c_void, host_ptr: *const c_void, size: usize, ) -> PxlResult

Source§

impl Context

Source

pub unsafe fn copyFromDevice( self: Pin<&mut Self>, host_ptr: *const c_void, device_ptr: *const c_void, size: usize, ) -> PxlResult

Source§

impl Context

Source

pub unsafe fn syncToDevice( self: Pin<&mut Self>, device_ptr: *const c_void, size: usize, ) -> PxlResult

Source§

impl Context

Source

pub unsafe fn syncFromDevice( self: Pin<&mut Self>, device_ptr: *const c_void, size: usize, ) -> PxlResult

Source§

impl Context

Source

pub unsafe fn getMemInfo( self: Pin<&mut Self>, host_ptr: *const c_void, ) -> MemInfo_t

Trait Implementations§

Source§

impl ExternType for Context

Source§

type Kind = Opaque

Source§

type Id

A type-level representation of the type’s C++ namespace and type name. Read more

Auto Trait Implementations§

§

impl !Freeze for Context

§

impl RefUnwindSafe for Context

§

impl !Send for Context

§

impl !Sync for Context

§

impl !Unpin for Context

§

impl UnwindSafe for Context

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.