#[repr(transparent)]pub struct RawPipe(_);cl2 only.Implementations§
source§impl RawPipe
impl RawPipe
pub fn new( access: MemAccess, host_access: bool, packet_size: u32, max_packets: u32 ) -> Result<Self>
pub fn new_in( ctx: &RawContext, access: MemAccess, host_access: bool, packet_size: u32, max_packets: u32 ) -> Result<Self>
sourcepub fn packet_size(&self) -> Result<NonZeroU32>
pub fn packet_size(&self) -> Result<NonZeroU32>
Return pipe packet size specified when pipe is created.
sourcepub fn max_packets(&self) -> Result<NonZeroU32>
pub fn max_packets(&self) -> Result<NonZeroU32>
Return max. number of packets specified when pipe is created.
Methods from Deref<Target = RawMemObject>§
pub unsafe fn retain(&self) -> Result<()>
pub fn id(&self) -> cl_mem
pub fn id_ref(&self) -> &cl_mem
pub fn id_ref_mut(&mut self) -> &mut cl_mem
sourcepub fn ty(&self) -> Result<MemObjectType>
pub fn ty(&self) -> Result<MemObjectType>
Returns the memory obejct’s type
sourcepub fn associated_memobject(&self) -> Result<Option<RawMemObject>>
Available on crate feature cl1_1 only.
pub fn associated_memobject(&self) -> Result<Option<RawMemObject>>
cl1_1 only.Return memory object from which memobj is created.
sourcepub fn flags(&self) -> Result<MemFlags>
pub fn flags(&self) -> Result<MemFlags>
Return the flags argument value specified when memobj is created.
sourcepub fn size(&self) -> Result<usize>
pub fn size(&self) -> Result<usize>
Return actual size of the data store associated with memobj in bytes.
sourcepub fn host_ptr(&self) -> Result<Option<NonNull<c_void>>>
pub fn host_ptr(&self) -> Result<Option<NonNull<c_void>>>
If memobj is created with a host_ptr specified, return the host_ptr argument value specified when memobj is created.
sourcepub fn map_count(&self) -> Result<u32>
pub fn map_count(&self) -> Result<u32>
Map count. The map count returned should be considered immediately stale. It is unsuitable for general use in applications. This feature is provided for debugging.
sourcepub fn reference_count(&self) -> Result<u32>
pub fn reference_count(&self) -> Result<u32>
Return memobj reference count. The reference count returned should be considered immediately stale. It is unsuitable for general use in applications. This feature is provided for identifying memory leaks.
sourcepub fn context(&self) -> Result<RawContext>
pub fn context(&self) -> Result<RawContext>
Return context specified when memory object is created.
sourcepub fn offset(&self) -> Result<usize>
Available on crate feature cl1_1 only.
pub fn offset(&self) -> Result<usize>
cl1_1 only.Return offset if memobj is a sub-buffer object created using create_sub_buffer. Returns 0 if memobj is not a subbuffer object.
sourcepub fn uses_svm_pointer(&self) -> Result<bool>
pub fn uses_svm_pointer(&self) -> Result<bool>
Return true if memobj is a buffer object that was created with CL_MEM_USE_HOST_PTR or is a sub-buffer object of a buffer object that was created with CL_MEM_USE_HOST_PTR and the host_ptr specified when the buffer object was created is a SVM pointer; otherwise returns false.
sourcepub fn on_destruct(&self, f: impl 'static + FnOnce() + Send) -> Result<()>
Available on crate feature cl1_1 only.
pub fn on_destruct(&self, f: impl 'static + FnOnce() + Send) -> Result<()>
cl1_1 only.Adds a callback to be executed when the memory object is destructed by OpenCL.
pub fn on_destruct_boxed(&self, f: Box<dyn FnOnce() + Send>) -> Result<()>
cl1_1 only.pub unsafe fn on_destruct_raw( &self, f: unsafe extern "C" fn(memobj: cl_mem, user_data: *mut c_void), user_data: *mut c_void ) -> Result<()>
cl1_1 only.