View Full Version : NTSC DVD (29.97 + 23.976fps w/ 3:2 pd) to 25fps x264
Metal-HTPC
26th February 2019, 08:58
hello,
since this looks like the ultimate forum when it comes to Avisynth scripts I'm wondering what you guys would suggest me for the following project:
I want to encode a MPEG2 NTSC DVD with short episodes (each episode has an intro) to MPEG4 (x264) with 25fps.
The intro of each episode is in 29.97 and when the episode starts it switches to telecined film (23.976 with 3:2 pulldown)
So what should I do ? To convert without visible quality loss or stuttering and without the Audio (always runs in 23.976) running out of synch?
Using a motion interpolating frame rate changer to convert the intro to 23.976, then IVTC the rest with TFM().TDecimate(). ?
MPEG2Source("E:\video.d2v")
p1 = Trim(0,2459).SmoothFPS2(24000,1001)
p2 = Trim(2460,0).TFM().TDecimate()
p1+p2
AssumeFPS(25.000)
LanczosResize(720,576)
Maybe you guys have a better idea. Thanks in advance for your help.
Sharc
26th February 2019, 19:19
My first thought was why would you want to change to PAL 25 fps? Leave it at 29.97 and encode everything as interlaced with x264, without resizing. Every player will play it.
If you absolutely need to convert:
You should definitely IVTC the (hard) telecined section and speed it up to 25fps, as you suggest, and recover the progressive original frames.
For the intro part (is it true interlaced?) you can choose your poison: Interpolation artefacts, blending, or decimate and accept some jerkyness. Don't know what looks best to you, it also depends on the source.
Perhaps someone else has a better proposal.
johnmeyer
26th February 2019, 19:42
My first thought was why would you want to change to PAL 25 fps? Leave it at 29.97 and encode everything as interlaced with x264, without resizing. Every player will play it.That would be my recommendation as well. How often will you play this, over the next ten years? Is it really worth all the effort?
Metal-HTPC
27th February 2019, 08:15
I wouldn't do it if it isn't worth it. It's one of my favorite shows so I'm definitely going to watch it every 2-3 years. I'm not shure if the intro is true interlaced. I can check that later or post a sample if I'm not shure.
The reason why I need to convert it to PAL is that I need to adjust another audio Layer to the video which runs in PAL speed and has a pal tone pitch. There is no way for me to convert the audio without losing audible quality.
If you convert it to 23,970 directly it will sound too deep and if you convert to 23,970 with a pitch correction it will sound tinny.
johnmeyer
27th February 2019, 09:16
With the proper software you should be able to do a relatively minor audio speed change, with pitch correction, and not be able to notice any artifacts whatsoever. The key is proper software. I use iZotope, which is quite expensive, but I think Audacity can also do pretty good changes. I also use my Vegas editing software with the "elastique" enabled, and cannot detect even a hint of flanging, which is what I think you are referring to when you say "tinny."
I much prefer changing audio duration, and leaving the video alone, whenever possible because, unlike what I just described for audio, it is impossible to change video speed without introducing artifacts that, at times, will be quite noticeable.
Metal-HTPC
27th February 2019, 14:54
I never noticed any artifacts on any of the commerical released PAL DVD's I know. I also own many movies as a PAL and a NTSC version and compared them. They look identical to me. With x264 I can use a much higher bitrate because I'm not limited to the DVD spec of 9000 so there shouldn't be any pixelation if the above script works good.
Back in the past I converted all my NTSC DVD's to PAL with HCencoder with the same commands "tdecimate()" or "Telecide(guide=1,blend=true) and Decimate(cycle=5,quality=3)". which are only deleting one frame in five to convert 29.97 fps to 23.976 fps and doesn't do any pulldown removals. Although some videos had stuttering in faster scenes I never noticed any pixelations or visible artifacts.
For me it's much easier to convert the video. For commerical blu-rays even more. I just change the framerate in ts muxer to 25 which is a very easy and fast speedup. I don't need to touch the audio at all and can finish my project pretty fast. I also only do this if the sound has a pal speedup tone which is only used for TV shows and a a few direct to video releases. All other versions can be easily converted with eac3to with the "25.000 -changeTo23.970" command and the video stays untouched.
Sharc
27th February 2019, 19:57
The problem with artifacts is neither PAL as such nor the x264 encoding bitrate. Nobody said this. Artifacts are introduced when you frame-rate convert the (interlaced?) introduction (your p1) from 29.97 to 25 with a "motion interpolating frame rate changer" as per your original post. Framerate changers will always introduce artifacts of some kind. Depending on the video (motion) and the interpolating algorithm they might be quite acceptable though and may not be noticed at normal playback speed on TV for example. Stuttering (as you observed) due to skipping or doubling frames is just one kind of "artifact". Some people can't stand it, other people hate blends etc. As I said when you do framerate conversion you can choose your poison.
The telecined part is not the problem. You can IVTC it to 23.976 and get perfect progressive pictures without introducing any artifacts, speed it up to 25 and add your extra (25fps) audio track, as you intend.
SeeMoreDigital
27th February 2019, 21:03
...It's one of my favorite shows so I'm definitely going to watch it every 2-3 years. What show?
hello_hello
27th February 2019, 23:24
Maybe increasing the frame rate of the intro would look better than trying to reduce it.... the idea being to increase the frame rate to 47.952fps, so the PAL speed-up takes it to 50fps. Then you could repeat every frame in the second section to make the whole thing 50fps. And myself.... I tend to resize to square pixel dimensions anyway, but if you have to resize, why not go straight to square pixels?
MPEG2Source("E:\video.d2v")
Trim(0,2459).FrameRateConverter(48000,1001).AssumeFPS(50)\
++Trim(2460,0).TFM().TDecimate().AssumeFPS(25).ChangeFPS(50)
LanczosResize(640,480) # or 720x540 or some other 4:3 dimensions
Or it wouldn't be hard to encode as variable frame rate, given there's only two different frame rates. 50fps for the intro and 25fps for the rest. The two sections must have a single frame rate in the script though, to keep Avisynth happy.
MPEG2Source("E:\video.d2v")
Trim(0,2459).FrameRateConverter(48000,1001).AssumeFPS(25).GreyScale()\
++Trim(2460,0).TFM().TDecimate().AssumeFPS(25)
LanczosResize(640,480)
I'd add GreyScale() to the first section as you'll need to check the new frame numbers after converting the frame rate, unless you're good at maths, and GreyScale() makes it easy to see where the first section ends (assuming it doesn't fade to black). Obviously you'd remove it for encoding, but a timecodes file for the above example would look like this. Frames 0-2459 become frames 0-3935 after the frame rate conversion.
# timecodes format v1
Assume 25.000000
0,3935,50.000000
The timecodes would be added to the x264 command line this way:
--tcfile-in "D:\timecodes.txt"
I guess you could also apply a speedup to the 29.97fps section directly using a timecodes file. It'd avoid the frame rate conversion, but the resulting frame rate wouldn't be standard, if you care about that sort of thing. It might be the least offensive way to do it though. Frames 0-2459 are increased to 31.25fps via the timecodes.
MPEG2Source("E:\video.d2v")
Trim(0,2459).AssumeFPS(25)\
++Trim(2460,0).TFM().TDecimate().AssumeFPS(25)
LanczosResize(640,480)
# timecodes format v1
Assume 25.000000
0,2459,31.250000
I think that's correct, although my preference would be to change the audio speed instead. :)
Metal-HTPC
28th February 2019, 08:00
thanks so far guys I will try a bit get back to you with additional information on sunday.
@hellohello. Your guide looks pretty interesting tho my project has to be compatible to a BD-R specifictation since I already have pretty awesome cover boxes for this show and plan on making several bd-r's out of it which have to be compatible for stand alone bd player playback.
hello_hello
28th February 2019, 15:05
That's a pity... Does your Bluray player play MKVs? I assume they pretty much all do these days. If so, you could still use discs but burn the MKVs as data files instead of having to worry about all the Bluray compatibility stuff.
Other than that, maybe converting the 29.97fps section to interlaced PAL might be the next best bet. I think this is the standard method, only instead of converting to 50fps before removing fields for 25i, you'd convert to 47.952fps and apply PAL speedup. Chances are it'll look better though if you interpolate new frames rather than blend them.
ie FrameRateConverter(48000,1001) instead of ConvertFPS(48000,1001) etc.
Obviously you'll have to encode as interlaced, but assuming the source intro section is progressive...
Trim(0,2459)\
.LanczosResize(720,576)\
.ConvertFPS(48000,1001)\
.AssumeFPS(50)\
.SeparateFields()\
.SelectEvery(4,0,3)\
.Weave()\
\
++Trim(2460,0)\
.TFM().TDecimate()\
.LanczosResize(720,576)\
.AssumeFPS(25)
Or.... you could deinterlace the first section for 25p. I could be wrong, but I suspect it'll look better than going from 29.97fps to 23.976fps and applying speedup, especially if you de-interlace with QTGMC().
I'd also try running QTGMC() in progressive mode over the second section too, assuming it could do with some cleaning up and/or noise removal. I use it for that sort of thing regularly.
Trim(0,2459)\
.LanczosResize(720,576)\
.FrameRateConverter(48000,1001)\
.AssumeFPS(50)\
.SeparateFields()\
.SelectEvery(4,0,3)\
.Weave()\
.QTGMC(FPSDivisor=2)\
\
++Trim(2460,0)\
.TFM().TDecimate()\
.LanczosResize(720,576)\
.QTGMC(InputType=1, EzDenoise=1)\
.AssumeFPS(25)
Sharc
28th February 2019, 15:51
The OP should upload a sample of the critical intro part (and preferably also of the telecined 2nd part). Otherwise all advice is speculative and based on possibly wrong assumptions.
Metal-HTPC
1st March 2019, 07:48
your suggestion sounds pretty interesting, hello_hello.
Now I have so many suggestions that I also think that it will probably the best to upload a sample here. I will do that later on.
Metal-HTPC
1st March 2019, 15:17
ok here is the sample: https://www.file-upload.net/download-13522248/sample.m2v.html
Sharc
1st March 2019, 17:07
The hoster permanently tries to install some executable crap.
Change the file hoster. I won't download anything from this site.
StainlessS
1st March 2019, 17:26
MediaFire is often used on Doom9, you need an account.
SendSpace, I think that you dont need account (but easier with), but uploads deleted 30 days after last download.
hello_hello
1st March 2019, 20:13
Here's some more. You can upload without an account. I've used all three in the past and I'm pretty sure they're okay.
http://ge.tt/
https://www.filedropper.com/
https://uploadfiles.io/
Metal-HTPC
2nd March 2019, 01:20
hey guys,
sorry didn't know that service turned into crap. I just put it on wetransfer. We use that one at work it's very safe.
https://we.tl/t-YbUNuA5p4m
hello_hello
2nd March 2019, 06:30
I gave my previous suggestion a try and it seems okay.
In case you're wondering, the cropping/resizing in the included script was done with a script (although a newer version with support for anamorphic resizing I haven't quite finished yet), but I cropped the crud because I have to.... it's probably some sort of OCD thing (Obsessive Crud Disorder ;))
I only encoded about 2/3 of the sample as my upload speed tends to be more of an upload slow, and there's wasn't a great deal of 29.97fps video anyway. The pulldown starts right after the "Tales From The Crypt" logo, about 35 seconds from the beginning.
Sample.zip (http://ge.tt/1fztZlu2)
Metal-HTPC
2nd March 2019, 11:09
dear hello_hello,
the sample you encoded looks pretty amazing. I will try the script tomorrow. Regarding cropping it's totally okay to get rid of black bars ;-). I will download your CropResize script and use that.
By the way I noticed something weird. For Season 1-2 the audio I need to adjust to the video runs in NTSC speed, so I only need to convert season 3-7 to 25fps and can encode the seasons 1-2 in 23976.
Would you use your script for a x264 NTSC encode as well and would the main commands look like this instead
Trim(0,2459)\
.FrameRateConverter(30000,1001)\ or .FrameRateConverter(24000,1001)\ ?
.AssumeFPS(23.976)\
.SeparateFields()\
.SelectEvery(4,0,3)\
.Weave()\
.QTGMC(FPSDivisor=2)\
\
++Trim(2460,0)\
.TFM().TDecimate()\
.QTGMC(InputType=1, EzDenoise=1)\
.AssumeFPS(23.976)
or wouldn't you use that and make a direct encode with only .AssumeFPS(23.976) and the cropping command in the avisynth script?
Also as far as I understood your cropping script, it works automatically so I could just change the command to .CropResize(720,480,12,0,-10,-4,InDAR=15.0/11.0,OutDAR=15.0/11.0)\ right?
hello_hello
3rd March 2019, 14:08
....or wouldn't you use that and make a direct encode with only .AssumeFPS(23.976) and the cropping command in the avisynth script?
Also as far as I understood your cropping script, it works automatically so I could just change the command to .CropResize(720,480,12,0,-10,-4,InDAR=15.0/11.0,OutDAR=15.0/11.0)\ right?
The current version of the script doesn't support an anamorphic output, and the new version isn't quite ready to release into the wild, so there's a modded version of the old script attached. Everything is disabled other than full resizing so I didn't have to spend lots of time testing it (no borders, input pixel aspect ratio, colour correction or ability to disable resizing). Doing that gave me an idea for solving a problem I was having with the new script behaving intuitively though, so it probably helped me too.
This temporary version is called CropResizePicDar() as it always crops according to the specified PicDAR, which by default is the same as the InDAR, which by default is the same as the source video dimensions. The output dimensions will be the same as the source unless you specify something else. Therefore the following should produce the same result for a 720x480 DVD.
CropResizePicDar(720,480, 12,0,-10,-4, InDAR=15.0/11.0, PicDAR=15.0/11.0)
CropResizePicDar(0,0, 12,0,-10,-4, InDAR=15.0/11.0, PicDAR=15.0/11.0)
CropResizePicDar(0,0, 12,0,-10,-4, InDAR=15.0/11.0)
When resizing NTSC to PAL you'd need to specify the 720x576 output dimensions.
For the videos that don't need to be converted to PAL, I assume there's no reason why you couldn't emulate the DVD and encode at two different frame rates.
For the progressive section you'd encode at 29.97fps and add --fake-interlaced to the x264 command line along with all the other Blu-ray requirements, as 29.97fps progressive isn't Blu-ray compliant for 480p. For the film section you'd remove the pulldown with TFM().TDecimate() and encode at 23.976fps while adding --fake-interlaced & --pulldown 32 to the command line.
--pulldown 32 tells the player which fields to repeat so it can output 29.97fps by applying pulldown on playback, but I think a player would/should ignore the repeat field flags and just output 23.976fps progressive when connected to a progressive display.
To make all that work, I think the encoder has to write a raw .264 stream (not an MKV) and you'd have to encode the two sections separately and join them later, but to make sure I wasn't talking rubbish I encoded test samples. MKVToolNix appended them without complaint and the output MKV played perfectly with MPC-HC. I also added --stitchable to the x264 command line each time.
Where you go from there to put it onto a Bluray complaint video disc I have no idea as I've never created one myself, given there's MKV.
Here's some links on Bluray compliance in case you haven't seen them.
http://www.x264bluray.com/home
https://forum.doom9.org/showthread.php?t=154533
http://www.chaneru.com/Roku/HLS/X264_Settings.htm#pulldown
Here's the modified CropResize script and the test samples I created to make sure the encoding would work as expected.
NTSC Sample.zip (http://ge.tt/7Qv89nu2)
PS Here's the command lines for the two encodes. Hopefully I got it right.
29.97fps progressive
x264.exe --level 4.1 --bluray-compat --preset slow --tune film --crf 18.0 --keyint 30 --open-gop --slices 4 --vbv-bufsize 30000 --vbv-maxrate 40000 --stitchable --fake-interlaced --colorprim smpte170m --transfer smpte170m --colormatrix smpte170m --sar 10:11 --output "D:\sample 1.264" "D:\sample 1.avs"
23.976fps progressive
x264.exe --level 4.1 --bluray-compat --preset slow --tune film --crf 18.0 --keyint 24 --open-gop --slices 4 --vbv-bufsize 30000 --vbv-maxrate 40000 --stitchable --fake-interlaced --colorprim smpte170m --transfer smpte170m --colormatrix smpte170m --pulldown 32 --sar 10:11 --output "D:\sample 2.264" "D:\sample 2.avs"
Metal-HTPC
4th March 2019, 08:43
thanks a lot for your suggestions for the 29.97fps and 23.976fps I will get back to those later.
First I need to get your 25fps script running. I tried for hours yesterday and didn't have any success. In order to get a compatibillity to your CropResize script I updated several dlls to the latest version and added several new ones I haven't used before.
So at the moment I'm loading the following plugins
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\DGDecode.dll")
import("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\addgrain.avs")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\mvtools2.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\DePan.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\DePanEstimate.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\TIVTC.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\dither.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\avstp.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\FrameRateConverter.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\AutoCrop.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\RgTools.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\AddGrainC.dll")
LoadPlugin("C:\Program Files (x86)\Video\Encoder\AviSynth\plugins\ColorMatrix.dll")
However the CropResize still doesn't work here. In my AVSProdgui I'm getting the error message "CropResize does not have a named argument "OutDAR".
So in order to achieve something I didn't use the cropresize lines and instead just changed the this/that lines to
This = ABC.Trim(0,1212).DoThis().LanczosResize(720,576)
That = ABC.Trim(1213,0).DoThat().LanczosResize(720,576)
However my x264 batch puts out "Module not found. Install missing library" error messages for "FrameRateConverter.dll", "mvtools2.dll", "tivtc.dll". After downgrading mvtools2 and tivtc to the older version which I had before the error message disappeared. Now I'm trying to find an older FrameRateConverter and give it another try this evening. But when I want to give your CropResize another chance an older FrameRateConverter won't accept as many block sizes as the new version so that wouldn't make sense. I don't know how to solve those problems other than trying to ask you for a "hello_hello" Avisynth plugin package" ;-)
thanks for your ongoing support
hello_hello
4th March 2019, 13:59
CropResize doesn't use any plugins aside from autocrop.dll if auto-cropping is enabled and the Resize8 script for resizing, but only when that's enabled (otherwise it uses Avisynth's Spline36Resize), and colormatrix.dll for color conversion when upscaling/dpwnscaling, but you don't need it and if you don't have it installed you won't get an error anyway. The reason for the error is I changed some of the argument names for the new version. For the version I included with the sample you need to use PicDAR instead of OutDAR (as I did for the example in my previous post). Or don't use it at all and just specify the correct InDAR, as by default PicDAR will be the same as InDAR. That's only for the modified CropResizePicDAR script I included with the sample. The current CropResize script doesn't support anamorphic resizing and will only resize to square pixel dimensions (I'm still ironing out bugs in the new one as I've changed quite a bit).
The rest of the errors relate to QTGMC and/or FrameRateConverter plugins. They have plugins in common. The "missing library" error means you need to install the library for the plugin in question. Make sure you have the latest version of each plugin listed on the QTGMC wiki (http://avisynth.nl/index.php/QTGMC#Core_Plugins_and_scripts) and make note of any runtime files each plugin requires. For example masktools2 requires the VS 2017 runtime files (http://avisynth.nl/index.php/MaskTools2#Download). For the other plugins, check the included readme file for any dependencies. They don't all have dependencies and you could already have some of the required runtimes, depending on your version of Windows.
By the way, plugins in the AviSynth\plugins folder (the one where you installed Avisynth) will auto-load when Avisynth runs. You don't need to load them with LoadPlugin if they're in the auto-loading folder. The same applies to scripts such as QTGMC as long as they have an AVSI extension. You don't need to import them
Newer QTGMC versions require the SMDegrain and AnimeIVTC scripts, and make note of where to put libfftw3f-3.dll and and FFTW3.dll. Instructions for those are just below the list of plugins in the QTGMC Wiki. The dither package also includes dither.avsi, mt_xxpand_multi.avsi and avstp.dll.
The closest I have to a plugin pack is one I put together for QTGMC well over a year ago. I don't recommend using those plugins as such (FrameRateConverter probably requires newer MaskTools2/MvTools2), but as it exists and it's easy enough to provide a link, here it is (https://files.videohelp.com/u/210984/QTGMC%203.357s%20_%20Plugins%202017-05-05.zip) so you can use it as a guide to make sure you have everything. Putting together a new one would require a bit of work.
QTGMC is generally a challenge, especially if you're relatively new to Avisynth, but once it's working it'll keep working and many scripts have the same plugins in common. If you get an error regarding a missing function when you're sure you have the plugin in question, or a "missing library" error, check for required runtime files.
hello_hello
4th March 2019, 14:19
PS. I'm not familiar with addgrain.avs, but AddGrainC.dll (http://avisynth.nl/index.php/AddGrainC) is an optional QTGMC plugin.
Metal-HTPC
4th March 2019, 16:17
ah now I get. I will try to use your modified CropResize script from post #21 then.
Regarding the runtimes I have to say that I never used additional runtime files before so I somehow must have overread it. I will install the required ones and that should solve those problems.
Thanks a lot also for your package which I can use as a guideline.
For the videos which don't need a pal conversion I have to say that I always used --TFF or --BFF as an interlaced command in my script but will give your
"---fake-interlaced" suggestion a try. Just read that it allows the stream to be encoded progressively yet flagged as interlaced which sounds pretty interesting.
Katie Boundary
5th March 2019, 02:18
Clip opens with a generic climb down some stairs from a first-person perspective at 30 progressive frames per second, followed by a 60 hz fadeout; I assume this is a common intro to every episode
This is followed by some BS with a motorcycle and the Cryptkeeper yakking at the camera while dressed as one of the Village People. I assume this is an "intro" specific to this particular episode. This is done at 24 FPS.
Then the episode proper begins. The individual clips were shot at 24 FPS, but then they were transferred to tape and edited on tape, leaving a lot of orphaned fields and other interruptions in the pulldown pattern.
In short, it's your classic 24/30/60 FPS hybrid clusterf**k from the 1980s/90s, improperly captured from old VHS or Beta masters. Fortunately, a few months ago, I wrote a boilerplate approach for converting exactly this kind of content to PAL:
loadcplugin("c:\yadif.dll")
A=yadif(mode=1).selecteven()
B=yadif(mode=1).selectodd()
C=Tfm(field=1,mode=0,slow=2,cthresh=2,mthresh=2,clip2=A,micmatching=0)
D=Tfm(field=0,mode=0,slow=2,cthresh=2,mthresh=2,clip2=B,micmatching=0)
Interleave(C,D).tdecimate(mode=1,cycle=6).spline144resize(720,576).separatefields().selectevery(4,0,3).weave().assumefps(25)
You can replace Yadif with any bob-deinterlacer of your choice, but Yadif is the most reliable at delivering "correct enough" results. This script also assumes that you need an actual PAL result; if you just need 25 fps and don't care about the resolution, then you can cut out spline144resize().
Metal-HTPC
5th March 2019, 10:13
@hello_hello
I successfully made an encode of your suggestion yesterday. I left out
CropResize but will try that soon and would ask further questions about it in your official thread regarding that script.
The encoding of the intro theme (until the crypt keeper comes out of the casket) had a bit of stuttering. The encode of the cryptkeeper announcement and the episode itself looked very good.
@Katie Boundary
thanks a lot for your script suggestion and very interesting information which most likely not many people would be able to notice. I will try that one as well and see how it comes out.
I have a question in advance tho'. You wrote that the episode is actually a mix of 3 different fps:
A = intro theme (until casket w/ laughing crypt keeper) = 30fps
B = crypt keeper announcing the episode (until open book = 24fps
C = the episode itself = 60 fps
at the end of the episode the crypt keeper is appearing again and after that the end credits follow. This will most likely mean
D = crypt keeper closing speach = 24fps
E = end Credits = 30fps
I could post a short sample of the passages to make shure.
I noticed that you didn't split your script in 2 or 3 different parts with commands such as "Trim(2460,00)"
Does this mean that your scripts finds out which parts of the episodes are 30/24/60 by itself without having to define it ?
That would be pretty amazing but is hard for me to believe.
Regarding resolution: I'm encoding it blu-ray compatible to h264 but want it to be real 720x576 and 25fps. so that it is a so called PAL SD-Blu-ray.
For resizing I usually use spline36 or Lanczos. Does spline144 really make a difference on this particular project?
hello_hello
5th March 2019, 16:46
@hello_hello
I successfully made an encode of your suggestion yesterday. I left out
CropResize but will try that soon and would ask further questions about it in your official thread regarding that script.
The encoding of the intro theme (until the crypt keeper comes out of the casket) had a bit of stuttering. The encode of the cryptkeeper announcement and the episode itself looked very good.
I'm a bit motivated now so I might spend some time trying to finish the new version this week.
@Katie Boundary
thanks a lot for your script suggestion and very interesting information which most likely not many people would be able to notice. I will try that one as well and see how it comes out.
I have a question in advance tho'. You wrote that the episode is actually a mix of 3 different fps:
A = intro theme (until casket w/ laughing crypt keeper) = 30fps
B = crypt keeper announcing the episode (until open book = 24fps
C = the episode itself = 60 fps
There's no such thing as 60fps for DVD.
If a "film" section was edited after applying pulldown, it's possible to create an "orphaned" field at the edit point, where one field from a whole frame no longer exists.
I'm not an NTSC expert but I don't think it's generally that big a deal, as it just changes the pattern of duplicate frames after field matching, and TDecimate() removes the duplicates anyway.
24p/30p/60i hybrid is nothing unusual. DVD is an interlaced format designed for an interlaced display and was only intended to be 59.94 fields per second. Orphaned fields don't matter when you're not displaying frames. Progressive displays and Katie's need to combine fields into whole frames came much later. ;)
I noticed that you didn't split your script in 2 or 3 different parts with commands such as "Trim(2460,00)"
Does this mean that your scripts finds out which parts of the episodes are 30/24/60 by itself without having to define it ?
That would be pretty amazing but is hard for me to believe.
After limiting what TFM can do in ways that don't quite make sense to me, her script outputs 59.94fps, then
TDecimate(mode=1,cycle=6)
removes one frame in six for 49.95fps,
separatefields().selectevery(4,0,3).weave()
deletes fields for 24.975fps, and I assume
AssumeFPS(25)
is there to put the audio out of sync.
Or to distract you from the uneven motion.
I don't get it......
hello_hello
6th March 2019, 03:38
By the way, TIVTC can pick out the video and film sections for variable frame rate. You need to run two passes. The first pass being something like:
TFM(Output="D:\TFM Ep1.txt")
TDecimate(mode=4, Output="D:\TDecimate Ep1.text")
And the second pass for encoding:
TFM(Input="D:\TFM Ep1.txt")
TDecimate(mode=5, hybrid=2, Input="D:\TDecimate Ep1.text", tfmin="D:\TFM Ep1.txt", mkvOut="D:\Ep1 Timecodes.txt")
The timecodes file is created as soon as the second pass script is opened, and it can be send to the x264 encoder with
--tcfile-in "D:\Ep1 Timecodes.txt"
The video sections are de-interlaced to 29.97fps and the film sections IVTC'd to 23.976fps and the whole thing is encoded as variable frame rate. I doubt it'd be easy to use that to make a Bluray compliant video though
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.