Tutorial 2 TCP audio

vincent vinny_vis at hotmail.com
Tue Apr 18 13:15:45 UTC 2017


Hi,

Im trying to get a working pipeline to receive audio. 
It works perfectly with gst-launch:

Windows 
gst-launch tcpclientsrc host=192.168.73.103 port=3001 ! "audio/x-mulaw,
channels=2, depth=16, width=16, rate=44100" ! mulawdec ! audioconvert !
autoaudiosink

and

Linux
gst-lauch audiotestsrc freq=1000 ! mulawenc ! tcpserversink port=3001

Now i want to build a app to receive the audio on an android device.
I followed a few tutorials
https://gstreamer.freedesktop.org/documentation/tutorials/android/index.html
and i am using the command line for building and deploying.

For building i using an older version of NDK (android-ndk-r9d) to prevent
building problems with -fuse-ld=gold. I am also using the latest android sdk
(1.11.90) and the tutorials from GIT. (latest)

The tutorials are working on my device without any problem.

I use tutorial 2 as starting point for the app and i changed the pipeline in
tutorial-2.c

  /* Build pipeline */
  //audiotestsrc ! audioconvert ! audioresample ! autoaudiosink
  data->pipeline = gst_parse_launch("tcpclientsrc host=192.168.73.103
port=3001 ! audio/x-mulaw, channels=1, depth=16, width=16, rate=44100 !
mulawdec ! audioconvert ! autoaudiosink", &error);

But now i get: Error received from element tcpclientsrc0: could not open
resource for reading.

I also added some plugins in android.mk

GSTREAMER_NDK_BUILD_PATH  := $(GSTREAMER_ROOT)/share/gst-android/ndk-build/
include $(GSTREAMER_NDK_BUILD_PATH)/plugins.mk
GSTREAMER_PLUGINS         := $(GSTREAMER_PLUGINS_CORE)
$(GSTREAMER_PLUGINS_PLAYBACK) $(GSTREAMER_PLUGINS_CODECS)
$(GSTREAMER_PLUGINS_NET) $(GSTREAMER_PLUGINS_SYS)
G_IO_MODULES              := gnutls
GSTREAMER_EXTRA_DEPS      := gstreamer-video-1.0
include $(GSTREAMER_NDK_BUILD_PATH)/gstreamer-1.0.mk

I have searched on the Internet but couldn't/can't find the answer

I am new to GStreamer and any help would be appreciated! 



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Tutorial-2-TCP-audio-tp4682714.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list