Click or drag to resize

ViewportInfoSetScreenPort Method (Int32, Int32, Int32, Int32, Int32, Int32)

Location of viewport in pixels. These are provided so you can set the port you are using and get the appropriate transformations to and from screen space. // For a Windows window / int width = width of window client area in pixels; / int height = height of window client area in pixels; / port_left = 0; / port_right = width; / port_top = 0; / port_bottom = height; / port_near = 0; / port_far = 1; / SetScreenPort( port_left, port_right, / port_bottom, port_top, / port_near, port_far );

Namespace:  Rhino.DocObjects
Assembly:  RhinoCommon (in RhinoCommon.dll)
Syntax
public bool SetScreenPort(
	int left,
	int right,
	int bottom,
	int top,
	int near,
	int far
)

Parameters

left
Type: SystemInt32
A left value.
right
Type: SystemInt32
A left value. (port_left != port_right)
bottom
Type: SystemInt32
A bottom value.
top
Type: SystemInt32
A top value. (port_top != port_bottom)
near
Type: SystemInt32
A near value.
far
Type: SystemInt32
A far value.

Return Value

Type: Boolean
true if input is valid.
Version Information

Rhino for Mac

Supported in: 5.4

Rhino for Windows

Supported in: 6.5
See Also