[...] hd ? last.PointResize(last.width * 12, last.height * 12) : 0 # Aspect ratio correction height = hd \ ? 2160 \ : last.width > (last.height * waspect / haspect) \ ? (last.width * haspect / waspect) \ : last.height width = handheld \ ? height * last.width / last.height \ : height * waspect / haspect width = (width % 4 == 1) ? width + 3 : \ (width % 4 == 2) ? width + 2 : \ (width % 4 == 3) ? width + 1 : width height = (height % 4 == 1) ? height + 3 : \ (height % 4 == 2) ? height + 2 : \ (height % 4 == 3) ? height + 1 : height g = hd \ ? LanczosResize(width, height, taps=2) \ : handheld || pass == 1 || pass == 2 \ ? last \ : LanczosResize(width, height, taps=2) # Logo. d = ImageSource( \ file=file, start=0, end=int((last.FrameRate * 2) - 1), \ fps=last.FrameRate \ ).ConvertToRGB32().AssumeFPS( \ last.FrameRateNumerator, last.FrameRateDenominator \ ) e = BlankClip(d, audio_rate=last.AudioRate, channels=last.AudioChannels) f = AudioDub(d, e).LanczosResize(g.width, g.height, taps=2) last = f ++ g [...] # Downloadable encodes need a resizing filter for the colourspace reduction. # HD encodes need to be point resized to keep the colour information faithful. ConvertToYV24(chromaresample="point", matrix=(hd ? "Rec709" : "PC.601") ) (pass == 1) ? ExactDedup( \ firstpass=true, dupinfo="./temp/dup.txt", times="./temp/times.txt" \ ) : last (pass == 2) ? ExactDedup(firstpass=false, dupinfo="./temp/dup.txt") : last i444 ? last : ConvertToYV12( \ chromaresample="lanczos", \ matrix=(hd ? "Rec709" : (pass == 0 ? "Rec601" : "PC.601")) \ )