starting android development

Chuck Crisler ccrisler at mutualink.net
Fri Mar 20 06:27:34 PDT 2015


Thank you *VERY MUCH* for the help. I suspected that the SDK was old. It
would be helpful if there was a note added to the (real) GStreamer website
to that effect.

On Fri, Mar 20, 2015 at 4:54 AM, Sérgio Agostinho <
sergio.r.agostinho at gmail.com> wrote:

> Hi Chuck,
>
> This might also be useful. I remember I struggled for a while to properly
> build Gstreamer with Android Studio. Place your Android.mk and
> Application.mk inside src/main/jni
> Add these snippets to your local.properties file
>
> android{
>>     //otherstuff
>>     sourceSets.main {
>>         jniLibs.srcDir 'src/main/libs'
>>         jni.srcDirs = [];
>>     }
>>     tasks.withType(JavaCompile) {
>>         compileTask -> compileTask.dependsOn ndkBuild
>>     }
>>     task('ndkBuild', type: Exec) {
>>         // normal building tool
>>         commandLine 'ndk-build', 'clean'
>>         commandLine 'ndk-build', 'APP_PLATFORM=*<replace with target
>> version e.g. android-19>*', '-C', file('src/main').absolutePath
>>     }
>> }
>
>
> This ensures your ndk code will always be compiled before your java code,
> and that the Gstreamer.java will be already in your src folder.
>
> Cheers
>
>
> 2015-03-20 9:41 GMT+01:00 Sebastian Dröge <sebastian at centricular.com>:
>
>> On Do, 2015-03-19 at 22:30 -0400, Chuck Crisler wrote:
>> > I am trying to learn Java and Android development at the same time.
>> > Fortunately, I know GStreamer fairly well. I have the Android Studio,
>> the
>> > SDK and the NDK installed on my Linux system and have downloaded the
>> > GStreamer 1.4.5 ARM v7 binaries. I have also downloaded the GStreamer
>> SDK
>> > and have been looking at ~slomo/gst-sdk-tutorials. I am confused and
>> can't
>> > seem to 'put it all together'. I have read and built and executed (on my
>> > Android phone) some of the pure Android samples, including JNI samples.
>> I
>> > feel that I could convert a GStreamer Android SDK based tutorial to the
>> > Android Studio structure.
>> >
>> > Here are the questions that I immediately don't understand.
>> > 1. Do I need both the 1.4.5 binaries and the GStreamer SDK?
>>
>> The GStreamer 1.4.5 binaries contain everything that the "GStreamer SDK"
>> contains, just 3 years newer.
>>
>> > 2. Do I need to build anything to get started working with the GStreamer
>> > tutorials?
>>
>> You just need to extract the binaries to some please and then set
>> GSTREAMER_ROOT_ANDROID in the environment to that place. Then you can
>> just build them like any other Android project.
>>
>> > 3. Tutorial #1 imports package org.freedesktop.gstreamer.GStreamer,
>> which I
>> > don't think that I have. How should I build it, or where is it?
>>
>> That's autogenerated by ndk-build.
>>
>> > 4. Which tutorials are more current, ~slomo or the GStreamer SDK?
>>
>> See above :)
>>
>> > 5. Is it possible to run something like the command line gst-launch
>> > application on Android to test pipelines and installations?
>>
>> Yes but command line applications don't have access to the hardware
>> codecs and other things, and you need a rooted device.
>>
>> See
>>
>> https://coaxion.net/blog/2014/10/gstreamer-remote-controlled-testing-application-for-android-ios-and-more/
>> for some gst-launch style application for Android/iOS.
>>
>> Also see
>> https://github.com/sdroege/gst-player
>> for some (hopefully) cleaner code (than the tutorials) for how to do
>> GStreamer Android development by properly splitting the backend (C) and
>> the frontend (Java).
>>
>> --
>> Sebastian Dröge, Centricular Ltd · http://www.centricular.com
>>
>> _______________________________________________
>> gstreamer-devel mailing list
>> gstreamer-devel at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>>
>>
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
>


-- 
___________________________________________________
Name
*Chuck Crisler*

Mutualink, Inc.
3 Lan Dr.
Westford, MA  01886

Direct: (978) 490-3006 <%28866%29%20957-5465> Ext: 118

E-Mail: ccrisler at mutualink.net <employeer at mutualink.net>

Web: www.mutualink.net


The information in this email, and subsequent attachments, may contain
confidential information that is
intended solely for the attention and use of the named addressee(s). This
message or any part thereof
must not be disclosed, copied, distributed or retained by any person
without authorization from the addressee.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20150320/2c9470a0/attachment-0001.html>


More information about the gstreamer-devel mailing list