summaryrefslogtreecommitdiffstats
path: root/src/com/jogamp/opencl/impl
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2011-06-28 22:32:22 +0200
committerSven Gothel <[email protected]>2011-06-28 22:32:22 +0200
commit20a94528161909e12fdcbd06cf5affe89a37efb9 (patch)
treed4084b90238b1a318e308039f2492092cad438e6 /src/com/jogamp/opencl/impl
parent3016f4fe04dcabdd82d2475a7c23d3b47e1c8766 (diff)
parent560d4b4958c2838a934fb2008357a7a85e61b546 (diff)
Fix merge w/ latest mbien/edge
Diffstat (limited to 'src/com/jogamp/opencl/impl')
-rw-r--r--src/com/jogamp/opencl/impl/CLTLAccessorFactory.java8
-rw-r--r--src/com/jogamp/opencl/impl/CLTLInfoAccessor.java16
2 files changed, 12 insertions, 12 deletions
diff --git a/src/com/jogamp/opencl/impl/CLTLAccessorFactory.java b/src/com/jogamp/opencl/impl/CLTLAccessorFactory.java
index ab4fcca6..36718f1a 100644
--- a/src/com/jogamp/opencl/impl/CLTLAccessorFactory.java
+++ b/src/com/jogamp/opencl/impl/CLTLAccessorFactory.java
@@ -4,7 +4,7 @@
package com.jogamp.opencl.impl;
import java.nio.IntBuffer;
-import com.jogamp.common.nio.NativeSizeBuffer;
+import com.jogamp.common.nio.PointerBuffer;
import com.jogamp.opencl.llb.CL;
import com.jogamp.opencl.llb.CLDeviceBinding;
import com.jogamp.opencl.spi.CLAccessorFactory;
@@ -41,7 +41,7 @@ public class CLTLAccessorFactory implements CLAccessorFactory {
}
@Override
- public int getInfo(int name, long valueSize, Buffer value, NativeSizeBuffer valueSizeRet) {
+ public int getInfo(int name, long valueSize, Buffer value, PointerBuffer valueSizeRet) {
return cl.clGetDeviceInfo(ID, name, valueSize, value, valueSizeRet);
}
@@ -58,7 +58,7 @@ public class CLTLAccessorFactory implements CLAccessorFactory {
}
@Override
- public int getInfo(int name, long valueSize, Buffer value, NativeSizeBuffer valueSizeRet) {
+ public int getInfo(int name, long valueSize, Buffer value, PointerBuffer valueSizeRet) {
return cl.clGetPlatformInfo(ID, name, valueSize, value, valueSizeRet);
}
@@ -75,7 +75,7 @@ public class CLTLAccessorFactory implements CLAccessorFactory {
}else{
checkForError(ret, "error while enumerating devices");
- NativeSizeBuffer deviceIDs = NativeSizeBuffer.wrap(getBB(count*NativeSizeBuffer.elementSize()));
+ PointerBuffer deviceIDs = PointerBuffer.wrap(getBB(count*PointerBuffer.ELEMENT_SIZE));
ret = cl.clGetDeviceIDs(ID, type, count, deviceIDs, null);
checkForError(ret, "error while enumerating devices");
diff --git a/src/com/jogamp/opencl/impl/CLTLInfoAccessor.java b/src/com/jogamp/opencl/impl/CLTLInfoAccessor.java
index ee5d0e47..c31b22a6 100644
--- a/src/com/jogamp/opencl/impl/CLTLInfoAccessor.java
+++ b/src/com/jogamp/opencl/impl/CLTLInfoAccessor.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2009 - 2010 JogAmp Community. All rights reserved.
+ * Copyright (c) 2009 JogAmp Community. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification, are
* permitted provided that the following conditions are met:
@@ -29,7 +29,7 @@
package com.jogamp.opencl.impl;
import com.jogamp.opencl.spi.CLInfoAccessor;
-import com.jogamp.common.nio.NativeSizeBuffer;
+import com.jogamp.common.nio.PointerBuffer;
import com.jogamp.common.os.Platform;
import com.jogamp.opencl.util.CLUtil;
import java.nio.Buffer;
@@ -55,11 +55,11 @@ public abstract class CLTLInfoAccessor implements CLInfoAccessor {
}
};
- protected final static ThreadLocal<NativeSizeBuffer> localNSB = new ThreadLocal<NativeSizeBuffer>() {
+ protected final static ThreadLocal<PointerBuffer> localNSB = new ThreadLocal<PointerBuffer>() {
@Override
- protected NativeSizeBuffer initialValue() {
- return NativeSizeBuffer.allocateDirect(1);
+ protected PointerBuffer initialValue() {
+ return PointerBuffer.allocateDirect(1);
}
};
@@ -77,7 +77,7 @@ public abstract class CLTLInfoAccessor implements CLInfoAccessor {
@Override
public final String getString(int key) {
- NativeSizeBuffer sizeBuffer = getNSB();
+ PointerBuffer sizeBuffer = getNSB();
int ret = getInfo(key, 0, null, sizeBuffer);
checkForError(ret, "error while asking for info string");
@@ -122,11 +122,11 @@ public abstract class CLTLInfoAccessor implements CLInfoAccessor {
}
}
- protected NativeSizeBuffer getNSB() {
+ protected PointerBuffer getNSB() {
return localNSB.get();
}
- protected abstract int getInfo(int name, long valueSize, Buffer value, NativeSizeBuffer valueSizeRet);
+ protected abstract int getInfo(int name, long valueSize, Buffer value, PointerBuffer valueSizeRet);
}