Autodesk.AutoCAD.GraphicsSystem Namespace > View Class
View Class
Description

 

This .NET class wraps the View ObjectARX class. 

 

An View object corresponds to a portion of a GUI window, a set of camera parameters that define a view, and a collection of objects to be viewed. More specifically, an View can be used to represent an AutoCAD viewport. 

 

An View is added to an Device. A view may belong to only a single device at a time. Views need to be told what they are viewing. The client adds and removes (Drawable, Model) pairs corresponding to the viewed piece of the specified model. Each View has a RenderMode that corresponds to the algorithm employed when drawing geometry in that view. 

 

An View has two states: interactive and non-interactive. By default, an View is non-interactive. This means that all methods are executed immediately upon calling and return only when completed. All return values are trustworthy and all methods can be invoked. 

 

A call to BeginInteractivity transforms an View into the interactive state as well as specifying a frame rate that the view will attempt to maintain (or exceed). To do this, it queues up all view modifications and update calls, handling them asynchronously. It is important to observe here that the minimum acceptable frame rate is often different from the user input rate (such as how fast the mouse is sampled). As a result of the queuing and asynchronous processing of view modifications, it is not safe to call methods that query the view state or modify the view state (such as add() or remove()). The only reliable calls are SetViewportFromView(), SetView(), EnableFrontClip, FrontClip, EnableBackClip, BackClip, Mode, Dolly(), Roll(), Orbit(), Zoom(), Pan(), Update(), Flush(), and EndInteractivity(). At the return from a call to EndInteractivity(), an interactive View will have been transformed to a non-interactive state. 

 

View objects support front and back clipping planes. These planes are view-aligned; their normals are coincident with the eye vector. The planes maintain this orientation throughout modifications to the eye vector (in other words, they remain view-aligned). When the front clipping plane is enabled, it cuts all geometry in the direction specified by traveling from the camera target to the camera position. Conversely, when the back clipping plane is enabled, it cuts all geometry in the direction specified by traveling from the camera position to the camera target. 

 

The View class should be used for accessing the full-view description in perspective mode. It contains all the necessary query functions for the view definition, clipping planes, and view matrices.

Class Hierarchy
Autodesk.AutoCAD.GraphicsSystem.View
Visual Basic
Public Class View
Inherits DisposableWrapper
C#
public class View : DisposableWrapper;
Links
See Also

Drawable, Device, Model, Configuration, Manager

   Comments?