<div dir="ltr"><div><div><div><div><div><div><div><div>Hello,<br><br>I have tried to read raw frames using android java api and send them to gstreamer pipelines using appsrc.<br><br></div>I have implemented it starting from Tutorial3 for Android and I have done the required changes. I have tried two solutions:<br>
</div>1) call a native Android function from Java code to push the buffer in appsrc<br></div>2) using callbacks related to appsrc to retrieve frame when data are needed<br><br></div>I have the following problems:<br></div>
1) The pipeline with appsrc works and I'm able to use image frame in GStreamer but the buffer is filled too fast and is cleared too slow so after some time I obtain an out of memory error.<br></div>2) This way could resolve problem of out of memory but when I call "g_idle_add ((GSourceFunc) read_data, data);" in "need-data" callback the code doesn't enter never in idle function (read_data). I have investigated on forums what could generate this problem and I have found something related to launching main_loop in an external thread; I have tried to add g_thread_init(NULL) but it doesn't resolve the problem.<br>
<br></div><div>What could be the problem?<br><br></div></div><div>Thanks in advance,<br>Francesco Argese<br><br>P.S.: Are there any changes in more recent versions of GStreamer that could simplify my work to take camera on Android?<br>
</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/5/13 Mailing List SVR <span dir="ltr"><<a href="mailto:lists@svrinformatica.it" target="_blank">lists@svrinformatica.it</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div text="#000000" bgcolor="#FFFFFF">
<div>Il 13/05/2013 11:51, Sebastian Dröge ha
scritto:<br>
</div><div><div class="h5">
<blockquote type="cite">
<pre>On Mo, 2013-05-13 at 11:35 +0200, Francesco Argese wrote:
</pre>
<blockquote type="cite">
<pre>2013/5/13 Sebastian Dröge <a href="mailto:sebastian.droege@collabora.co.uk" target="_blank"><sebastian.droege@collabora.co.uk></a>
v4l2 is no public API on Android and not available on many
devices.
You can get the MPEG4 encoder when listing the ffmpeg plugin
in your
Android.mk
I have tried to follow your suggestion regarding fffenc_mpeg4 and I
have created the Android.mk below but, when I compile with ndk-build I
obtain the error below.
I have seen that for every plugin available a related library exists
with name libgst$(plugin_name).a in directory
$(GST_ANDROID_ROOT)/lib/gstreamer-0.10/static but, for ffenc_mpeg4, it
doesn't exist and it seems that it was not compiled.
Am I wrong somewhere?
</pre>
</blockquote>
<pre>The plugin is just called "ffmpeg"
</pre>
<blockquote type="cite">
<pre>Regarding vrl2src does exist another plugin to read frames from an
Android camera device?</pre>
</blockquote>
</blockquote>
<br>
<br></div></div>
you can read raw frames using android java api and send them to
gstreamer pipelines using appsrc,<br>
<br>
Nicola<br>
<br>
<br>
<blockquote type="cite"><div class="im">
<blockquote type="cite">
<pre></pre>
</blockquote>
<pre>Not yet, but it would be possible to create something around the Android
camera Java API.
</pre>
<br>
<fieldset></fieldset>
<br>
</div><pre>_______________________________________________
gstreamer-android mailing list
<a href="mailto:gstreamer-android@lists.freedesktop.org" target="_blank">gstreamer-android@lists.freedesktop.org</a>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-android" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-android</a>
</pre>
</blockquote>
<br>
</div>
<br>_______________________________________________<br>
gstreamer-android mailing list<br>
<a href="mailto:gstreamer-android@lists.freedesktop.org">gstreamer-android@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-android" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-android</a><br>
<br></blockquote></div><br></div>