View Full Version : MKV with VFR to AVI with CFR


PeaceMasta
29th September 2005, 17:54
Hi there. I've been working myself through a couple of guides and stuff about this problem (http://www.avisynth.org/VariableFrameRateVideo), but I've come to no solution either because I wasn't able to follow the guide or because none of the guides really treated my problem/idea of solving the problem:

I have a video with VFR MPEG4 (DivX 5.xx) and AAC MP4A content in a MKV-container. The problem is that my StandAlone-DivX player does neither support MKV nor AAC. So first I just changed the container of the video to AVI (VirtualDub[Mod]), encoded the sound to AC3 (Graphedit via ffdshow) and muxed them together (VirtualDub[Mod]). Then I had the problem that when i tried to play that video on my SAP, the sound went out of sync. After a little research i discovered, that those animated videos are often encoded in VFR to safe space. Well either that avi-container(crap) does not support VFR or my SAP does not. Now I have read a couple of guides about changing MPEG2-hybrid stuff to CFR avi stuff and so, but all of these guides either needed a re-encode or those guides treated videos where the source was MPEG2 or where the result was wanted to be VFR whereas the source was CFR.

I would love to know if its possible to just duplicate the frames that need to be duplicated to make the VFR to a CFR without reencoding the video.

Thanks for any kind of help.

//edit: I also tried to follow this thread :
http://forum.doom9.org/showthread.php?t=89294&highlight=vfr+cfr

But when i use the script
LoadPlugin("C:\Programme\AviSynth 2.5\plugins\FDecimate.dll")
Source=AviSource("VideoVFR.avi")
videoA=source.Trim(0,2247).AssumeFPS(23.9761).ChangeFPS(119.88)
videoB=source.Trim(2248,2547).AssumeFPS(29.9700).ChangeFPS(119.88)
videoC=source.Trim(2548,3099).AssumeFPS(23.9760).ChangeFPS(119.88)
videoD=source.Trim(3100,3264).AssumeFPS(29.9728).ChangeFPS(119.88)
videoE=source.Trim(3265,3284).AssumeFPS(23.9521).ChangeFPS(119.88)
VideoF=source.Trim(3285,3454).AssumeFPS(29.9718).ChangeFPS(119.88)
videoG=source.Trim(3455,3474).AssumeFPS(23.9808).ChangeFPS(119.88)
videoH=source.Trim(3475,3504).AssumeFPS(29.9700).ChangeFPS(119.88)
....
Video0=VideoA+videoB+videoC+VideoD+VideoE+VideoF+VideoG+VideoH+VideoI+VideoJ+VideoK+VideoL+VideoM+VideoN+VideoO+VideoP+VideoQ+VideoR+VideoS+VideoT+VideoU+VideoV+VideoW+VideoX+VideoY+VideoZ
Video1=VideoA1+videoB1+videoC1+VideoD1+VideoE1+VideoF1+VideoG1+VideoH1+VideoI1+VideoJ1+VideoK1+VideoL1+VideoM1+VideoN1+VideoO1+VideoP1+VideoQ1+VideoR1+VideoS1+VideoT1+VideoU1+VideoV1+VideoW1+VideoX1+VideoY1+VideoZ1
Video2=VideoA2+videoB2+videoC2+VideoD2+VideoE2+VideoF2+VideoG2+VideoH2+VideoI2+VideoJ2+VideoK2+VideoL2+VideoM2+VideoN2+VideoO2+VideoP2+VideoQ2+VideoR2+VideoS2+VideoT2+VideoU2+VideoV2+VideoW2+VideoX2+VideoY2+VideoZ2
Video3=VideoA3+videoB3+videoC3+VideoD3+VideoE3+VideoF3+VideoG3+VideoH3+VideoI3+VideoJ3+VideoK3+VideoL3+VideoM3+VideoN3+VideoO3+VideoP3+VideoQ3+VideoR3+VideoS3+VideoT3+VideoU3+VideoV3+VideoW3+VideoX3+VideoY3+VideoZ3
Video4=VideoA4+videoB4+videoC4+VideoD4+VideoE4+VideoF4+VideoG4+VideoH4+VideoI4+VideoJ4+VideoK4+VideoL4+VideoM4+VideoN4+VideoO4+VideoP4+VideoQ4+VideoR4+VideoS4+VideoT4+VideoU4+VideoV4+VideoW4+VideoX4+VideoY4+VideoZ4
Video5=VideoA5+videoB5+videoC5+VideoD5+VideoE5+VideoF5+VideoG5+VideoH5+VideoI5+VideoJ5+VideoK5+VideoL5+VideoM5+VideoN5+VideoO5+VideoP5+VideoQ5+VideoR5+VideoS5+VideoT5+VideoU5+VideoV5+VideoW5+VideoX5+VideoY5+VideoZ5 Video6=VideoA6+videoB6+videoC6
Video1+video2+video3+Video4+Video5+Video6
FDecimate(23.976)
and encode it to something like huffyuv, all i get is a green screen.

multicone
29th September 2005, 19:15
You are trying to pack a AMD64 CPU into an old socket A motherboard, to allow using your old 2 MB video card with modern software ? Good luck .....

Wilbert
29th September 2005, 21:18
http://www.avisynth.org/VariableFrameRateVideo#enc-cfr-non_mpeg2


DirectShowSource("F:\Guides\Hybrid\vfr_startrek.mkv", fps=119.88, convertfps=true)
FDecimate(29.97) # or FDecimate(23.976)

PeaceMasta
30th September 2005, 11:32
Ok Thanks. Thatone works quite well. With reencoding it :/