summaryrefslogtreecommitdiffstats
path: root/src/com/mbien/opencl/CLKernel.java
diff options
context:
space:
mode:
authorMichael Bien <[email protected]>2010-01-18 15:24:29 +0100
committerMichael Bien <[email protected]>2010-01-18 15:24:29 +0100
commit09ac312a0645bd0d9adff580f29f20382dfbf8c9 (patch)
tree52e121e8c366c797f34008244243dd896cc1e88a /src/com/mbien/opencl/CLKernel.java
parentc4aeea288271f57b3c8640a8cd4ba87d1c331814 (diff)
introduced CLMemory as superclass for all memory objects.
added CLImage, CLImage2d and CLImage3d.
Diffstat (limited to 'src/com/mbien/opencl/CLKernel.java')
-rw-r--r--src/com/mbien/opencl/CLKernel.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/com/mbien/opencl/CLKernel.java b/src/com/mbien/opencl/CLKernel.java
index 30ccc202..33d30730 100644
--- a/src/com/mbien/opencl/CLKernel.java
+++ b/src/com/mbien/opencl/CLKernel.java
@@ -58,7 +58,7 @@ public class CLKernel implements CLResource {
}
- public CLKernel putArg(CLBuffer<?> value) {
+ public CLKernel putArg(CLMemory<?> value) {
setArg(argIndex++, value);
return this;
}
@@ -83,13 +83,13 @@ public class CLKernel implements CLResource {
return this;
}
- public CLKernel putArgs(CLBuffer<?>... values) {
+ public CLKernel putArgs(CLMemory<?>... values) {
setArgs(argIndex, values);
argIndex += values.length;
return this;
}
- public CLKernel setArg(int argumentIndex, CLBuffer<?> value) {
+ public CLKernel setArg(int argumentIndex, CLMemory<?> value) {
setArgument(argumentIndex, CPU.is32Bit()?4:8, wrap(value.ID));
return this;
}
@@ -114,12 +114,12 @@ public class CLKernel implements CLResource {
return this;
}
- public CLKernel setArgs(CLBuffer<?>... values) {
+ public CLKernel setArgs(CLMemory<?>... values) {
setArgs(0, values);
return this;
}
- private final void setArgs(int startIndex, CLBuffer<?>... values) {
+ private final void setArgs(int startIndex, CLMemory<?>... values) {
for (int i = 0; i < values.length; i++) {
setArg(i+startIndex, values[i]);
}