diff options
author | Michael Bien <[email protected]> | 2010-02-22 23:38:56 +0100 |
---|---|---|
committer | Michael Bien <[email protected]> | 2010-02-22 23:38:56 +0100 |
commit | d78faf0ef678cc87f5220d2cb8eccbe173449541 (patch) | |
tree | 8a4dcff14f70c88869d6bdc095817474ae729311 /src/com/mbien/opencl/CLKernel.java | |
parent | 7c83da1d2e3e8d122e562408a63a13928cc97c83 (diff) |
introduced CLObject as common superclass for all OpenCL objects.
Diffstat (limited to 'src/com/mbien/opencl/CLKernel.java')
-rw-r--r-- | src/com/mbien/opencl/CLKernel.java | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/com/mbien/opencl/CLKernel.java b/src/com/mbien/opencl/CLKernel.java index a8c1ff10..a4573a01 100644 --- a/src/com/mbien/opencl/CLKernel.java +++ b/src/com/mbien/opencl/CLKernel.java @@ -19,14 +19,12 @@ import static com.mbien.opencl.CL.*; * CLKernel is not threadsafe. * @author Michael Bien */ -public class CLKernel implements CLResource, Cloneable { +public class CLKernel extends CLObject implements CLResource, Cloneable { - public final long ID; public final String name; public final int numArgs; private final CLProgram program; - private final CL cl; private final ByteBuffer buffer; @@ -34,9 +32,8 @@ public class CLKernel implements CLResource, Cloneable { private boolean force32BitArgs; CLKernel(CLProgram program, long id) { - this.ID = id; + super(program.getContext(), id); this.program = program; - this.cl = program.context.cl; this.buffer = BufferFactory.newDirectByteBuffer(8); PointerBuffer pb = PointerBuffer.allocateDirect(1); |