How to render pixels beyond frame

Started by Gedred, June 07, 2019, 11:23:19 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Gedred

Hi, I want to render an image with the set aspect ratio, however I want some slack in the image. I can't do this by dragging the view screen further out as it changes the camera.

How do I render a view pixels beyond my chosen camera position ?


Thanks guys.

andy.engelkemier

This is often called creating an overscan. Keyshot isn't the Most friendly of software for it, but it's not too bad.

It just requires a little math. You Usually do this on the focal length, but keyshot doesn't let you do that because changing the focal length inversely changes the field of view. This is Fantastic when you want to change perspective without changing your camera. It's not great when you want to change your resolution.

So here goes:

Step one, link your resolution, and make it smaller. I'll explain this one. Keyshot doesn't let you put in a value that's larger than what your screen can display. With my project menu open, it'll max out at 1482, so I can't put 1500. So, before trying to make my camera bigger, I need to make sure it will fit.
My camera was 1600x1200. Of course, it displays as 1321x991. I want it to be 2:1 so it would be 2400x1200. I wouldn't Want to take it to 800x600 for easy math, but that's not going to fit. I can only fit 1482 wide. Like i said, keyshot doesn't like to make this easy. So I'll take it down to 933x700, because 1400x700 will fit on my screen.

Now unlink the resolution, and change the width to your intended width. You're framing will now be wrong. This is where we fix it.

Here's the math: newWidth/oldWidth*Field of View = new Field of view.

So in my case: 1400/933*44.26 = 66.4137

Just change the field of view, and your camera will go right back into place.

I wish this were just a tool inside keyshot because you don't want to count on this being pixel perfect. There will be rounding errors. Yeah, your object won't really move, but the pixels won't be exactly the same.
I'm not a talented programmer, but someone that is could probably knock out a python script for this while they eat lunch. Any takers?

BTW, this works in reverse as well. If you're making it more narrow.

Warning: You need to include the camera changes in undo, in preferences, if you want to undo any of this. But it won't let you undo resolution. So write that down, and save a copy of your camera first. I either stick to only one aspect ratio per file, OR include that in the name of the camera. Keyshot doesn't let you set different aspect ratios for different camera (yet?)

Gedred

Works perfectly, thanks Andy - your a godsend!

andy.engelkemier

I complain a lot. So I try and help out the community occasionally so the team at keyshot isn't annoyed with me Too much.