Hi,
I am working on an optimization project, where I am varying my ship hull at every iteration. I would like to capture the variations as images and create a movie using them. I am able to capture the image using -_ViewCaptureToFile
function, but unable to set the display option and zoom properly. You can see that the ship bow got cut in the saved image.
I would like to show the 1. whole ship
and 2. The forward part of the ship
. And also want to show the curves.
Can someone help me with this. Thanks for your help.
~Amitava
Sub saveImage(imgPath, imgName)
Rhino.UnselectAllObjects
Rhino.Command "_setActiveViewport perspective"
Rhino.Command "-_SetDisplayMode _Viewport=Active _Mode=Ghosted"
Rhino.Command "-_Zoom _Extents"
Call Rhino.Command("_-ViewCaptureToFile " & chr(34) & imgPath & imgName & chr(34) & " " & ViewParamString() & " _Enter _Enter", True)
End Sub
Function ViewParamString()
Dim params
params = params & "_Width=" & 800 & " "
params = params & "_Height=" & 400 & " "
params = params & "_Scale=" & 1 & " "
params = params & "_DrawGrid=_" & "No" & " "
params = params & "_DrawWorldAxes=_" & "No" & " "
params = params & "_DrawCPlaneAxes=_" & "No" & " "
params = params & "_TransparentBackground=_" & "No" & " "
ViewParamString = params
End Function