Camera Object
Description
The Camera defines the view of the model shown within the window.
Methods
Apply |
Method that causes the changes made to the Camera object to be applied to the actual camera of the view. This will also cause the view to update. |
ApplyWithoutTransition |
Method that applies the current camera to the View without transition. |
ComputeWithMouseInput |
Method that changes the view according mouse movement and view operation. |
CreateImage |
Creates an image based on the current camera view. |
CreateImageWithOptions |
Creates an image based on the current camera view with options. |
Fit |
Method that fits all the contents of the Document into the view. |
GetExtents |
Method that gets the current extents of the camera. The camera extents define the area within the model that is visible in the view. |
ModelToViewSpace |
Method that converts a point in model space to the equivalent point on the view. |
SaveAsBitmap |
Method that saves the current camera view to the specified file. The width and height arguments define the aspect ratio and the number of pixels in the output image.
The CreateImage method is similar to this but instead of writing the image to a file it creates it in memory, which is more efficient than writing and reading if from disk if you need to use the image immediately. |
SetExtents |
Method that sets the current extents of the camera. The camera extents define the area within the model that is visible in the view. Setting the extents results in the camera zooming in or out. The Apply method of the camera must be called before any changes are shown in the view. |
ViewToModelSpace |
Method that converts a point in view space to the equivalent point in the model. |
Properties
Eye |
Specifies the position of the observer's 'Eye' (View's center). |
ModelToViewTransformation |
Read-only property that returns the transformation matrix from model space to view space. |
Parent |
Property that returns the parent object of the camera. |
Perspective |
Gets/Sets a boolean flag indicating whether Perpspective viewing is on/off. |
PerspectiveAngle |
Gets/Sets the Perspective Angle. |
SceneObject |
Get/Set the contents of the scene for a camera. This is applicable only when the Camera is created from the TransientObjects.CreateCamera. Valid objects that can be set to this property are: ComponentDefinition, Sheet, and PresentationScene. |
Target |
Specifies the position of the Target point the observer's viewing in the scene (View's Z-axis). |
Type |
Returns an ObjectTypeEnum indicating this object's type. |
UpVector |
Specifies the vector defining what is 'up' for the observer. |
ViewOrientationType |
Gets/Sets the type of orientation of the camera (Top, Iso, etc. or arbitrary). |
Accessed From
ClientView.Camera,
DesignViewRepresentation.Camera,
DetailDrawingView.Camera,
DrawingView.Camera,
PresentationSequence.Camera,
PresentationSnapshotView.SavedCamera,
Publication.InitialCamera,
PublicationMarkedView.Camera,
SectionDrawingView.Camera,
TransientObjects.CreateCamera,
View.Camera
Samples
Drive the camera |
This sample will fly the camera around the model. To simplify the code, the target is hard coded at the origin and the up vector is the positive Z. |
OnDrag Event - dragging a WorkPoint |
This sample demonstrates the use of the OnDrag event to drag fixed work points when no command is active. This sample only allows drags parallel to the X-Y plane. This sample is dependent on events and VB only supports events within a class module. |
Version
Introduced in version 4