Eyeshot 10 WinForms API Reference
ViewportLayout Class Methods


WinForms Assembly > devDept.Eyeshot Namespace : ViewportLayout Class

For a list of all members of this type, see ViewportLayout members.

Public Methods
 NameDescription
Public MethodOverloaded.  For internal use only.  
Public Method Adjusts camera near and far planes based on model extents and on origin symbol, grid and shadow visibility status.  
Public MethodOverridden.   
Public Method Stops the asynchronous background work.  
Public MethodChecks the size on screen of the top level entities and hides the ones smaller that SmallSize, if HideSmall is true.  
Public Method Clears all the viewport master collections: blocks, entities, materials, labels and layers.  
Public MethodOverloaded.  Executes a 3D scene visual testing.  
Public MethodOverloaded.  Compiles 3D user interface elements like the origin symbol, the bitmap background, the FEM restraint and load symbols, etc.  
Public MethodCopies all items inside control master collections (Entities, Labels, Blocks, Layers, Materials, TextStyles, LineTypes) to the specified ViewportLayout.  
Public MethodOverloaded.  Copies a raster image of the current viewport scene on the clipboard.  
Public Method Copies a vectorial image of the current scene of the active viewport on the clipboard.  
Public Method Create a bitmap for the image comparison.  
Public Method Deactivates the product.  
Public Method For internal use only.  
Public Methodstatic (Shared in Visual Basic)  
Public MethodAccomplishes the work.  
Public MethodDraws a text on the ViewportLayout's client area.  
Public MethodOverridden.   
Public Methodstatic (Shared in Visual Basic) Evaluates the bounding box of a collection of entities without taking care of entity visibility.  
Public MethodOverloaded.  Extrudes a text creating an array of new solids.  
Public MethodOverloaded.  Finds the closest triangle to the viewer of the specified entity.  
Public MethodOverloaded. Looks for the model vertex whose 2D screen projection is closer to the mouse cursor skipping entities different from entType.  
Public MethodOverloaded. Looks for the model vertices whose 2D screen projections are closer to the mouse than the maxDistance.  
Public Method Returns the list of all the visible and selectable entities geometrically crossing the selection box, regardless of their actual visibility on screen.  
Public Method Selects all entities completely enclosed in the specified selection rectangle.  
Public Method Returns all the visible (on screen) top level and selectable entities (which may include the parents stack for nested entities) under the mouse cursor in the active viewport.  
Public Method Returns all the visible (on screen) and selectable entities (which may include the parents stack for nested entities) under the mouse cursor in the active viewport.  
Public Method Returns all the visible labels under the mouse cursor in the active viewport.  
Public Method Returns the list of all visible entities in the specified selection box in the active viewport.  
Public Method Returns the list of all visible entities (which may include the parents stack for nested entities) in the specified selection box in the active viewport.  
Public Method Returns the list of all visible labels in the specified selection box.  
Public Methodstatic (Shared in Visual Basic) Gets the currently loaded assembly.  
Public Method Gets the default cursor for the viewport control.  
Public Method For internal use only.  
Public Methodstatic (Shared in Visual Basic) Returns the entity's linetype pattern.  
Public Method Returns the index of the first top level entity under the mouse cursor.  
Public Method Gets the first item under the mouse cursor (which may include the parents stack for nested entities).  
Public Method Returns the index of the first label under the mouse cursor.  
Public Method Gets the color of the specified pixel in this viewport  
Public Method Gets the plane used to draw the planar reflections.  
Public Method Returns a thumbnail bitmap of the whole viewportLayout. The maximum size is 256x256.  
Public Method Creates a single unit from selected entities.  
Public MethodOverridden. Ensures that at least one Viewport is present in the Viewports collection.  
Public MethodOverloaded.  Invalidates the entire surface of the control and causes the control to be redrawn.  
Public MethodOverridden.  Gets a boolean indicating whether the control is running at design time.  
Public MethodOverridden.   
Public MethodOverloaded.  For internal use only.  
Public MethodOverridden.  Gets the Pick Cursor stream.  
Public MethodOverloaded. 

Restores the current scene from disk, including entities, textures, blocks and labels.

 
Public Methodstatic (Shared in Visual Basic)Overloaded.  Triangulates the specific region.  
Public Methodstatic (Shared in Visual Basic)Analyzes a number of entities and returns a closed loop of points starting from the entity at startIndex. You can provide an array of 100 entities an get a 3D loop of a square made up of 4 lines. Entities connection is checked using chordalError parameter, if the end points of two entities are farther of this value they will not be connected.  
Public Methodstatic (Shared in Visual Basic) Returns a closed loop of points at the specified distance.  
Public MethodOverloaded.  Moves a list of entities from plane XY to the specified plane.  
Public MethodRestores the next view previously saved on the Viewport.SavedViews stack.  
Public Method Orients the Camera between the two specified points.  
Public MethodOpens the Page Setup dialog.  
Public MethodOverloaded.  Pans the view from one screen point to the other.  
Public Method Pans the view downwards.  
Public Method Pans the view to the left.  
Public Method Pans the view to the right.  
Public Method Pans the view upwards.  
Public MethodOverloaded. Overridden.   
Public MethodRestores the previous view on the Viewport.SavedViews stack.  
Public MethodComputes the hidden lines and opens the Print dialog.  
Public MethodComputes the hidden lines and opens the Print Preview dialog.  
Public Method Selects each entity crossing the specified selection rectangle.  
Public Method Selects each entity completely enclosed in the specified selection rectangle.  
Public Method Selects only visible entities in the specified rectangle.  
Public Method Selects only visible labels in the specified rectangle.  
Public MethodOverloaded. Creates a block with the selected Entities, computes the center of their bounding box, translates them all of the negative of that quantity and returns a BlockReference to that block.  
Public MethodOverloaded. Returns an image of the current ViewportLayout scene. The image can be scaled even to a poster size one.  
Public Method Restores the previously saved view in the active viewport.  
Public Method  
Public MethodOverloaded. Sets the view direction as the normal of the plane under the mouse cursor.  
Public Method Rotates the view downwards.  
Public Method Rotates the view to the left.  
Public Method Rotates the view to the right.  
Public Method Rotates the view upwards.  
Public MethodOverloaded.  Saves the current scene on disk, including entities, textures, blocks and layouts.  
Public MethodOverloaded. Saves the current view on the Viewport.SavedViews stack.  
Public Method Scales the element for high DPI settings.  
Public MethodOverloaded.  Maps screen coordinates to world coordinates in the active viewport.  
Public MethodOverloaded.  Maps screen coordinates to world coordinates.  
Public Methodstatic (Shared in Visual Basic)  
Public Method Sets a coded color depending on the entity id.  
Public Method Sets a coded color depending on the entity id.  
Public Methodstatic (Shared in Visual Basic) Rendered mat changer.  
Public Methodstatic (Shared in Visual Basic) Shaded color changer.  
Public Method Sets the cursor.  
Public Method Sets the default cursor for the viewport control.  
Public MethodOverridden.   
Public Method Sets the parents stack that represents the starting point for the selection.  
Public MethodOverloaded. Sets the view direction of the camera to the specified direction.  
Public Method  
Public MethodOverloaded. 

Starts the animation timer. After calling this method the Animate method of all the entities is called periodically to allow the computation of the new entity position.

To animate group of entities the recommended approach is the following:

  1. Create groups of moving objects (using Block class and adding entities to the Block.Entities collection)
  2. Add blocks created at point 1) to the Blocks collection
  3. Subclass the BlockReference class for each moving group of objects
  4. Override the BlockReference.MoveTo() method of the class at point 2) and add the code to move the objects at that specific time frame
  5. Add the block references created at point 4) to the Entities collection
  6. Call StartAnimation() providing the time interval between each frame
  7. Call StopAnimation() to stop the animation
 
Public Method Starts the work asynchronously.  
Public MethodStops the animation timer. Call base class method when overriding.  
Public Method For internal use only.  
Public Method Suspends the updates of ViewportLayout.  
Public Method Removes the group status from the specified group.  
Public Method Validates the license for runtime usage.  
Public Method Used by the designer to update the graphics.  
Public Method Updates the viewport in both desing-time and run-time mode. If necessary adjust near and far planes to accomodate origin symbols of various sizes.  
Public MethodUpdates the Viewports dimensions and locations depending on the LayoutMode property.  
Public MethodThis method needs to be called before using one of the visible selection action modes or one of the methods that get the entities (or labels) under the mouse cursor if the devDept.Eyeshot.Entities.Entity.Visible or the devDept.Eyeshot.Entities.Entity.Selectable (or devDept.Eyeshot.Labels.Label.Visible or devDept.Eyeshot.Labels.Label.Selectable in case of labels selection) changed and the camera was not moved.  
Public MethodOverridden.   
Public MethodOverloaded.  Maps world coordinates to screen coordinates.  
Public MethodOverloaded. Saves a raster image of the current viewport scene on disk.  
Public Method Saves a vectorial image of the current scene of the active viewport on disk in EMF format.  
Public MethodOverloaded.  Zooms the view of the specified amount.  
Public MethodOverloaded.  Fits the entire model in the viewport control's client area.  
Public MethodOverloaded.  Fits the selected entities, including the ones inside BlockReferences.  
Public Method Zooms the view in.  
Public Method Zooms the view out.  
Public Method Zooms to the specified window.  
Top
Protected Methods
 NameDescription
Protected Method For internal use only.  
Protected Internal Method  
Protected Internal Method Gets the color used to draw the given non-current entity.  
Protected Method Draws model, shadow and bounding box.  
Protected Internal Method Draws the Background of the ViewportLayout control.  
Protected Internal MethodDraws an image on the ViewportLayout's client area.  
Protected Method Draws overlaying UI elements.  
Protected Method Main drawing method.  
Protected Method Draws the model shadow  
Protected Internal MethodOverloaded. Draws a text on the ViewportLayout's client area.  
Protected Method Draws a texture.  
Protected Method  
Protected Method Draws the vertices of the entities.  
Protected Internal Method Draws the viewport.  
Protected Method Draws the viewport background and reflections.  
Protected Method Starts a sequence of Zoom-Pan-Rotate movements.  
Protected MethodRaises the ProgressChanged event.  
Protected MethodRaises the WorkCancelled event.  
Protected MethodRaises the WorkCompleted event.  
Protected MethodRaises the WorkCancelled event.  
Protected MethodOverridden.   
Protected Method Returns the list of all the visible and selectable entities crossing the specified selection box.  
Protected Methodstatic (Shared in Visual Basic) Gets the entity line weight.  
Protected Method Gets the text bitmap.  
Protected Internal Methodstatic (Shared in Visual Basic) Gets the outlined text image.  
Protected Method Returns the viewport under the given mouse position.  
Protected Internal Method Returns the indices of the entities read from the back buffer in the selectionBox.  
Protected Internal MethodTells if the projected point, whose square distance from the mouse cursor is squareDistance, is closer than the currentMinimumSquareDistance.  
Protected MethodTells if the current ActionMode requires dragging.  
Protected MethodOverridden.   
Protected MethodTells if the current ActionMode is one of the ByBox ones.  
Protected MethodTells if the current ActionMode is one of the ByPick ones.  
Protected MethodTells if the current ActionMode is one of the ByPolygon ones.  
Protected MethodOccurs every timer tick. Call base class method when overriding.  
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden. Synchronize hasFocus parameter, reset action, redraw the control.  
Protected Internal MethodOccurs every Mouse3DButtonDown event.  
Protected Internal MethodOccurs every Mouse3DButtonUp event.  
Protected Internal MethodOccurs every Mouse3DMove event.  
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected MethodOverridden.   
Protected Internal MethodOccurs every MultiTouchClick event.  
Protected Internal MethodOccurs every MultiTouchDoubleClick event.  
Protected Internal MethodOccurs every MultiTouchDown event.  
Protected Internal MethodOccurs every MultiTouchMove event.  
Protected Internal MethodOccurs every MultiTouchUp event.  
Protected MethodOverloaded. Overridden.   
Protected MethodOverridden.   
Protected Internal Method Paints the viewport surface without redrawing the whole scene.  
Protected Method  
Protected Method Selects each entity crossing the specified selection polygon.  
Protected Method Selects each entity completely enclosed in the specified selection rectangle.  
Protected Method Selects each visible entity in the specified selection polygon.  
Protected Method Resizes the Viewports.  
Protected Internal Method  
Protected Internal Method  
Protected Method Sorts the transparent entities from the farthest to the nearest to the camera for better rendering.  
Protected Internal Method Starts a sequence of Zoom-Pan-Rotate movements if the proper keys/mouse buttons are pressed.  
Protected Internal Method Swaps the front and back buffers.  
Top
See Also

Reference

ViewportLayout Class
devDept.Eyeshot Namespace