Log in

View Full Version : Frame accurate source filter for H.264 in MKV?


`Orum
1st January 2016, 08:56
I'm looking for a frame accurate (handing the output to Trim()) source filter for AviSynth+ x64, and I've tried several, but none seem to actually work. Source material is a BD H.264 stream remuxed into a MKV container, via eac3to. Here's the two I've tried so far:

FFMpegSource2 - This claims it's frame accurate with MKV containers. But, even with seekmode = 1 (the default), reopening an unchanged script and seeking to the same frame number often produces different results.
DSS2mod - This is actually a lot more reliable at hitting the same frame than FFMS2, but still isn't 100% on frame seeking. Occasionally the frame seeking will still be a frame or two off from previous openings of the same file.

So are there any other options? I've tried a few other source filters, but have yet to actually get any of them to even decode the video in the first place, let alone seek in it.

feisty2
1st January 2016, 09:01
lsmash
dgdecode

`Orum
1st January 2016, 09:29
lsmash
dgdecode

I tried LSMASHVideoSource, but it dies with the strange error: "Failed to read an input file" (despite leaving the string for the file name, which is the only parameter I'm passing it, unchanged from all the various other source filters I've used)

And as for DGDecode... isn't that only for MPEG-2? EDIT: Ah, I guess you were referring to DGAVCDecode? Unfortunately, as far as I'm aware, that's 32-bit only.

feisty2
1st January 2016, 09:32
And as for DGDecode... isn't that only for MPEG-2?

dgmpeg
dgim
dgnv
dgavc..

vivan
1st January 2016, 09:54
I tried LSMASHVideoSource, but it dies with the strange error: "Failed to read an input file" (despite leaving the string for the file name, which is the only parameter I'm passing it, unchanged from all the various other source filters I've used)LSMASHVideoSource is for mp4/mov, LWLibavVideoSource is for everything.

`Orum
1st January 2016, 09:57
Ah, yeah, DG's current decoder requires a NVIDIA card, which would be a problem. Anyway, I looked more closely at the LSMASH source filter, and realized I'm using the wrong function--LSMASHVideoSource() instead of LWLibavVideoSource(). Edit: vivan beat me to it!

Mea culpa. I think this is frame accurate based on my testing so far. I'm going to run a few more tests but assuming there are no issues I'll just stick with this. Thanks!

foxyshadis
1st January 2016, 12:00
You can also usually fix frame accuracy problems by remuxing with mkvmerge, but... that's a fair bit of drive thrashing for 10GB+ files.