diff options
Diffstat (limited to 'src/com')
-rw-r--r-- | src/com/jogamp/opencl/CLMemory.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/com/jogamp/opencl/CLMemory.java b/src/com/jogamp/opencl/CLMemory.java index 6a28d0a5..00f51b6b 100644 --- a/src/com/jogamp/opencl/CLMemory.java +++ b/src/com/jogamp/opencl/CLMemory.java @@ -145,7 +145,7 @@ public abstract class CLMemory <B extends Buffer> extends CLObjectResource { if(buffer == null) { return 0; } - return buffer.capacity(); + return buffer.limit(); } /** @@ -155,7 +155,7 @@ public abstract class CLMemory <B extends Buffer> extends CLObjectResource { if(buffer == null) { return 0; } - return getElementSize() * buffer.capacity(); + return getElementSize() * buffer.limit(); } /** |