Page 1 of 1

New tool to change Level in H264 bitstream

PostPosted: Wed Jan 05, 2011 1:54 pm
by Illico
I found these projects from roozhou, the modified(patch) ffmpeg can easily change the h264 level in the same step.
http://forum.doom9.org/showthread.php?t=152419

I download this modified ffmpeg.
and try this following command line to change AVC High@L4.0 to High@L3.0
C:\Serviio\lib\ffmpeg.exe -i BigBuckBunny-DivXPlusHD.mkv -vcodec copy -acodec copy -vbsf h264_changesps=level=30 BigBuckBunny-DivXPlusHD_HL30.mkv

Zip do you think this option could be included in serviio ffmpeg to change H264/AVC profile Level for device like Sony TV/Bluray that only supported <4.1 level?

Re: New tool to change Level in H264 bitstream

PostPosted: Wed Jan 05, 2011 2:12 pm
by zip
Will have a look. The difficult bit is to find out what level the file is, so that we can match it in transcoding config

Re: New tool to change Level in H264 bitstream

PostPosted: Mon Jan 10, 2011 7:06 am
by Zek
This is what I use instead. It patches the level on a 264 bitstream or a Matroska container with the bitstream. It works in many cases where the level was set too high in the first place. However there are other bitstream factors such as reference frame count that may fail the file even if you lower the level. It worked for most of my old L5.1 MKV files, especially the 720p variety, and they now play on my Bravia fine.
http://coolsoft.altervista.org/en/h264leveleditor

Pretty much instant on 10Gb+ videos.

Cheers,
Zek

Re: New tool to change Level in H264 bitstream

PostPosted: Mon Jan 10, 2011 7:34 am
by Zek
I forgot to say that there is another method to fix unplayable files that I use. This will get the file playing on my Bravia 95% of the time but it may have artifacts if the device can't handle the high level features. The demux/remux takes a few minutes for a multi gigabyte file but does no transcoding.

1. Demux the file using tsMuxeR_1.10.6 and keep the window open. You can change level here too and be sure to keep "Add timing info" and "Insert SPS/PPS"
2. Remux the streams using mkvtoolnix's mmg.exe into a Matroska container. Be sure to set the FPS manually here by reading what tsMuxeR reported.
3. Profit.

Cheers,
Zek