Package foundry.veil.api.opencl
Class CLEnvironmentOptions.Builder
java.lang.Object
foundry.veil.api.opencl.CLEnvironmentOptions.Builder
- Enclosing class:
CLEnvironmentOptions
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Sets the target of the environment to a compute accelerator.Sets the target of the environment to the CPU.Sets the target of the environment to the default device.Sets the target of the environment to the GPU.deviceMask
(int deviceMask) Sets the devices the environment should target.setClVersion
(CLEnvironmentOptions.CLVersion clVersion) Sets the version of OpenCL to target.setRequireCompiler
(boolean requireCompiler) Sets whether a compiler is required for the device.setRequireGL
(boolean requireOpenGL) Sets whether a compiler is required for the device.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
setClVersion
Sets the version of OpenCL to target.- Parameters:
clVersion
- The CL version to use
-
deviceDefault
Sets the target of the environment to the default device. -
deviceGpu
Sets the target of the environment to the GPU. -
deviceCpu
Sets the target of the environment to the CPU. -
deviceAccelerator
Sets the target of the environment to a compute accelerator. -
deviceMask
Sets the devices the environment should target. If unsure, leave the default.- Parameters:
deviceMask
- The mask for what kinds of devices to use
-
setRequireCompiler
Sets whether a compiler is required for the device. This is only needed to use string programs.- Parameters:
requireCompiler
- Whether the device needs to have a compiler
-
setRequireGL
Sets whether a compiler is required for the device. This is only needed to use string programs.- Parameters:
requireOpenGL
- Whether the device needs to have a compiler
-
build
- Returns:
- A new environment option spec
-