JOCL FAQ: Difference between revisions
No edit summary |
|||
Line 52: | Line 52: | ||
// creates a shared context. This context can be used to share memory with JOGL's OpenGL context | // creates a shared context. This context can be used to share memory with JOGL's OpenGL context | ||
[http://jogamp.org/deployment/webstart-next/javadoc/jocl/javadoc/com/jogamp/opencl/gl/CLGLContext.html CLGLContext].create(glContext); | [http://jogamp.org/deployment/webstart-next/javadoc/jocl/javadoc/com/jogamp/opencl/gl/CLGLContext.html CLGLContext].create(glContext); | ||
== Can I allocate a CLBuffer without allocating a java.nio.Buffer? == | |||
yes, just use the right context.createBuffer() method: http://jogamp.762907.n3.nabble.com/Allocate-memory-object-on-device-only-td2465039.html |
Revision as of 15:33, 10 February 2011
How do I get the Source Code?
The project repository is located on github.
You can create a local copy/branch of the git repository, either anonymous:
- git clone git://github.com/mbien/gluegen.git gluegen
- git clone git://github.com/mbien/jocl.git jocl
- git clone git://github.com/mbien/jocl-demos.git jocl-demos
- git clone git://github.com/mbien/jogl.git jogl
or via SSH and your user credential, so you can easily push back your changes to the github server:
- git clone [email protected]:username/gluegen.git gluegen
- git clone [email protected]:username/jocl.git jocl
- git clone [email protected]:username/jocl-demos.git jocl-demos
- git clone [email protected]:username/jogl.git jogl
What are the Build Dependencies?
JOCL depends on GlueGen and JOGL
JDK6 and ANT 1.8 or later. JUnit tests require OpenCL capable hardware and OpenCL drivers.
I have all the Sourcecode, how do I build it?
Please refer to this HowTo
What files do I need at Runtime?
JOCL consists of two files:
- jocl.jar
- and one system dependent native library (e.g libjocl.so or jocl.dll or ..).
additionally you will have to provide
- gluegen-rt.jar
- and the corresponding native library (e.g libgluegen-rt.so or gluegen.dll or ...)
optionally you might want to add JOGL if you want to do OpenGL - OpenCL interoperability
How do I Get Started?
Is it possible to run JOCL based app without JOGL?
Yes. JOCL is independent from JOGL and can be used without JOGL in the classpath. In fact you have to explicitly create a shared context from a existing JOGL context if you want to interoperate with OpenGL.
// creates a pure OpenCL context CLContext.create();
// creates a shared context. This context can be used to share memory with JOGL's OpenGL context CLGLContext.create(glContext);
Can I allocate a CLBuffer without allocating a java.nio.Buffer?
yes, just use the right context.createBuffer() method: http://jogamp.762907.n3.nabble.com/Allocate-memory-object-on-device-only-td2465039.html