diff options
Diffstat (limited to 'src/com/mbien/opencl/CLContext.java')
-rw-r--r-- | src/com/mbien/opencl/CLContext.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/com/mbien/opencl/CLContext.java b/src/com/mbien/opencl/CLContext.java index db32a446..76fbc2ee 100644 --- a/src/com/mbien/opencl/CLContext.java +++ b/src/com/mbien/opencl/CLContext.java @@ -1,5 +1,6 @@ package com.mbien.opencl; +import com.sun.gluegen.runtime.BufferFactory; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; @@ -104,6 +105,10 @@ public final class CLContext { return buffer; } + public CLBuffer createBuffer(int flags, int size) { + return createBuffer(flags, BufferFactory.newDirectByteBuffer(size)); + } + CLCommandQueue createCommandQueue(CLDevice device, long properties) { CLCommandQueue queue = new CLCommandQueue(this, device, properties); |