#include <representation.h>
Inheritance diagram for VIEW::Representation:

Public Types | |
Enums | |
| enum | Properties { PROPERTY__ALWAYS_FRONT = 0, PROPERTY__IS_COORDINATE_SYSTEM } |
| Properties. | |
Public Member Functions | |
Constructors and Destuctor | |
| Representation () throw () | |
| Default Constructor. | |
| Representation (ModelType model_type, DrawingPrecision drawing_precision, DrawingMode drawing_mode) throw () | |
| Representation (const Representation &representation) throw () | |
| Copy constructor. | |
| virtual | ~Representation () throw () |
| Destructor. | |
Predicats and Accessors | |
| const Representation & | operator= (const Representation &rep) throw () |
| void | clear () throw () |
| Clears all properties. | |
| void | setHidden (bool state) throw () |
| bool | isHidden () const throw () |
| void | setDrawingPrecision (DrawingPrecision precision) throw () |
| DrawingPrecision | getDrawingPrecision () const throw () |
| float | getSurfaceDrawingPrecision () const throw () |
| void | setSurfaceDrawingPrecision (float precision) throw () |
| void | setDrawingMode (DrawingMode mode) throw () |
| DrawingMode | getDrawingMode () const throw () |
| Size | getTransparency () const throw () |
| get transparency (0 - 255) | |
| void | setTransparency (Size value) throw () |
| set transparency (0 - 255) | |
| const GeometricObjectList & | getGeometricObjects () const throw () |
| GeometricObjectList & | getGeometricObjects () throw () |
| void | setGeometricObjects (GeometricObjectList &gol) throw () |
| void | insert (GeometricObject &object) throw () |
| const List< const Composite * > & | getComposites () const throw () |
| void | setComposites (const List< const Composite * > &composites) throw () |
| void | setComposite (const Composite *composite) throw () |
| const ModelProcessor * | getModelProcessor () const throw () |
| ModelProcessor * | getModelProcessor () throw () |
| void | setModelProcessor (ModelProcessor *processor) throw () |
| ColorProcessor * | getColorProcessor () throw () |
| void | setColorProcessor (ColorProcessor *processor) throw () |
| void | setModelType (ModelType type) throw () |
| ModelType | getModelType () const throw () |
| String | getName () const throw () |
| void | setName (const String &name) throw () |
| void | setColoringMethod (ColoringMethod type) throw () |
| ColoringMethod | getColoringMethod () const throw () |
| void | enableModelUpdate (bool state) |
| void | enableColoringUpdate (bool state) |
| bool | modelUpdateEnabled () const |
| bool | coloringUpdateEnabled () const |
| String | getProperties () const throw () |
| Get a descpription string (nr triangles and geometric objects, transparency, mode). | |
| bool | isValid () const throw () |
| Check if drawing mode, transparency and drawing precision have reasonable values. | |
| void | update (bool rebuild) throw () |
| Apply ModelProcessor (if rebuild) and ColorProcessor. | |
| void | clearGeometricObjects () throw () |
| Clear and destroy all stored GeometricObject. | |
| const PreciseTime & | getModelBuildTime () const throw () |
| Get the time when the model was builded This is needed for updating the Representation, after the vector of atom attributes was modified. | |
| bool | needsUpdate () const throw () |
| Returns true, if Representation needs to be updated. | |
| void | setNeedsUpdate (bool state=true) throw () |
| void | dump (std::ostream &s=std::cout, Size depth=0) const throw () |
| Dum to ostream for debugging. | |
| String | toString () const throw () |
| Get a String containing all settings for Usage in project files. | |
| void | setModelInformation (const ModelInformation &mi) |
| Set a custom ModelInformation e.g. when new models were added external of the library. | |
| const ModelInformation & | getModelInformation () const |
| bool | operator== (const Representation &object) const throw () |
| bool | operator< (const Representation &object) const throw () |
| Needed for MSVC. | |
Protected Member Functions | |
| void | update_ () throw () |
| Wrapper method for multithreading. | |
| void | collectRecursive_ (const Composite &c, HashMap< const Composite *, Position > &hashmap) const throw () |
Protected Attributes | |
| DrawingMode | drawing_mode_ |
| DrawingPrecision | drawing_precision_ |
| float | surface_drawing_precision_ |
| ModelType | model_type_ |
| ColoringMethod | coloring_method_ |
| Size | transparency_ |
| ModelProcessor * | model_processor_ |
| ColorProcessor * | color_processor_ |
| List< const Composite * > | composites_ |
| PreciseTime | model_build_time_ |
| bool | needs_update_ |
| bool | rebuild_ |
| bool | changed_color_processor_ |
| bool | hidden_ |
| GeometricObjectList | geometric_objects_ |
| bool | model_update_enabled_ |
| bool | coloring_update_enabled_ |
| String | name_ |
| const ModelInformation * | custom_model_information_ |
Static Protected Attributes | |
| MolecularInformation | information_ |
| ModelInformation | model_information_ |
Friends | |
| class | UpdateRepresentationThread |
| class | RepresentationManager |
An instance of Representation manages the memory for the geometric objects, the ColorProcessor and the ModelProcessor. So when a Representation is destroyed, so are its geometric objects and processors. It stores the drawing precision and mode.
|
|
Get the time when the model was builded This is needed for updating the Representation, after the vector of atom attributes was modified.
|
|
|
Returns true, if Representation needs to be updated. Called by GeometricControl. Uses needs_update_. |
|
|
Apply ModelProcessor (if rebuild) and ColorProcessor. The usage of these processors can be disabled, either by setting a NULL-pointer accordingly or call enableColoringUpdate(false) and enableModelUpdate(false). |
|
|
Wrapper method for multithreading. Can be called by update() directly, or by the RepresentationManager' s UpdateRepresentationThread. |