pub trait CubeTask<C: Compiler>: Send + Sync {
// Required methods
fn id(&self) -> KernelId;
fn compile(
&self,
compiler: &mut C,
compilation_options: &C::CompilationOptions,
mode: ExecutionMode,
) -> CompiledKernel<C>;
// Provided method
fn name(&self) -> &'static str { ... }
}
Expand description
Kernel trait with the ComputeShader that will be compiled and cached based on the provided id.
Required Methods§
Sourcefn compile(
&self,
compiler: &mut C,
compilation_options: &C::CompilationOptions,
mode: ExecutionMode,
) -> CompiledKernel<C>
fn compile( &self, compiler: &mut C, compilation_options: &C::CompilationOptions, mode: ExecutionMode, ) -> CompiledKernel<C>
Compile the kernel into source