summaryrefslogtreecommitdiffstats
path: root/test/com/jogamp/opencl/CLBufferTest.java
diff options
context:
space:
mode:
authorMichael Bien <[email protected]>2011-04-20 01:01:42 +0200
committerMichael Bien <[email protected]>2011-04-20 01:01:42 +0200
commit59ec9a937001549262c37c543266cc6015e53f9d (patch)
treee52a7c0a07a65f6612308ba26b332b07e8b56656 /test/com/jogamp/opencl/CLBufferTest.java
parent3c06ab634c7119249d37f808a5a979a5f7776de5 (diff)
added mapped CLMemory argument to putUnmapMemory for more flexibility.
Diffstat (limited to 'test/com/jogamp/opencl/CLBufferTest.java')
-rw-r--r--test/com/jogamp/opencl/CLBufferTest.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/com/jogamp/opencl/CLBufferTest.java b/test/com/jogamp/opencl/CLBufferTest.java
index 0e4a4a65..1b718277 100644
--- a/test/com/jogamp/opencl/CLBufferTest.java
+++ b/test/com/jogamp/opencl/CLBufferTest.java
@@ -158,10 +158,10 @@ public class CLBufferTest {
ByteBuffer mappedBufferA = queue.putMapBuffer(clBufferA, Map.READ_WRITE, true);
assertEquals(sizeInBytes, mappedBufferA.capacity());
- fillBuffer(mappedBufferA, 12345); // write to A
+ fillBuffer(mappedBufferA, 12345); // write to A
- queue.putUnmapMemory(clBufferA) // unmap A
- .putCopyBuffer(clBufferA, clBufferB); // copy A -> B
+ queue.putUnmapMemory(clBufferA, mappedBufferA)// unmap A
+ .putCopyBuffer(clBufferA, clBufferB); // copy A -> B
// map B for read operations
ByteBuffer mappedBufferB = queue.putMapBuffer(clBufferB, Map.READ, true);
@@ -171,7 +171,7 @@ public class CLBufferTest {
checkIfEqual(mappedBufferA, mappedBufferB, elements); // A == B ?
out.println("results are valid");
- queue.putUnmapMemory(clBufferB); // unmap B
+ queue.putUnmapMemory(clBufferB, mappedBufferB); // unmap B
context.release();