i just threw together a ‘proof-of-concept’ i was thinking about for some time now.
after having a lot of trouble with the, as of now, crappy QTJ API i finally figured out a way to use the native QT API through the JNI. as mentionened above the code is more of a ‘proof-of-concept’ and since i have not much experience with C/CPP i didn t manage to come up with a windows version ( maybe someone can help
). it s just osx.
the basic concept is to get rid off the, especially under osx, annoying copying of data from native to java to native to opengl and rather leave all the heavy data pushing in native world where it belongs.
i was really suprised to find out that when suppling a valid opengl context from jogl, you can call ‘native’ opengl functions via JNI from native code. i m not sure if this is valid, whatever that means, but i tested it under osx on several occasion and it seems to be robust.
with that knowledge i wrote ( and snipped of course ) a little wrapper around the native QT API that would simply allocate some memory, let quicktime write into this memory and copy it to opengl, all on the native side. the java/jogl part would just controll the whole process. which is creating, playing, looping movies etc.
it still seems a bit like blackmagic to me and maybe is. i would be happy to get some feedback and even better some improvement on this approach.
-> QTGLJNI