Page 1 of 1

Transcoding and streaming live 1080i/720p feed.

Posted: 22 Aug 2012 09:39
by sambir
Hi guys,

I want to live stream a 1080i satellite live feed. So basically i want to transcode this feed and stream it in h264 (since this is the format which gives the best streaming results). With my current hardware (amd quad core) i am not able to stream in h264 with 1280x720 resolution. It just chokes the cpu...My question to you guys is...Do i need to upgrade the server hardware or is there a workaround?

If i need to upgrade:
* What hardware do you suggest (cheap as possible)
* Is there any dedicated transcoding accelerator or some sort which works with VLC?

Software wise:
* (maybe not the place to ask this question) Is there any other transcoding/streaming software which does not choke out the cpu at these resolutions?
* Is there any other codec you suggest i should use, eventough i already tried this and it resulted in either bad pixelisation or lag/stuttering i'm still curious to know your suggestions...

By the way, I even tried transcoding the feed with my own intel quad q6600 @ 3.4Ghz and even with this cpu it resulted in almost 100% utilization.

More or less i plan to use this code to transcode the feed (some tweaks like resolution settings and deinterlacing still needs to be added):
vlc.exe -vvv --no-crashdump --sout-x264-ref=4 --sout-x264-bpyramid=none "http://IP" --repeat --sout #transcode{vcodec=h264,vb=4000,scale=1,acodec=aac,ab=128,threads=4,channels=2,audio-sync,samplerate=48000}:http{mux=ts,dst=:PORT/} :no-sout-rtp-sap :no-sout-standard-sap :sout-all :ttl=1 :sout-keep"

Any help would be appreciated...Thank you in advance :)

Re: Transcoding and streaming live 1080i/720p feed.

Posted: 23 Aug 2012 12:27
by sambir
I have just ordered an AMD Phenom II X6 1045T. This cpu will replace my AMD Phenom X4 810. I hope this cpu will be able to transcode the feed... :) By the way the ram on the server is 2x2gb DDR2 PC6400 800MHZ. Will faster ram result in less load on the cpu or is H264 transcoding purely cpu based?

For instance if i would replace the board by a ddr3 board with 4gb of ram at 1400mhz or so will this result in less cpu load?

Re: Transcoding and streaming live 1080i/720p feed.

Posted: 23 Aug 2012 14:06
by Lotesdelere
is H264 transcoding purely cpu based?
Yes it is. x264 is the best H.264 encoder around but it's a software encoder only and it will always try to use as many CPU ressources as available.

Re: Transcoding and streaming live 1080i/720p feed.

Posted: 23 Aug 2012 15:07
by sambir
is H264 transcoding purely cpu based?
Yes it is. x264 is the best H.264 encoder around but it's a software encoder only and it will always try to use as many CPU ressources as available.
Ok but could the RAM speed or capacity affect transcoding performance? Or would for instance upgrading to 1333mhz ram result in just minor performance gains?

Re: Transcoding and streaming live 1080i/720p feed.

Posted: 24 Aug 2012 09:12
by Lotesdelere
A bit but the best gains will be given by a fast CPU. The faster the CPU, the faster the encoding.

Re: Transcoding and streaming live 1080i/720p feed.

Posted: 25 Aug 2012 16:30
by sambir
So i upgraded my hardware and YESS the load is just 50% on a hexacore but now i have a different issue...the stream works fine for a while but then all of a sudden vlc just crashes or stops transcoding. this is my line:

Code: Select all

vlc.exe -vvv dshow:// :dshow-aspect-ratio=16:9 :dshow-vdev="7160 (HDMI) HD Capture (0)" :dshow-adev="Lijningang (VIA High Definition" --repeat --sout #transcode{vcodec=h264,vb=2000,scale=1,width=1280,height=720,acodec=aac,ab=128,threads=4,channels=2,audio-sync,samplerate=48000}:http{mux=ts,dst=:32322/} :no-sout-rtp-sap :no-sout-standard-sap :sout-all :ttl=1 :sout-keep"

Re: Transcoding and streaming live 1080i/720p feed.

Posted: 25 Aug 2012 18:11
by sambir
modified the line a bit this line seems to work better.

Code: Select all

vlc.exe -vvv dshow:// :dshow-aspect-ratio=16:9 :dshow-vdev="7160 (HDMI) HD Capture (0)" :dshow-adev="Lijningang (VIA High Definition" --sout #transcode{vcodec=h264,vb=4000,width=1280,height=720,acodec=aac,ab=128,threads=6,channels=2,samplerate=48000}:http{mux=ts,dst=:33232/} :no-sout-rtp-sap :no-sout-standard-sap :sout-all :ttl=1 :sout-keep"
and the load is not stable but i already expected this. When the camera is moving fast or recording crowded placed the load goes up to 80 90%

Re: Transcoding and streaming live 1080i/720p feed.

Posted: 25 Aug 2012 22:22
by dazzaa
try using vlc 2.0.4
also if your source is interlaced, add deinterlace into the mix for a better stream, i use bob or linear which double the framerate to 50fps
could try unparking the cpu cores
or try these drivers if u have an nvidia card http://forums.laptopvideo2go.com/topic/ ... s-support/
vlc runs well with them :)

Re: Transcoding and streaming live 1080i/720p feed.

Posted: 27 Aug 2012 09:20
by sambir
No i have an ATI HD5450 card in de system. The stream was crashing because of audio-sync being in the command line. Now it worked perfectly for 2 days in a row...

I added deinterlacing but did not add what type of deinterlacing do you know what it selects by default? Wont bob affect performance or framerates on tv? Also 50fps is not realistic in my opinion...

Also the bitrate is fluctuating to much i want to limit it actually.. i changed the bitrate to vb=3000 but sometimes it just goes up to 4000 5000 kbit

My only issue at the moment is the pc hanging sometimes out of nothing resulting in unreachability by RDP. The only solution is to hardreset the pc...but that is not possible remotely so at the moment im looking for a Relay or some sort which works with my phone and is able to hardreset the pc :)