summaryrefslogtreecommitdiffstats
path: root/src/com/mbien/opencl/CLMemory.java
diff options
context:
space:
mode:
authorMichael Bien <[email protected]>2010-03-08 17:08:03 +0100
committerMichael Bien <[email protected]>2010-03-08 17:08:03 +0100
commite081f13ca50353a7a9c34438a2f81d38e03e88a7 (patch)
tree7948e78a8e73fb4de5340a80075d35a8a1499c1f /src/com/mbien/opencl/CLMemory.java
parent5ad19147a76f80635dcae18693929edbf1da2cbf (diff)
introduced gl package and moved all interoperability functionality into it.
Diffstat (limited to 'src/com/mbien/opencl/CLMemory.java')
-rw-r--r--src/com/mbien/opencl/CLMemory.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/com/mbien/opencl/CLMemory.java b/src/com/mbien/opencl/CLMemory.java
index 275f39ff..8bebea4c 100644
--- a/src/com/mbien/opencl/CLMemory.java
+++ b/src/com/mbien/opencl/CLMemory.java
@@ -52,6 +52,10 @@ public abstract class CLMemory <B extends Buffer> extends CLObject implements CL
throw new RuntimeException("Unexpected buffer type " + buffer.getClass().getName());
}
+ protected static CL getCL(CLContext context) {
+ return context.cl;
+ }
+
/**
* Returns a new instance of CLMemory pointing to the same CLResource but using a different Buffer.
*/
@@ -250,7 +254,7 @@ public abstract class CLMemory <B extends Buffer> extends CLObject implements CL
return null;
}
- static int flagsToInt(Mem[] flags) {
+ public static int flagsToInt(Mem[] flags) {
int clFlags = 0;
if (flags != null) {
for (int i = 0; i < flags.length; i++) {