cee::vis::Model
-
class Model : public RefCountedObject
Model holds information which is to be gathered to constitute a view.
CEETRON Envision offers several types of models. Model is the base class of all model types. UnstructGridModel is a subclass of Model which adds specific model structure and functionality for representing scientific and engineering models, e.g. finite element data. Other model types are MarkupModel and GeometryModel.
Each view can contain one or more models. See the Model for more information.
Tutorials
Subclassed by GeometryModel, UnstructGridModel, MarkupModel
Public Functions
-
Model()
Constructs an empty model.
-
void setName(const Str &name)
Sets the name of the model.
The name of the model is not used by CEETRON Envision, but can be used by the user to track and debug applications with lots of models.
-
bool use2dPixelProjection() const
Returns true if the model is using a 2D pixel exact projection to render its content.
See also
-
void setUse2dPixelProjection(bool use2dMode)
Specify if this model should use an override camera to render 2D sceen aligned data.
Use this method to enable 2D rendering of items from the MarkupModel and the Geometry model. The items will be fixed in the specified coordinates on the screen and will not change if the user modifies the camera by panning, rotating or zooming.
If enabled, all items in the model will be rendered in an Orthographic projection with the viewport setup to match the screen (OpenGL based) coordinates of the host window. The items in the model will be rendered on top of all other contents of the view, but it is still possible to use the z buffer for ordering within the models with this option enabled.
The x and y coordinate of the cee::Vec3d will be screen coordinates (OpenGL based window coordinates with lower left as origin) and the z coordinate will be used to determine which object to be visible if they overlap. The one with the largest z coordinate will win and be shown.
-
virtual BoundingBox boundingBox() = 0
Returns the model’s bounding box.
Protected Types
Protected Functions
-
void notifyObservingViews(NotifyAction notifyAction, const View *exceptView)
Sends a notification to all observing views.
-
bool hasAnyObservingViewsWithClipping(bool *outExplicitViewClippingIsActive = NULL, bool *outDropShadowClippingIsActive = NULL) const
Returns true if the model is a being viewed in any views where clipping is enabled (either view clipping or shadow clipping)
-
Model()