logo

Could not compile stylesheet for simplistic. Using last compiled stylesheet.
Issue
2010016A
2010016A
Offline
0
Hi there,
We are trying to stream a video from an analog camera connected on the expansion board of an IGEPV2 to an android tab.
The poky distribution is installed on the IGEPV2.

We managed to send the video from the IGEPV2 board with the following pipeline :
gst-launch-0.10 v4l2src device=/dev/video4 queue-size=1 ! video/x-raw-yuv,format=\(fourcc\)UYVY,width=720,height=576,framerate=\(fraction\)25/1 ! ffmpegcolorspace ! TIVidenc1 codecName=h264enc engineName=codecServer ! rtph264pay ! udpsink host=192.168.11.12 port=1234


But the following pipeline on the android app did not display anything :
gst-launch-0.10  udpsrc port=1234 ! "application/x-rtp, media=video, clock-rate=90000, encoding-name=H264, sprop-parameter-sets=\\\"Z0KAH4toC0EkQA\\\\=\\\\=\\\\,aM4BqHcg\\\ ! gstrtpjitterbuffer ! rtph264depay ! ffdec_h264 ! ffdeinterlace ! eglglessink sync=false


Although, we managed to receive it on a PC with :
gst-launch-0.10 udpsrc port=1234 ! "application/x-rtp, payload=127" ! rtph264depay ! ffdec_h264 ! xvimagesink sync=false



The most surprising is that if we put the PC as a relay between the IGEPV2 and the android app, it works well : the PC receives the video and send it to the android device, and the android device displays it :
On the PC :
gst-launch-0.10 udpsrc port=1234 ! "application/x-rtp, payload=127" ! rtph264depay ! ffdec_h264 ! 'video/x-raw-yuv,width=720,height=576' !  x264enc pass=qual quantizer=20 tune=zerolatency ! rtph264pay ! udpsink host=192.168.11.12 port=1234


In the same way, the android device manage with the same pipeline to display the PC's webcam video :
on the PC :
gst-launch-0.10 v4l2src device=/dev/video0 ! 'video/x-raw-yuv,width=640,height=480' !  x264enc pass=qual quantizer=20 tune=zerolatency ! rtph264pay ! udpsink host=192.168.11.12 port=1234


It is just as if the android device was not able to decode the video encoded with the TIVidenc.
Any idea on how we can solve this issue ?

Vincent
Responses (7)
  • Accepted Answer

    mcaro
    mcaro
    Offline
    Saturday, March 01 2014, 02:03 PM - #permalink
    0
    Hi Vincent,

    why you're using ffdeinterlace in your android device?

    Manel
    The reply is currently minimized Show
  • Accepted Answer

    2010016A
    2010016A
    Offline
    Tuesday, March 04 2014, 05:10 PM - #permalink
    0
    Hi Manel,
    We are using ffdeinterlace in the android device to make a "smoother" video image. If we do not use it, we have an interlacing effect that is not confortable.
    As our camera is fixed on a moving device, it is important for us.
    To go further, we did not succeed in deinterlacing "easily" directly in the IGEP board, so we prefer to the deinterlace in the client system.

    The deinterlacing do not seem to be responsible of our current problem, as it works well when the video comes from the PC.

    Do you have an idea, or a suggestion to advise us ?
    Vincent
    The reply is currently minimized Show
  • Accepted Answer

    mcaro
    mcaro
    Offline
    Tuesday, March 04 2014, 05:52 PM - #permalink
    0
    Hi Vincent,

    I've two suggestions:

    a) Check the tune options for TIVidenc1 using the command: get-inspect TIVidenc1
    b) In the android device save the h264 stream to any file and check if you receive the data ...

    Manel
    The reply is currently minimized Show
  • Accepted Answer

    2010016A
    2010016A
    Offline
    Wednesday, March 05 2014, 11:12 AM - #permalink
    0
    Hi Manel,
    the result of the gst-inspect command :
    Factory Details:
      Long name:	TI xDM 1.x Video Encoder
      Class:	Codec/Encoder/Video
      Description:	Encodes video using an xDM 1.x-based codec
      Author(s):	Brijesh Singh; Texas Instruments, Inc.
      Rank:		primary (256)
    
    Plugin Details:
      Name:			TICodecPlugin
      Description:		Plugin for TI xDM-Based Codecs
      Filename:		/usr/lib/gstreamer-0.10/libgstticodecplugin.so
      Version:		0.10.0.1
      License:		unknown
      Source module:	gstticodecplugin
      Binary package:	TI
      Origin URL:		http://www.ti.com/
    
    GObject
     +----GstObject
           +----GstElement
                 +----GstTIVidenc1
    
    Pad Templates:
      SRC template: 'src'
        Availability: Always
        Capabilities:
          video/mpeg
                mpegversion: { 2, 4 }
               systemstream: false
                  framerate: [ 0/1, 2147483647/1 ]
                      width: [ 1, 2147483647 ]
                     height: [ 1, 2147483647 ]
          video/x-h264
                  framerate: [ 0/1, 2147483647/1 ]
                      width: [ 1, 2147483647 ]
                     height: [ 1, 2147483647 ]
    
      SINK template: 'sink'
        Availability: Always
        Capabilities:
          video/x-raw-yuv
                     format: UYVY
                      width: [ 1, 2147483647 ]
                     height: [ 1, 2147483647 ]
                  framerate: [ 0/1, 2147483647/1 ]
    
    
    Element Flags:
      no flags set
    
    Element Implementation:
      Has change_state() function: 0x405109a0
      Has custom save_thyself() function: gst_element_save_thyself
      Has custom restore_thyself() function: gst_element_restore_thyself
    
    Element has no clocking capabilities.
    Element has no indexing capabilities.
    Element has no URI handling capabilities.
    
    Pads:
      SRC: 'src'
        Implementation:
          Has custom eventfunc(): gst_pad_event_default
          Has custom queryfunc(): gst_pad_query_default
          Has custom iterintlinkfunc(): gst_pad_iterate_internal_links_default
          Has acceptcapsfunc(): gst_pad_acceptcaps_default
        Pad Template: 'src'
      SINK: 'sink'
        Implementation:
          Has chainfunc(): gst_tividenc1_chain
          Has custom eventfunc(): gst_tividenc1_sink_event
          Has custom queryfunc(): gst_pad_query_default
          Has custom iterintlinkfunc(): gst_pad_iterate_internal_links_default
          Has setcapsfunc(): gst_tividenc1_set_sink_caps
          Has acceptcapsfunc(): gst_pad_acceptcaps_default
        Pad Template: 'sink'
    
    Element Properties:
      name                : The name of the object
                            flags: readable, writable
                            String. Default: "tividenc10"
      engineName          : Engine name used by Codec Engine
                            flags: readable, writable
                            String. Default: null
      codecName           : Name of video codec
                            flags: readable, writable
                            String. Default: null
      resolution          : Input resolution for the input video ('width''x''height')
                            flags: readable, writable
                            String. Default: null
      bitRate             : Set the video encoder bit rate
                            flags: readable, writable
                            Integer. Range: 1 - 2147483647 Default: 2000000 
      iColorSpace         : Input color space (UYVY, Y8C8, NV16 or NV12)
                            flags: readable, writable
                            String. Default: "UYVY"
      framerate           : Frame rate of the video expressed as a fraction.  A value of 0/1 indicates the framerate is not specified
                            flags: readable, writable
                            Fraction. Range: 0/1 - 2147483647/1 Default: 30000/1001 
      contiguousInputFrame: Set this if elemenet recieved contiguous input frame
                            flags: readable, writable
                            Boolean. Default: false
      genTimeStamps       : Set timestamps on output buffers
                            flags: readable, writable
                            Boolean. Default: true
      rateControlPreset   : Bit rate control
    			1 - No rate control
    			2 - Constant bit rate (CBR)
    			3 - Variable bit rate (VBR)
                            flags: readable, writable
                            Integer. Range: 1 - 2147483647 Default: 1 
      encodingPreset      : Algorithm specific creation time parameters
    			1 - Use codec default
    			2 - High quality
    			3 - High speed
                            flags: readable, writable
                            Integer. Range: 1 - 2147483647 Default: 1 
      byteStream          : Generate byte stream format of NALU
                            flags: readable, writable
                            Boolean. Default: false
    


    I do not see anything weird. Do you ?

    I will check the storage in a file on the android device quickly.

    Thanks
    Vincent
    The reply is currently minimized Show
  • Accepted Answer

    mcaro
    mcaro
    Offline
    Thursday, March 06 2014, 06:20 PM - #permalink
    0
    Hi Vincent,

    You should setup your video encoder to be compatible with your video decoder in the android device so, normally it should be done using:


    resolution
    bitRate
    rateControlPreset
    encodingPreset


    And byteStream

    So not all h264 profiles be the same in this case the codec uses H.264 BP Encode/Decode (up to 720P) where the important info is the Base line profile, it means that your decoder must use this profile too, in the other side you should check if the decoder is capable to use CBR or VBR and the right bitrate.

    Looking your encoding pipe I saw you're using:

    video/x-raw-yuv,format=\(fourcc\)UYVY,width=720,height=576,framerate=\(fraction\)25/1

    But if you use UYVY, Why you're using ffmpegcolorspace?

    I hope it help you ...

    Manel
    The reply is currently minimized Show
  • Accepted Answer

    2010016A
    2010016A
    Offline
    Friday, March 07 2014, 06:28 PM - #permalink
    0
    Hi Manel,
    Remove the ffmpegcolorspace did not solve the problem.
    And it seems that the decoder is correctly setup... Every element is the same as in the encoder.

    We tried to use theora instead of Tividenc, and it works... We received the video on the android app, but there is a too important latency (due to the encoding performance) for our application.

    The problem seems definetly to come from the decoder
    The reply is currently minimized Show
  • Accepted Answer

    mcaro
    mcaro
    Offline
    Friday, March 07 2014, 06:35 PM - #permalink
    0
    You can try to encode with mpeg4 ...

    or check your h264 decoder properties ... you can check the setup PC <-> Android and check in the PC the h264 default encoding (if I remember it works) and then use the same with IGEPv2 ...

    Manel
    The reply is currently minimized Show
Your Reply

SUPPORT


This email address is being protected from spambots. You need JavaScript enabled to view it.
This email address is being protected from spambots. You need JavaScript enabled to view it.
IGEP Community Wiki
IGEP Community Forum
IGEP Community Online Chat