Resize and de-interlace prior to encoding. Is this a sensible work flow?

Posted by Cris McConkey 
Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 01, 2007 06:56PM
Does it make sense to rendering NTSC-DV video as 480 x 320 with de-interlace filter prior to encoding H.264 multi-pass with Compressor? Anyone do things in a similar fashion? Pros and cons?

I am wondering how much of encoding time is take up with re-scaling and de-interlacing, and whether the quality is diminished by starting with a smaller screen size to start.

Thanks,

Cris
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 01, 2007 07:19PM
I don't see any point in doing it in two steps. And I do suspect that if you reduce the frame size prior to the export, you're reducing the amount of data available for the final compression and your quality will suffer. Also, de-interlacing NTSC video tends not to look very good.


www.derekmok.com
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 01, 2007 07:34PM
Um, deinterlacing NTSC can look very good if that's the look you want, and is very appropriate for a web movie.

Graeme

[www.nattress.com] - Plugins for FCP-X
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 01, 2007 07:54PM
Personally, I far prefer using something like the Nattress package to simulate 24p than to use the De-Interlace filter. That's what I meant. To my eye, the De-Interlace filter never looks right.


www.derekmok.com
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 01, 2007 07:59PM
Standards Conversion makes a 24p movie from a 60i one - [www.nattress.com] works well!

Graeme

[www.nattress.com] - Plugins for FCP-X
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 01, 2007 08:08PM
The QT streaming server I use seems to choke on interlaced video, so that is my main concern. Your video at 24p looks great!

--Cris
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 01, 2007 10:29PM
Cris:

As indicated, if you're going for the web then de-interlace and encode the movie as progressive.

Do not resize prior to Compression. Do the resizing in the final stage, in Compressor.

Question for Graeme:

Does your filter make a 35mm telecined for editing in FCP work (29.97) in making the movie 24 frames per second progressive? Or does it only work with 60i?

Derek:

You often speak of 35mm originated video as having 24 fps cadence. Is it possible to regain that after having telecined the movie in 29.97? And how is it done?

Thanks.
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 02, 2007 10:14AM
Sorry, I had missed derekmok's response on email.

But, I am more confused than ever.

I had always understood --give the codec more pixels to work with. Of course, if I am using the h.262 codec for higher quality, then it is self defeating to rescale first. I was interested to see if doing that might cut back on encoding time, but really, it is all out of desperation, as I am having a lot of problems with the streaming which appears to behave in a sporadic manner with the hosting service I am using (Darwin Streaming Server).

Currently, I am deinterlacing the video using a combination of FCP deinterlace medium flicker filter and Joes motion adaptive de-interlace filter with a sequence advance setting for progressive rather than interlaced video. No change in size.
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 02, 2007 10:19AM
Well, interlace doesn't play on the web as all computer monitors are progressive, so you've got to kill that. 30fps is also less frames per second than 60fps. I've seen people take the 30fps and encode at 15fps if motion isn't that important, but resolution and detail are. Going to 24fps like I did, can help as you get good filmic motion, but it's less than 30fps so you've got more bandwidth, effectively.

Giving the codec less, but higher quality information is a good way to go. Noise is a codec killer, so shrinking an image down will reduce noise.

Graeme

[www.nattress.com] - Plugins for FCP-X
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 02, 2007 10:52AM
Thanks, Graeme. For the first time I know now why my early videos on the web didn't look that good.

But my question is more regarding DVDs. Do you make a plugin/filter that returns a 24 fps film back to 24 fps after having been digitized as 29.97 fps for editing on FCP?
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 02, 2007 11:16AM
Cinema Tools, that comes with FCP, does that!

Graeme
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 02, 2007 11:44AM
Okay, thanks.

You're a super guy.
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 02, 2007 01:57PM
Graeme, et al.,

So, there are too opposing answer to this question of re-sizing. Effectively filtering out higher frequency spacial noise by reducing the scale before encoding vs give the codec all the pixels to work with. You are saying that if quality of the image is improved by scaling first, then the quality of the encoding may be improved for the desired output size. Therefore, a case might be made for reducing the encoding time by scaling first ...sometimes.

In regard to 15 fps...

I do mostly seminars, lectures, press conferences, etc.. Obtaining a 'filmic' look is not so important to me but using 15 fps, on a close up of someone talking, makes the lip movement look very unnatural. So, what you say about have more effective bandwidth with 24p could apply here as well.

I am really confused in regard to what happens to the fields during encoding. De-interlace filters still retain two fields. One may be duplicate of the other (field doubling), or interpolated, or some parts of the image are interpolated and others not by virtue of a motion mask. Or, I guess there is another option as well that will actually move the filed(s) in space as needed.

What happens when I change the sequence setting from interlaced to progressive prior to rendering? Does this do anything?

Looking at my rendered footage, using Joe's field fixer I can see the difference between even and odd fields on frames where motion has left a ghost image. My NTSC monitor through the digital camcorder I use alternates the fields but they have been interpolated so much that very little flicker is noticeable. So, does changing the sequence setting to progressive have any effect at all? Does it write something in the file header telling the encoder to treat the fields as 60p rather than 60i?

How would I export a 30p movie? After all this de-interlacing, I don't see much is lost by throwing away the odd or even frames.

Graeme, can you give me an idea how long it might take for your 60i to 24p converter to render? On a 867 MHz G4? On a Mac Pro power book? (current, but nothing fancy).

Thanks,

Cris
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 02, 2007 02:00PM
About 6:1 for the render to 24p I think.

Field doubling wouldn't be good for scaling down to web size, but blending would be good. There'd be minimal advantage from a smart de-interlace.

Yes, 15fps can be too extreme, but sometimes it's fine - all depends. 24p is usually ok.

Graeme

[www.nattress.com] - Plugins for FCP-X
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 05, 2007 12:07AM
I just found the appended in the topic "Deinterlacing in Compressor" on Apple's Compressor forum. [discussions.apple.com]

This indicates that I may have been on the right track to begin with. The trick is to de-interlace and rescale in one render operation in FCP, with the scaling defined by the sequence setting, and then transcode with Compressor:

This also fits Graeme's comment that rescaling may reduce some of the noise and make compression more efficient.

I am trying this with a sequence setting of 360 x 240 progressive. I am simply using FCP "upper field" de-interlace. Throw 1/2 the fields away but scaling down to half the lines at the same time anyway.

Check it out. Let me know what you think. --Cris

---------------------

[discussions.apple.com]


subnubilus

Posts: 79
From: Irondale, Alabama, USA
Registered: Sep 6, 2006

Re: Deinterlacing in Compressor
Posted: Apr 30, 2007 8:03 PM in response to: Noble Brown
Click to reply to this topic Reply email Email

If you're doing this for your iPod and your video is at least twice as big as the iPod dimensions, here's what you do for perfect compression:

1) Add the deinterlace filter to every clip in your sequence. Do not apply it to a nested version, it needs to be the original timeline or an exact duplicate of it.

2) Duplicate the sequence and delete all the contents of the timeline in the new sequence. This is in order to make a sequence with identical settings. Now go into the sequence settings and change the aspect ratio and dimensions to whatever it'll be on the iPod, and also set it to PROGRESSIVE. Make sure to turn Motion Filtering or whatever they call it to Fast (Linear). Unless you know something I don't, you should probably turn this off in your original sequences too.

3) Now nest the deinterlaced sequence into the smaller sequence (drag the sequence file itself into the new timeline). I believe the scaling will be done for you but if not just fix that in the Motion settings, which you'll only need to do once since it's a nested sequence with no separate clips.

4) Render the entire sequence, and then Export as Quicktime Movie (NOT Export using Quicktime Conversion). INCLUDE Compression markers but DO NOT CHECK THE BOX about making the Quicktime movie independent (or something like that, I forgot what it's called, not at my PowerMac right now).

5) Put that Quicktime into Compressor, but edit your settings so that Frame Controls are OFF.

I left out a lot of the little details because I figure the above solves your particular problem. If you're worried the deinterlace filter is removing data, it's not. The temporal data is rendered by Final Cut Pro and the resolution, which would normally be halved by the deinterlacing process, is shrunk down to half-size or less anyway, negating the loss in resolution.

And no, you shouldn't have to do all this since supposedly FCP and Compressor work together, but it's the only solution I could come up with that produced pristine results and didn't take too long.
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 05, 2007 11:16AM
Quote

4) Render the entire sequence, and then Export as Quicktime Movie (NOT Export using Quicktime Conversion). INCLUDE Compression markers but DO NOT CHECK THE BOX about making the Quicktime movie independent (or something like that, I forgot what it's called, not at my PowerMac right now).

I have tried exporting both as a reference movie and full contained movie. Time to write the file is estimated at 5 hours for a one hour movie. This is with the sequence fully rendered and the sequence setting exactly matching the export settings.

I cam open the 240 x 360 pixel render file just fine in QT Player, so it is beyond me why it takes so long to write the file during export. Obviouslt, there is some rendering going on in the background, which suggests the reason for exporting a reference movie instead of a fully contained movie, except that this isn't working in my case.

What would be rendered during export?

I am wondering, should I have changed field preference to "none" when I changed advance video settings to progressive?

The attempt here is to half the vertical lines while throwing away half the fields with no re-frame sampling, but apparently QT insists on redrawing all the frames.

Be that as it may ...

I'd like to see more discussion on how best to preserve as much quality and resolution when going from 30i to 30p (or 29.97 as the case may be) prior to transcoding for web streaming. That implies a smart de-interlace in order to gain spacially what is lost temporally. That does not imply a motion mask that preserves some of the interlacing.

I'd be willing to invest in format conversion software that would give me two identical fields at full resolution, so one could be thrown away without losing resolution, keeping blurring, ghosting, etc, at a minimum.

If it is necessary to go to a slower frame rate inorder to interpolate and preserve spacial quality and resolution, in effect reclaiming spacial information from temporal fields, I'd consider that too.

I did try a 24 fps quicktime export, on a close up of a subject with fast and almost exagerated lip motion. It isn't too bad. But at this point, I am less interested in filmic look than in preserving quality and getting the best encoding I can that will stream without problems.

So, that is the broader topic --how to render in and export from FCP prior to transcoding for best results achievable in a reasonable amount of time.

Final note: given how long my G4 is running, I am thinking of reducing my carbon footprint with a Mac Pro laptop and Stealth transcoding card.

--Cris
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 05, 2007 07:12PM
Quote

time to write the file is estimated at 5 hours for a one hour movie. This is with the sequence fully rendered and the sequence setting exactly matching the export settings.

that could be a problem right there.
don't try to match the sequence settings,
export as a QuickTime Movie, and just use the default "Current Settings"

once you move away from that, even if you;ve used exactly the same settings, it;s a re-compress, which could entail a re-render.
Export With Quicktime Conversion will DEFINITELY require a re-render.
(notice how the timeline goes all RED when you use this. it by-passes your original renders to start from scratch)

Quote

interlacing

didn't Graeme answer this?
for web streaming, computers cant display interlaced fields, so don't sweat it.
use the de-inmtelace in Compressor.

as soon as you get to 30 frames per second as opposed to 60 discrete images per second, you're SO much close to the look of 24fps it's probably all you want.

Quote

So, that is the broader topic --how to render in and export from FCP prior to transcoding for best results achievable in a reasonable amount of time.

for DV, Quicktime movie, same settings.
that's the "ones & zeros" export
do everything else in Compressor.


nick
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 07, 2007 10:26AM
Thanks Nick,

Here is the vexing problem:

I made a copy of the sequence from where I exported the fully contained movie, deleted all files in the time line (leaving only the sequence compression and chapter markers) and imported the fully contained movie which I had exported earlier with these exact same sequence settings. Wouldn't you know, FCP says it needs to be rendered!

Maybe I am missing something obvious. Anyone who wishes to venture down this path is welcome to chime in.

-----------------------------------------
full account of trials and tribulation:

The render export problem appears to be a more complicated one. Please bare with me. I couldn't reply sooner because I decided to do a very long combined export and render from FCP which sucked up virtually all of my computer's CPU time. I decided not to risk having to render again and I was confident enough with my filter settings that I decided to do things this way. Fortunately, I have an UPS.

This took in excess of 20 hours because in addition to the custom sequence setting, I had three filters: Joe's Frame Blender (for noise); Un-sharp (mostly to improve the appearance of shadowed text for titles after de-interlacing) ; Quick De-interlace.

My sequence setting (video) was as follows:

Frame size: 420 x 316 Custom 4:3
Pixel Aspect Ratio: square
Field Dominance: none
Editing Timebase: 29.97 (unchanged)

Quicktime Video Settings
Compressor: DV/DVC-PRO - NTSC
Quality: 100%

Advanced:
Motion
Frames per second: 29.97
Compressor
Quality: Best

Scan mode: Progressive
Aspect Ratio: 4:3

The resulting video looks good. The custom size is what I want for embedding into a word press blog once a sprite is added. Only in a few places on close-ups with accentuated head movement is ghosting evident due to the frame blending. The titles (Boris Title 3-d with a composited effect) look O.K. after scaling and de-interlacing. The camera gain noise, which was accentuated as I had to boost the mid range because of inadequate fill light, is not noticeable (scaling down image size alone would have not solved the problem).

This far, a test 2-minute 300 kbps H.264 SINGLE PASS encoding looks O.K.. (I am having break-up problems with streaming video encoded with VBR, so I was looking to find compression settings that might give acceptable results with a single pass as well as reducing encoding time).

However, I'd like to add some additional forced I frames (compression markers). The only way I know how to do this is in FCP, though I suppose I could figure out how to export the text file from my movie, add some points, and paste it back in. Perhaps there is an easier way to do this outside of FCP.

Here is the vexing problem:

I made a copy of the sequence from where I exported the fully contained movie, deleted all files in the time line (leaving only the sequence compression and chapter markers) and imported the fully contained movie which I had exported earlier with these exact same sequence settings. Wouldn't you know, FCP says it needs to be rendered!

Maybe I am missing something obvious. Anyone who wishes to venture down this path is welcome to chime in.
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 07, 2007 02:33PM
this may just be on a higher level than what i can read into but........

it really doesnt make a difference what the TL is set to. most of us are using 4:3,16:9,and 3:2.

in my experience compressor is A1 when it comes to conversion. if you are working in 60i and want 24p then you simply tell compressor. there are some quality setting that can be tweaked to gain even more quality.

most of my final output is to web & DVD. honestly i dont see a lot of video on other sights that meet my quality standards. if you insist on having h264 for the web then you quality is gonna be better any way.

Quote
chris
Does it make sense to rendering NTSC-DV video as 480 x 320 with de-interlace filter prior to encoding H.264 multi-pass with Compressor?

Quote
chris
I am trying this with a sequence setting of 360 x 240 progressive. I am simply using FCP "upper field" de-interlace. Throw 1/2 the fields away but scaling down to half the lines at the same time anyway.

the settings in the seq. i always leave at 3:2 ntsc. i record with dvx100b at 30p. when ever i want a good quality h264 for the web i do it the simple way, QT conversion. in qt you can set the size and a lot of things the are more strait forward quick settings. like broadband medium will set your parameters for web steam. fcp is for editing and basic composites. compressor is for size and quality.
samething applies to compressor as far as size and codec. more codec control in

Quote
chris
I am having a lot of problems with the streaming which appears to behave in a sporadic manner with the hosting service I am using (Darwin Streaming Server).

i use swf files 70% of the time for the web. the reason is that it is compatible with 98% of all cpu's. h264 is hands down the best quality on the web in my view but it is not as universal.

i do see that the darwin server is something for developers but i am not knowledgeable enough to know why a person would need it if they simply had a godaddy or ixhost account. our site is dnn so we use a flash8 module.

""" What you do with what you have, is more important than what you could do, with what you don't have."

> > > Knowledge + Action = Wisdom - J. Corbett 1992
""""
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 07, 2007 02:35PM
i get hella quality from my swf files at less within 15-25% of h264.

""" What you do with what you have, is more important than what you could do, with what you don't have."

> > > Knowledge + Action = Wisdom - J. Corbett 1992
""""
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 07, 2007 04:33PM
I have gotten some pretty good looking video on Google (which I understand uses Flash/swf) when I had a uniform background for my subject, or when I had was able to blur the background with wide aperature.

I got interested in Quicktime streaming because I needed to have chapter jumps.

If a Quicktime reference movie can call a swf streaming movie, perhaps I could add chapters to the QT reference movie as I do now?

Google video seems to be a progressive download, but one that is accessible at any point on the time line. I presume that each time one starts at any random pllace on the timeline, a new cache file is written. But I am only guessing.

Are there streaming swf that are true streaming files?

--Cris
Re: Resize and de-interlace prior to encoding. Is this a sensible work flow?
June 07, 2007 04:39PM
Interlaced video is the root of all evil. I wish I had progressive footage to start with. As it turned out, after applying the quick de-interlace filter in FCP , rendering a sequence I tthought was progressive, I still got some jaggies. So I had to use the de-interlace (blur) plus sharpen edges which gave me acceptable results.

Next time, I may simply try de-interlace (blur) along with edge sharpen in Compressor and see how that goes. Interlace (sharp) results in too many jaggies, as does odd or even.
Sorry, only registered users may post in this forum.

Click here to login

 


Google
  Web lafcpug.org

Web Hosting by HermosawaveHermosawave Internet


Recycle computers and electronics