Application for Android with Qt/C++
sebastian at centricular.com
Tue Jun 23 02:58:43 PDT 2015
On Di, 2015-06-23 at 00:21 -0700, Liru7 wrote:
> Hello Sebastian!
> Thx for your answer :-)
> I already know this function which is part of "gstreamer_android.c"
> in the
> android tutorials. But I'm not sure how to get all the initialization
> integrated in my C++ project in QtCreator.
> If I understand right, than I have to take care that
> and all the functions called from it have to be available in my Qt
> But I don't really know how to get the parameters for
> In the java environment the parameters information comes from the
> where is set which plugins should be integrated. Right?
> --> gst_android_init (*JNIEnv * env, jclass klass, jobject context*)
> For the last parameter I take "android.content.Context". But I have
> no idea
> from where I get the instances of JNIEnv* and jclass? Because I can't
> out where gst_android_init ist called with this parameters.
You have to get those values from somewhere, I don't know how this
works with Qt. You somehow need to be able to get a JNIEnv*, you will
also need that for any other Android specific Java API (and you
probably can't create a non-trivial application without).
But note that the new signature of that function is a bit different:
You only need the JNIEnv* and the android.context.Context instance of
For being able to call that, just declare that function somewhere in
your code and then just call it. As long as you make sure the
libgstreamer_android.so is linked in your application it will work.
Sebastian Dröge, Centricular Ltd · http://www.centricular.com
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 949 bytes
Desc: This is a digitally signed message part
More information about the gstreamer-devel