<div dir="ltr"><br><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">


Message: 2<br>
Date: Mon, 02 Sep 2013 16:20:13 +0200<br>
From: Sebastian Dr?ge <<a href="mailto:slomo@circular-chaos.org">slomo@circular-chaos.org</a>><br>
To: Discussions about GStreamer on Android<br>
        <<a href="mailto:gstreamer-android@lists.freedesktop.org">gstreamer-android@lists.freedesktop.org</a>><br>
Subject: Re: Failed to allocate buffer while playing mp4 file<br>
Message-ID: <1378131613.4380.30.camel@thor.lan><br>
Content-Type: text/plain; charset="utf-8"<br>
<br>
On Mo, 2013-09-02 at 17:10 +0800, Bruce Tsai wrote:<br>
><br>
>         Message: 5<br>
>         Date: Mon, 02 Sep 2013 09:48:48 +0200<br>
>         From: Sebastian Dr?ge <<a href="mailto:slomo@circular-chaos.org">slomo@circular-chaos.org</a>><br>
>         To: Discussions about GStreamer on Android<br>
>                 <<a href="mailto:gstreamer-android@lists.freedesktop.org">gstreamer-android@lists.freedesktop.org</a>><br>
>         Subject: Re: Failed to allocate buffer while playing mp4 file<br>
>         Message-ID: <1378108128.4380.14.camel@thor.lan><br>
>         Content-Type: text/plain; charset="UTF-8"<br>
><br>
>         On Mo, 2013-09-02 at 10:43 +0800, Bruce Tsai wrote:<br>
>         > If I want to print more debug info, how could I build<br>
>         gstreamer-sdk<br>
>         > with my modified code by "cerbero"?<br>
><br>
>         You should first of all build the SDK completely for Android<br>
>         according<br>
>         to the documentation. Then you could use the cerbero shell to<br>
>         apply your<br>
>         changes in<br>
>         cerbero/sources/android*/gst-plugins-bad-*-static/sys/androidmedia<br>
>         run make and copy .libs/*.a to<br>
>         cerbero/dist/android*/lib/gstreamer*/static<br>
><br>
><br>
><br>
> This is really really interesting!<br>
> I rebuilt libgstandroidmedia according your instruction without<br>
> modifying anything.<br>
> Then every thing is fine though the error, "Failed to call Java<br>
> method", still exists!<br>
> The video frames are correctly presented with audio.<br>
<br>
Not sure why or how that is possible :) Which instructions and sources<br>
did you use to build GStreamer?<br></blockquote><div><br></div><div>I git cerbero from git://<a href="http://anongit.freedesktop.org/gstreamer-sdk/cerbero">anongit.freedesktop.org/gstreamer-sdk/cerbero</a></div><div>The commit index is 374d5b.</div>

<div>After setup, run "cerbero -c config/cross-andorid.cbc bootstrap"</div><div>Then run "cerbero -c config/cross-android.cbc package gstreamer-sdk"</div><div>The version of gst-plugins-bad-static in cerbero/sources/android_arm is 0.10.23</div>

<div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<br>
> By outputting exception detail, I also found "Failed to call Java<br>
> method" is due to an exception from calling "dequeueOutputBuffer".<br>
> There is a similar question on StackOverflow, [1].<br>
<br>
Hmm, I don't think this is related though. Might be useful to check from<br>
where in the Android code this exception comes from, and also what<br>
exactly the exception is first (i.e. print the stacktrace and all<br>
that) :)<br><br>
</blockquote></div><br></div><div class="gmail_extra">I updated the log at [1] with stacktrace for the exception.</div><div class="gmail_extra"><pre id="code" class="" style="overflow:auto;padding:10px;margin-top:0px;margin-bottom:0px;white-space:pre-wrap;word-wrap:break-word;color:rgb(0,0,0);font-size:12px;font-family:Consolas,'Bitstream Vera Sans Mono','Courier New',Courier,monospace!important">

java.lang.IllegalStateException
android.media.MediaCodec.dequeueOutputBuffer(Native Method)
dalvik.system.NativeStart.run(Native Method)</pre></div><div class="gmail_extra"><br></div><div class="gmail_extra">[1]<a href="https://dl.dropboxusercontent.com/u/72809300/GoogleNexus7/log_no_mp4_video.txt">https://dl.dropboxusercontent.com/u/72809300/GoogleNexus7/log_no_mp4_video.txt</a></div>

</div>