Struct ocl::Program
[−]
[src]
pub struct Program(_);
A program from which kernels can be created from.
To use with multiple devices, create manually with ::from_parts()
.
Destruction
Handled automatically. Feel free to store, clone, and share among threads as you please.
Methods
impl Program
[src]
fn builder() -> ProgramBuilder
Returns a new ProgramBuilder
.
fn new(
context_obj_core: &ContextCore,
src_strings: Vec<CString>,
device_ids: Option<&[Device]>,
cmplr_opts: CString
) -> OclResult<Program>
context_obj_core: &ContextCore,
src_strings: Vec<CString>,
device_ids: Option<&[Device]>,
cmplr_opts: CString
) -> OclResult<Program>
Returns a new program built from pre-created build components and device list.
Prefer ::builder
to create a new Program
.
fn core_as_ref(&self) -> &ProgramCore
: Use ::core
instead.
Returns a reference to the core pointer wrapper, usable by functions in
the core
module.
fn core(&self) -> &ProgramCore
Returns a reference to the core pointer wrapper, usable by functions in
the core
module.
fn devices(&self) -> Vec<Device>
: Use ::info
with ProgramInfo::Devices
instead.
Returns the list of devices associated with this program.
fn info(&self, info_kind: ProgramInfo) -> ProgramInfoResult
Returns info about this program.
fn build_info(
&self,
device: Device,
info_kind: ProgramBuildInfo
) -> ProgramBuildInfoResult
&self,
device: Device,
info_kind: ProgramBuildInfo
) -> ProgramBuildInfoResult
Returns info about this program's build.
- TODO: Check that device is valid.
Methods from Deref<Target = ProgramCore>
fn as_ptr(&self) -> *mut c_void
Returns a pointer, do not store it.
fn devices(&self) -> Result<Vec<DeviceId>, Error>
Returns the devices associated with this program.
Trait Implementations
impl Clone for Program
[src]
fn clone(&self) -> Program
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Debug for Program
[src]
impl Display for Program
[src]
impl Deref for Program
[src]
type Target = ProgramCore
The resulting type after dereferencing
fn deref(&self) -> &ProgramCore
The method called to dereference a value
impl DerefMut for Program
[src]
fn deref_mut(&mut self) -> &mut ProgramCore
The method called to mutably dereference a value