Login  Register

Re: OpenCL on mobile devices

Posted by Xerxes Rånby on Jul 03, 2013; 1:22pm
URL: https://forum.jogamp.org/OpenCL-on-mobile-devices-tp4028411p4029503.html

Jim wrote
So I tried installing the jocl apk but an icon doesn't even show up on the deviece. I am guessing you need to install some of the other apks so I tried installing them all and then I got icons but none of them seemed to be opencl demos.
We currently provide an android launchers for JOGL and JOAL. An JOCL launcher can be implemented similar to the JOGL and JOAL activitys.
http://jogamp.org/git/?p=jogl.git;a=tree;f=src/test/com/jogamp/opengl/test/android
http://jogamp.org/git/?p=joal.git;a=tree;f=src/test/com/jogamp/openal/test/android

Jim wrote
Many of the demos crashed but some worked.
If you experience any issue using the 25-Jun-2013 2.0.2-rc12 .apk or later please file a bug-report:
http://jogamp.org/deployment/jogamp-current/apk/
https://jogamp.org/bugzilla/

Jim wrote
One called Elektro worked for a while after displaying a pyramid of pyramids then crashed after displaying a very complex 3d fractal that looked like cauliflower (I'm guessing that is what it is).
Demoscene Passivist's ElektronenMultiplizierer is our heavy OpenGL ES 2 GLSL stress test. It is known to take down some GPU driver implementations to its knees. ElektronenMultiplizierer is running an heavy ray-marching algorithm implemented using the fragment shader. You may want to check Demoscene Passivist's github and tumbler for more impressive visuals:
http://copypastaresearch.tumblr.com/
https://github.com/demoscenepassivist/SocialCoding

Jim wrote
I would post my own code but there is already others who have done so. Here is one basic example:
https://github.com/mattscar/opencl_device_test

basically you just have to load the driver using System.load.
Thank you for letting us know about mattscar's opencl_device_test.

We may need to make JOCL look at non-standard library names in order to resolve OpenCL library functions when in use on the first generation OpenCL mobile devices.

Example according to the aopencl project:
http://code.google.com/p/aopencl/
OpenCL are found in
/system/vendor/lib/egl/libGLES_mali.so
on Nexus 10 T604 based devices
and
/system/lib/libllvm-a3xx.so
for Nexus 4 Adreno 320 based GPU's

I have summarize these findings into a JOCL bug-report:
https://jogamp.org/bugzilla/show_bug.cgi?id=773