Nitrogen 6X -- large streaming delay.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Nitrogen 6X -- large streaming delay.

781 Views
cristianpandele
Contributor II

Dear all,

After getting valuable support from you, I managed to get the platform up and running and it performs encoding quite nicely.

However, one of the requirements we have is that we can achieve a 200-300ms latency in streaming from the board over the network. I am currently experiencing latencies of 2-3 seconds in my LAN setup.

The setup, in short:

Nitrogen 6x Quad on Ubuntu Trusty --> rtph264pay --> wired LAN --> Windows PC running VLC

on the sender, I run:

gst-launch-0.10 -e imxv4l2src do-timestamp=true device=/dev/video1 capture-mode=5 ! vpuenc codec=6 ! rtph264pay config-interval=1 ! udpsink host=192.168.0.153 port=9078 sync=false

on the receiver, I use the following SDP file:

v=0

o=- 1208520720 2590316915 IN IP4 <PC's IP>

c=IN <PC's IP>

s=ESP H264 STREAM

m=video 9078 RTP/AVP 96

a=rtpmap:96 H264/90000

//I took the sprop parameters from running gst-launch with -v

a=fmtp:96 media=video; clock-rate=90000; encoding-name=H264; sprop-parameter-sets=Z0JAKKaAeAIn5UAA,aM44gAA==

a=control:trackID=1

a=ssrc:3632397957

If I output the camera feed directly to the screen, there is no noticeable latency, so the latency should come from either the encoding, or the rtph264 layer. If I ping between the two machines, the latency is under 1ms.

Any suggestions would be highly appreciated!

Kindest regards,

Cristian Pandele

Labels (2)
0 Kudos
3 Replies

497 Views
Yuri
NXP Employee
NXP Employee

Hello,

   Please check Your Gstreamer pipeline, what elements have latency property in order

to configure them for low-latency mode.


Have a great day,
Yuri

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

497 Views
cristianpandele
Contributor II

Hi Yuri,

Thank you for your message. As far as I read before posting the question, there is not much in the way of low latency settings for the pipeline elements. Could anyone shed some light on possible parameters to set? And yes, vpuenc is required for our needs.

However, I managed to cut down a lot of latency by playing with VLC's settings, now we get around 500ms, still a bit far from 200-300ms, but definitely closer.

I welcome any suggestions regarding this issue.

Kindest regards,

Cristian Pandele

0 Kudos

497 Views
Yuri
NXP Employee
NXP Employee

Hello,

According to the following from Community “Q&A: How is VPU Latency on i.MX6”,

VPU delay depends on the following factors : num_reorder_frames, max_dec_frame_buffering,

num_ref_frames, MaxDpbSize, etc. So, the customer can try to play with these parameters to find 

the best solution.

Q&amp;A: How is VPU Latency on i.MX6

Regards,

Yuri.

0 Kudos