Distortion in output stream

I meant sample vidoes inside deepstream default folder at this location:

These video files were installed with deepstream
I am playing from the deepstream server (hosted locally in LAN) using this URL:


I meant 1. if set type to 3 in sink, deepstream-app will generate new file, does this new file play well ?
2. on the machine which run deepstram-app, does it play well using rtsp:://


1- when I save locally to file with sink type3 - it plays well no distortion in out.mp4
2- I am running on headless server therefore can’t display or play the rtsp locally on the server

it seems the distortion is happening when we output the RTSP stream, there is no network issue that might cause this because my PC is only 20 cm away of the headless redhat server (with deepstream), latency < 1 ms

rtsp_server is Gstreamer opensource module, it should be ok, To narrow down this issue,

  1. you can use ffmpeg -i rtsp://xxx -c copy 1.h264 or ffmpeg -i rtsp://xxx -c copy 1.mp4 to save data on the machine which runs deepstream-app.
  2. you can capture network packets on both sides to analyze.
  3. please check if “udp-port=5500” is using by other processes.

1- ffmpeg is recording a file which plays fine without any distortions, it just plays a little faster than normal (3x-4x speed), can we conclude that the problem is in the VLC player?
2- there are no network drops on both sides (my player and the deepstream server which is installed on a PC next to my desk).
3- ONLY deepstream is using port 5500

while playing the stream directly from the camera, VLC plays it well without issues, problem only occurs when playing the deepstream rtsp output stream.
Updating and reinstalling VLC didnt solve the problem
I tried disabling hardware / decoding acceleration in VLC but didnt work

[quote=“ali35, post:19, topic:235775”]
ffmpeg is recording a file which plays fine without any distortions.
from your test result, recording from RTSPStreaming server is ok, the network is ok, the issue should be VLC player.
you can try other players such as ffmpeg’s ffplay to play on the machine runningVLC.


1- can u share the command to run ffplay on deepstream server?
2- why is the recorded file (using ffmpeg )shows a video playing very fast? it seems like it was recorded with 3x-4x speed? i have not changed anything in the default configuration that i uploaded here

  1. ffplay rtsp://xxx
  2. we still suggest to capture network packets on both sides to check if the player side receive the whole packets, we can’t get this information only from ping value.

@fanzh while trying ffplay rtsp://localhost:8660/ds-test
i am getting this error:

(base) [appusr@wk-10662 ~]$ ffplay rtsp://localhost:8660/ds-test
ffplay version 4.2.8 Copyright (c) 2003-2022 the FFmpeg developers
built with gcc 8 (GCC)
configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --docdir=/usr/share/doc/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags=‘-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection’ --extra-ldflags=‘-Wl,-z,relro -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld ’ --extra-cflags=’ ’ --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libvo-amrwbenc --enable-version3 --enable-bzlib --disable-crystalhd --enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls --enable-ladspa --enable-libaom --enable-libdav1d --enable-libass --enable-libbluray --enable-libcdio --enable-libdrm --enable-libjack --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libmp3lame --enable-nvenc --enable-openal --enable-opencl --enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librsvg --enable-libsrt --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libvidstab --enable-libvmaf --enable-version3 --enable-vapoursynth --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-libzimg --enable-libzvbi --enable-avfilter --enable-avresample --enable-libmodplug --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-libmfx --enable-runtime-cpudetect
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libavresample 4. 0. 0 / 4. 0. 0
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
X Error of failed request: GLXBadDrawable
Major opcode of failed request: 146 (GLX)
Minor opcode of failed request: 29 (X_GLXGetDrawableAttributes)
Serial number of failed request: 95
Current serial number in output stream: 95

why did you use “localhost:8660”? from the error “X Error of failed request: GLXBadDrawable”, ffplay created display failed.

@fanzh i used localhost because i am trying to play the stream on the same BOX that has deepstream running.
I tried to use the ip instead but got the same error, what could be wrong?

if your box is a headless server, please use ffplay on the machine where your play vlc.

@yingliu we changed that, we are exporting the display from headless server through XTERM
in this case, the terminal can display the output in a seperate window, see screenshot

the machine which i use to play VLC is a windows machine so ffplay isnt installed, is there a windows version of ffplay?
Running ffplay from a remote VNC connection on the deepstream server is giving the below error:

please goggle windows ffplay.


Playing using ffplay on my windows machine still shows distorted images:

Recording using ffmpeg on my windows machine shows similar distorted images:

Running ffplay on the deepstream server (finally was able to run it using a direct VNC connection), shows clear image without distortion:

Pulling my hair out, can this be a network issue? tracing network is going to be painful.

playing on the server is good, playing on the remote machine is bad, it should be network issue, you can do network capturing by Wireshark.

@fanzh i confirm that the issue stands with my own windows machine, playing stream on another windows machine on the same network did not cause any rendering issue.

I am now facing another problem so i opened another thread here
Appreciate your help


Glad to know you fixed it, thanks for the update! If have a new problem, please open a new topic. Thanks

@fanzh appreciate if you help with my new issue here

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.