Render/Make 2D perspective alignment issue (camera edited control points)

Hi I am have issues with generating a render that matches my make 2d.

I have manipulated the two-point perspective camera’s control points to force a very vertical perspective and contained the view port to custom 200 width by 400 length. I can create a perfect make 2d of this but the render seems to move the camera angle and alter the framing and crop of the image. Is there a work-around?

thanks!

V-Ray doesn’t pay attention to Rhino’s two point perspective. It can do this though, if you look in visOptions -> Camera -> Physical Camera, you should see a Lens Shift Option. If you figure out how much Rhino is shifting its lens, and plug that into the lens shift, you should have something similar, but so far, I have not found a way to get absolutely exact (although close)

As far as I can tell, the V-Ray shift units are half the portion of the “film plane” to shift. So in your instance, with a 2:1 viewport aspect ratio, Rhino will treat the vertical film dimension as 48mm (Rhino always makes the minimum edge 24mm, so as your height is twice your width, it is 48mm). So if we apply this to V-Ray, with a 48mm tall frame, a value of 1 for the lens shift would shift the lens 24mm (one half of the frame), so it is now aligned with the top or bottom of the film plane.

Because Rhino and V-Ray also seem to treat their frames differently, you also have to override V-Ray’s Focal Length (just override it, and plug in the Rhino lens length, not sure why this matters, but it does), and you need to override V-Ray’s film with, in your case setting it to 24mm.

You are going to want a positive shift number, probably around 0.5 - 0.75 just looking at your images. Let me know if fudging is getting you close enough, or if you want to rather tedious explanation of getting close (but not perfect)

Sam

2 Likes

There is a button at the Vray toolbar. :wink:

But if you don’t like to set the lens shift and only want to know the value, than this old button script helps:

-_RunScript (
Call guess_shift()
Sub guess_shift()
Dim view : view = rhino.CurrentView
If Not rhino.IsViewPerspective(view) Then
rhino.Print "can’t calculate vertical shift for orthogonal views"
Exit Sub
End If
Dim cam : cam = rhino.ViewCameraTarget(view)(0)
Dim tar : tar = rhino.ViewCameraTarget(view)(1)
Dim cam_a : cam_a = cam
Dim tar_a : tar_a = tar
cam_a(2) = tar(2)
tar_a(2) = cam(2)
If rhino.Distance(cam, tar_a) = 0 Then Exit Sub

Dim shift:shift = rhino.Distance(cam, cam_a) / rhino.Distance(cam, tar_a)
If cam(2) > tar(2) Then
	shift = -shift
End If
rhino.Print shift

End Sub
)

3 Likes

awesome, thanks sam! I will give it a go today and let you know how I get on

Really useful, thanks!

Type in visguesslensshift and it will apply the shift you need. One question how you got that camera setting?? meaning instead of a point it actually show a camera and it seems that you were able to lower the horizon point on it. Please I have been cracking my head for a few months. I want to render a 50 stories tall building from not too far but I cant get it all in frame with out making the camera look up.

1 Like