aboutsummaryrefslogtreecommitdiffstats
path: root/src/com/mbien/opencl/CLKernel.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/mbien/opencl/CLKernel.java')
-rw-r--r--src/com/mbien/opencl/CLKernel.java14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/com/mbien/opencl/CLKernel.java b/src/com/mbien/opencl/CLKernel.java
index eb817f14..a8c1ff10 100644
--- a/src/com/mbien/opencl/CLKernel.java
+++ b/src/com/mbien/opencl/CLKernel.java
@@ -91,6 +91,11 @@ public class CLKernel implements CLResource, Cloneable {
return this;
}
+ public CLKernel rewind() {
+ argIndex = 0;
+ return this;
+ }
+
public CLKernel setArg(int argumentIndex, CLMemory<?> value) {
setArgument(argumentIndex, CPU.is32Bit()?4:8, wrap(value.ID));
return this;
@@ -157,6 +162,10 @@ public class CLKernel implements CLResource, Cloneable {
this.force32BitArgs = force;
return this;
}
+
+ public CLProgram getProgram() {
+ return program;
+ }
/**
* @see #setForce32BitArgs(boolean)
@@ -181,11 +190,6 @@ public class CLKernel implements CLResource, Cloneable {
return buffer.putLong(value).rewind();
}
- public CLKernel rewind() {
- argIndex = 0;
- return this;
- }
-
/**
* Releases all resources of this kernel from its context.
*/