Whither Smart Resample

amendegw wrote on 1/9/2012, 5:28 AM
This post: Project & render settings for YouTube from 60p? got me to thinking about "Smart Resample" - the default setting for video events.

In my work, I've found that "Smart Resample" has produced more problems than it solves. For example, when rendering to differing framerates or slowing down video events (e.g. cntl-drag or Velocity Envelope), "Disable Resample" must be set or the render quality degrades.

As a matter of fact, I can't think of a single instance where "Smart Resample" or "Force Resample" has helped my render.

So... I'd like to start a discussion on "Smart Resample"

1) Is "Smart Resample" really the desired default setting for video events?
2) Is there any way to change the default to "Disable Resample" (I know you can right click on multiple events and change resampling).
3) Do I even know what I'm talking about? Don't answer that! It's just a rhetorical question!

...Jerry

btw: In recent history, I almost exclusively shoot in 1920x1080 60p, and render for web delivery. May (or may not) be relevant to this discussion.

btw2: I just noticed I'd misspelled "whither" - I can change the "Subject title here, but not on the main thread listing.

System Model:     Alienware M18 R1
System:           Windows 11 Pro
Processor:        13th Gen Intel(R) Core(TM) i9-13980HX, 2200 Mhz, 24 Core(s), 32 Logical Processor(s)

Installed Memory: 64.0 GB
Display Adapter:  NVIDIA GeForce RTX 4090 Laptop GPU (16GB), Nvidia Studio Driver 566.14 Nov 2024
Overclock Off

Display:          1920x1200 240 hertz
Storage (8TB Total):
    OS Drive:       NVMe KIOXIA 4096GB
        Data Drive:     NVMe Samsung SSD 990 PRO 4TB
        Data Drive:     Glyph Blackbox Pro 14TB

Vegas Pro 22 Build 239

Cameras:
Canon R5 Mark II
Canon R3
Sony A9

Comments

Chienworks wrote on 1/9/2012, 5:47 AM
1) I quite agree. I find the blending of frames to be much more objectionable than having frames duplicated or dropped.

2) It's been asked for on occasion. It may be one of the numerous hex-encoded options in internal preferences but i haven't tried enough of them to find out yet.

3) I believe you do. There seems to be a pervasive feeling that smooth motion is the most important thing so Vegas defaults to it's own way of doing so. However, frame blending is not a good way to achieve it.
Andy_L wrote on 1/9/2012, 9:18 AM
A 'disable resample' checkbox in render options would make life a lot easier...
Chienworks wrote on 1/9/2012, 9:39 AM
I'd rather have it at the project level (though both would be nice). It can heavily affect previewing just as much as rendering.
amendegw wrote on 1/9/2012, 9:48 AM
Okay, I didn't want to post this until others confirmed that a need existed, but I wrote a little script that might help others: SetResample.zip

Enjoy!
...Jerry

System Model:     Alienware M18 R1
System:           Windows 11 Pro
Processor:        13th Gen Intel(R) Core(TM) i9-13980HX, 2200 Mhz, 24 Core(s), 32 Logical Processor(s)

Installed Memory: 64.0 GB
Display Adapter:  NVIDIA GeForce RTX 4090 Laptop GPU (16GB), Nvidia Studio Driver 566.14 Nov 2024
Overclock Off

Display:          1920x1200 240 hertz
Storage (8TB Total):
    OS Drive:       NVMe KIOXIA 4096GB
        Data Drive:     NVMe Samsung SSD 990 PRO 4TB
        Data Drive:     Glyph Blackbox Pro 14TB

Vegas Pro 22 Build 239

Cameras:
Canon R5 Mark II
Canon R3
Sony A9

PeterDuke wrote on 1/9/2012, 5:51 PM
"I just noticed I'd misspelled "whither""

So can we go back to "wither" as an imperative?
amendegw wrote on 1/9/2012, 6:02 PM
Hmmm...

wither = Become dry and shriveled

whither = To what end or purpose?

maybe both apply? [chuckle]

...Jerry

System Model:     Alienware M18 R1
System:           Windows 11 Pro
Processor:        13th Gen Intel(R) Core(TM) i9-13980HX, 2200 Mhz, 24 Core(s), 32 Logical Processor(s)

Installed Memory: 64.0 GB
Display Adapter:  NVIDIA GeForce RTX 4090 Laptop GPU (16GB), Nvidia Studio Driver 566.14 Nov 2024
Overclock Off

Display:          1920x1200 240 hertz
Storage (8TB Total):
    OS Drive:       NVMe KIOXIA 4096GB
        Data Drive:     NVMe Samsung SSD 990 PRO 4TB
        Data Drive:     Glyph Blackbox Pro 14TB

Vegas Pro 22 Build 239

Cameras:
Canon R5 Mark II
Canon R3
Sony A9

john_dennis wrote on 1/9/2012, 6:32 PM
This is the event that got me thinking about resample. Before this, I was blissfully ignorant that such a parameter existed. If essami never does anything else for mankind, I will be forever in his debt for causing me to look at it.

I ended up disabling resample and using 720p60 on Blu-ray for the video from this source. Now I just accept 640x480-30p to keep from having to deal with the 15 fps issue. Some day I'm going to stop shooting video with a still camera.
rs170a wrote on 1/9/2012, 6:34 PM
There's also whether (which seems truly appropriate these days :)

Whether 'tis nobler in the mind to suffer
The slings and arrows of outrageous fortune,
Or to take arms against a sea of troubles,
And by opposing end them? To die: to sleep;
No more; and by a sleep to say we end
The heart-ache and the thousand natural shocks
That flesh is heir to, 'tis a consummation
Devoutly to be wish'd.

Mike
PeterDuke wrote on 1/9/2012, 8:25 PM
Don't stop at "whether". There is also

weather, which can be as unpredictable as Vegas, and

wether, a sheep that is cut out to never be a father. Perhaps this applies to some features such as smart rendering AVCHD and Blu-ray on DVD that have been docked lately.
NickHope wrote on 1/9/2012, 10:49 PM
GREAT script Jerry!

Please take up Vegas scripting full time. With the logical way you approach user-friendliness and functionality in Vegas, I reckon you could come up with some crackers.

p.s. I now have this on the brain. Could be worse.

amendegw wrote on 1/10/2012, 4:04 AM
"Please take up Vegas scripting full time..."Ha! Thanks for the compliment, I'm really a newbie when it comes to scripting. Here's my workflow...

1) Look at how I did similar stuff in previous scripts,
2) Read a little about what others have done,
3) Read the class library documentation (Why can't they throw in some examples? Or at least give us some better definitions)
4) Try it, ah... that doesn't work,
5) Back to 1)
6) Darn, it still doesn't work
7) Looks like a .NET problem?
8) Google the issue.
9) Ahh.... that seems to fix it.
10) Test several scenarios.
11) Seems to work and doesn't break anything - do I dare share with others?
12) Phew! That was painful - lucky I'm retired and have time to do this.

Well, that was rather tongue-in-check, but I must say I'm really in awe of the jetdv's, johnnyroy's, johnmeyer's, rosebud's of the world (I'm sure there are more) when it comes to scripting.

...Jerry

System Model:     Alienware M18 R1
System:           Windows 11 Pro
Processor:        13th Gen Intel(R) Core(TM) i9-13980HX, 2200 Mhz, 24 Core(s), 32 Logical Processor(s)

Installed Memory: 64.0 GB
Display Adapter:  NVIDIA GeForce RTX 4090 Laptop GPU (16GB), Nvidia Studio Driver 566.14 Nov 2024
Overclock Off

Display:          1920x1200 240 hertz
Storage (8TB Total):
    OS Drive:       NVMe KIOXIA 4096GB
        Data Drive:     NVMe Samsung SSD 990 PRO 4TB
        Data Drive:     Glyph Blackbox Pro 14TB

Vegas Pro 22 Build 239

Cameras:
Canon R5 Mark II
Canon R3
Sony A9

amendegw wrote on 1/10/2012, 4:05 AM
One more thing - keep them puns coming! That's my kind of humor.

...Jerry

Edit (2012-02-13):

I've done some more testing here and want clarify my recommendations - just so folks reading my comments are not lead astray.

Recently, I've started shooting with a high shutter speed it improve the motion blur artifacts that occur when performing a "Rock Steady" stabilization via Mercalli V2. If I render this fast shutter footage to a different framerate, (to my eyes) "disable resample" visually improves the renders.

However, if my source footage is at a low shutter speed, the source footage contains motion blur. While the stabilization looks like crap (a technical term), the smoothness of motion in the resampled renders actually look better (again, to my old eyes) than those with "Disable Resample" applied.

So, what's the bottom line? There's no one answer for everything. Best advice is to do some test renders on your project and see what looks best.

Hope I haven't mislead anyone,
...Jerry

System Model:     Alienware M18 R1
System:           Windows 11 Pro
Processor:        13th Gen Intel(R) Core(TM) i9-13980HX, 2200 Mhz, 24 Core(s), 32 Logical Processor(s)

Installed Memory: 64.0 GB
Display Adapter:  NVIDIA GeForce RTX 4090 Laptop GPU (16GB), Nvidia Studio Driver 566.14 Nov 2024
Overclock Off

Display:          1920x1200 240 hertz
Storage (8TB Total):
    OS Drive:       NVMe KIOXIA 4096GB
        Data Drive:     NVMe Samsung SSD 990 PRO 4TB
        Data Drive:     Glyph Blackbox Pro 14TB

Vegas Pro 22 Build 239

Cameras:
Canon R5 Mark II
Canon R3
Sony A9

farss wrote on 2/13/2012, 5:03 PM
Jerry,
I think what you first need to do (if you haven't already) is to get your head around what Resampling in Vegas does. Then grasp that Force On / Off or Samrt is only controlling if that is invoked or not.

Basically how Vegas does its thing is to look for the frame that belongs at the current tick on the timeline.
If it can find an exact match it uses that frame. If your media's fps exactly matches the projects fps this will always be the case unless you've managed to have unquantized frames... which isn't all that hard to do by mistake in Vegas :(

If Vegas cannot find an exact match:
If Resample is enabled it creates a new frame by blending the two nearest frames. The blending ratio is determined by how far way the two frames are from the current tick.
If Resample is disabled it uses the nearest frame. This can mean frames will be duplicated.

Smart Resampling simply switches Resampling on or off based on the source footage fps matching the project fps.


Regarding your deliberations on shutter speed:

There are too many variables at play. You run a considerable risk of misleading yourself, rather like trying to find the molecular formula for coffee or chocolate :)

First and foremost you need to consider what the lens itself is doing. That is what controls the quality of the image that reaches the sensor so you cannot afford to ignore it. In general all but the most extremely expensive zoom lenses yield the highest resolution image at around the middle of their focal length and at a couple of stops below the iris being wide open. The other complication is if you close the iris too far the defraction caused by the light passing through the small hole that is the iris, affects image quality. For a small sensor camera this is a considerable limitation. Combine the two factors and you get a pretty small "sweet spot". That means there's a limited range of focal lenghts and iris openings (f stop) at which the image projected by the lens onto the sensor will be as good as it can be.

Taking that on board you can see that if you change shutter speed the iris has to open or close to keep the same amount of light reaching the sensor. That alone in a completely static shot is likely to affect image quality.

Now you might think the above has absolutely nothing to do with how motion looks but it does, yikes what a mess, our coffee syrup is not at all simple to make taste good :)
Image quality, not just simple resolution but MTF, has an impact on how we perceive motion. Our eye / brain system works mostly by looking at edges. So a very sharp image in motion is more likely to show up problems in how we perceive motion. If you doubt the veracity of this claim look at the number of people here having issues when they animate text. All generated media has a high MTF, it is tack sharp and between two adjoining pixels the contrast can be as high as it gets. Of course the impact of image MTF when you use a camera is not as dramatic but it is still a factor to consider. It also depends on what is in front of the camera of course.
In summary if you want to compare apples to apples you can't do that when the apple is in a fruit salad.

Bob.