diff options
author | Michael Bien <[email protected]> | 2010-01-20 20:39:33 +0100 |
---|---|---|
committer | Michael Bien <[email protected]> | 2010-01-20 20:39:33 +0100 |
commit | c9e1605e183d7e83af16dc8fac057e58cfc2d29b (patch) | |
tree | 61322e181ac79d4e9d733de23b2784fb686ca902 /src/com/mbien/opencl/CLContext.java | |
parent | 21f0d9231227a4d2c96cb70b5061c18145591fba (diff) |
seperated CLProgram specific tests into CLProgramTest.
implemented create-program-from-binaries functionality.
javadoc fixes.
Diffstat (limited to 'src/com/mbien/opencl/CLContext.java')
-rw-r--r-- | src/com/mbien/opencl/CLContext.java | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/com/mbien/opencl/CLContext.java b/src/com/mbien/opencl/CLContext.java index 6fbad0df..19e3ef09 100644 --- a/src/com/mbien/opencl/CLContext.java +++ b/src/com/mbien/opencl/CLContext.java @@ -214,6 +214,13 @@ public class CLContext implements CLResource { return createProgram(sb.toString()); } + + public CLProgram createProgram(Map<CLDevice, byte[]> binaries) { + CLProgram program = new CLProgram(this, binaries); + programs.add(program); + return program; + } + /** * Creates a CLBuffer with the specified flags and element count. No flags creates a MEM.READ_WRITE buffer. */ @@ -379,8 +386,8 @@ public class CLContext implements CLResource { } /** - * Returns the device with maximal FLOPS and the specified type from this context. - * The device speed is estimated by calulating the product of + * Returns the device with maximal FLOPS of the specified device type from this context. + * The device speed is estimated by calculating the product of * MAX_COMPUTE_UNITS and MAX_CLOCK_FREQUENCY. */ public CLDevice getMaxFlopsDevice(CLDevice.Type type) { |