Log in

View Full Version : Convert 1080p29.97 to 480i (29.97)


DeathMonk
1st March 2011, 00:43
A weird request, I know.. But at the request of a client. Another requirement is that it is center-cropped to 4:3, but I believe I have that figured out.

I'm lost on what do do with avisynth to make this happen.

LoRd_MuldeR
1st March 2011, 01:23
If with "480i (29.97)" you mean 59.94 fields per second, then this is impossible, as the temporal resolution of your source is only 29.97 progressive frames per second.

The only thing you could do is "fake interlaced", i.e. each pair of two successive fields showing the odd/even lines of one progressive input frame...

NerdWithNoLife
1st March 2011, 03:29
Unless for some odd reason it's 60p (not likely). If this client really has issue with progressive frames, MVTools2 can fake the extra instants of time to get 59.94 fields per second:

##MPEG2Source or whatever
#Edit: I put a bob here accidentally. The framerate should be doubled by the step:

##A "fast" way to double the frame rate (even faster if you do it after scaling down)
super = MSuper(pel=1,hpad=0,vpad=0,chroma=false)
backward_vec = MAnalyse(super, blksize=32, isb = true, chroma=false, searchparam=1,search=0)
forward_vec = MAnalyse(super, blksize=32, isb = false, chroma=false, searchparam=1,search=0)
MFlowFps(super, backward_vec, forward_vec, num=2*FramerateNumerator(last), \
den=FramerateDenominator(last), mask=0)

Crop(240,0,-240,0)
BicubicResize(720,480)
SeparateFields().SelectEvery(4,0,3).Weave()

manono
1st March 2011, 04:28
Just encode it as interlaced. Voila, 480i. If the frames really have to appear as interlaced (what a stupid idea when starting with progressive footage!), do as LoRd_MuldeR suggests. Separate the fields, drop the first one, weave it back together again.

DeathMonk
1st March 2011, 16:32
Sorry, yes I meant 59.94 fields per second. It is very odd to request interlaced... Especially since it will end up for the web. I'll give it a try.

manono
2nd March 2011, 05:46
480i is 59.94fields per second, even if each pair of fields is from the same moment in time. As for making an interlaced video for upload to the internet, does this person have any idea what he's asking? Or is he intentionally wanting to have it look as bad as possible?

2Bdecided
2nd March 2011, 13:50
I don't think you should attempt to create fake inter-field motion unless someone has very specifically asked for this (and even then, it adds artefacts!).

Just resize the frame and be done with it.

It's a 3 line script...
source
crop
resize

That's it.

If you want to do a proper job, find out _where_ on the web it's supposed to be going, and supply a suitable mp4 ready for upload (unless they want to edit it first).

Cheers,
David.

DeathMonk
2nd March 2011, 14:55
480i is 59.94fields per second, even if each pair of fields is from the same moment in time. As for making an interlaced video for upload to the internet, does this person have any idea what he's asking? Or is he intentionally wanting to have it look as bad as possible?

I know.. I have no clue as to why this was requested. We are not doing any of the post work, otherwise this silly question would have never been asked.

Didée
2nd March 2011, 15:16
The simple answer is that it's not clear what exactly should be done. It could be "fake-interlaced" progressive, or it could be synthesized fields, or it could be phase shift, ... it all has been mentioned before. We can't read minds, neither can you.

Clarification is needed. Check back with the customer about the technical details. A dice game is too easy to lose.

SilaSurfer
2nd March 2011, 17:12
Hey guys I found a script from author Dan Isaacs. Hd2sd() meant for downsamling from HD for interlaced and progressive material to SD.

http://3dvp.com/hd2sd_sd2hd.zip

Got some good results!

2Bdecided
2nd March 2011, 18:24
A dice game is too easy to lose.Oh, I don't know. With an apparently clueless customer it might raise the possibility of charging them twice!

Seriously, delivering 480p29.97-wrapped-in-480i29.97 would be fine.

Cheers,
David.

Emulgator
2nd March 2011, 21:31
SilaSurfer, these Dan Isaacs scripts (hd2sd and sd2hd) are awesome.
I was just experimenting with (not so) simple interlaced downsizers
for HD to SD conversion of an already rendered BD-ES
and couldn't find the real thing (besides TGMCing and resizing in progressive).
This helped. Many thanks !

DeathMonk
3rd March 2011, 01:00
Well, we sent a progressive and interlaced sample and they chose the progressive clip... Sighhhhh

NerdWithNoLife
3rd March 2011, 02:53
So it was basically a request like "I don't want to stretch it out but I want it to take up the whole screen" for SD on a 16:9 monitor. (And if they didn't know what they're talking about why be so specific?) Not surprising when you've dealt with enough clients. :)

2Bdecided
3rd March 2011, 12:40
SilaSurfer, these Dan Isaacs scripts (hd2sd and sd2hd) are awesome.
I was just experimenting with (not so) simple interlaced downsizers
for HD to SD conversion of an already rendered BD-ES
and couldn't find the real thing (besides TGMCing and resizing in progressive).
This helped. Many thanks !You just need dumb bob, colormatrix, resize, vertical soften, and re-interlace. TGMCing interlaced HD to convert it to interlaced SD is serious overkill.

But the 492 lines of the clever hd2sd script will get you there too. Though it doesn't vertically soften by default. And in some cases it seems to filter by default.

Cheers,
David.

SilaSurfer
6th March 2011, 15:58
SilaSurfer, these Dan Isaacs scripts (hd2sd and sd2hd) are awesome.
I was just experimenting with (not so) simple interlaced downsizers
for HD to SD conversion of an already rendered BD-ES
and couldn't find the real thing (besides TGMCing and resizing in progressive).
This helped. Many thanks !

You're welcome.

@2Bdecided

I've found couple of threads where you talked about going from interlaced HD to SD. You got any perticular workflow for progressive material?

2Bdecided
7th March 2011, 14:42
resize
colormatrix

Never needed anything else. You can vertically soften if you think it'll get displayed on a CRT one day, but that's throwing away nice sharpness.

EDIT: for "NTSC" you may need pulldown for 24p>60i: use dgpulldown.

Cheers,
David.