DivxBr
21st February 2010, 15:24
Hi,
I was thinking, about how to make a kind of "smart rendering" (like virtualdub does for avi) for h264 streams.
So I made a few tests, reencoding part of the content of a mkv file, cutting out old part and re-appending (to original frame sequence - of course, cutting - with mkvmerge - on IDR boundaries).
The problem I found, is that the mkvmerge, when I try to re-append stream parts, shows an error message saying that the private codec's data does not match.
So I used MediaInfo tool to extract encoding parameters from original file, to use them in encoding process:
- Mkv merge still shows different private codec's data;
- The file plays ok with ffdshow, but freezes on re-encoded part (few frames) in MPC-HC (dxva mode);
So my question is: Which part of the info in the original file I have to use (and how to extract it) to reencode for generating a compatible stream so I can append the original & reencoded parts without glitches?
:thanks:
Edit: And by the way, I'm using x264 for encoding.
I was thinking, about how to make a kind of "smart rendering" (like virtualdub does for avi) for h264 streams.
So I made a few tests, reencoding part of the content of a mkv file, cutting out old part and re-appending (to original frame sequence - of course, cutting - with mkvmerge - on IDR boundaries).
The problem I found, is that the mkvmerge, when I try to re-append stream parts, shows an error message saying that the private codec's data does not match.
So I used MediaInfo tool to extract encoding parameters from original file, to use them in encoding process:
- Mkv merge still shows different private codec's data;
- The file plays ok with ffdshow, but freezes on re-encoded part (few frames) in MPC-HC (dxva mode);
So my question is: Which part of the info in the original file I have to use (and how to extract it) to reencode for generating a compatible stream so I can append the original & reencoded parts without glitches?
:thanks:
Edit: And by the way, I'm using x264 for encoding.