34#include <NDEVR/DesignObject.h>
35#include <NDEVR/Model.h>
36#include <NDEVR/Effect.h>
37#include <NDEVR/DesignSelection.h>
38#include <NDEVR/CameraManager.h>
39#include <NDEVR/LogManager.h>
40#include <NDEVR/DesignParameterAccumulator.h>
50 class SelectionController;
51 class ModelEditController;
53 class SelectionEffect;
54 class DesignCommandManager;
55 class ResourceListener;
56 class DesignTaskManager;
58 class DesignObjectUpdateTarget;
89 virtual void addScene(
Scene scene,
bool ignore_application_scene =
false);
128 bool hasCamera(
const UUID&
id)
const;
133 virtual CameraManager* cameraManager();
134 virtual const CameraManager* cameraManager()
const;
135 virtual SelectionController* selectionController();
136 virtual ModelEditController* editManager();
202#if NDEVR_SUPPORTS_THREADING
207 virtual void update(
const Time& time,
const std::function<
void()>& wait_callback);
223#if NDEVR_SUPPORTS_THREADING
225 std::function<void(
const Exception&)> m_exception_callback =
nullptr;
236 CameraManager* m_camera_controller;
A bitset that stores 8 bits (elements with only two possible values: 0 or 1, true or false,...
Definition BitFlag.hpp:55
A specification of upper and lower bounds in N-dimensions.
Definition Bounds.hpp:52
The equivelent of std::vector but with a bit more control. The basic array unit of the library.
Definition Buffer.hpp:56
Provides a constant, unmodifiable pointer that has shared ownership of a dynamically allocated object...
Definition GraphicsPipeline.h:42
Stores logic for performing, undoing, or redoing DesignCommands.
Definition DesignCommandManager.h:14
A low-level database object that can be used to access general stored properties within the NDEVR Mod...
Definition DesignObject.h:67
A core class where all Design Objects including models, materials, and geometries are stored....
Definition DesignObjectLookup.h:65
Bounds< 3, fltp08 > boundsOfVisible() const
UUID m_active_layer
Definition DesignObjectLookup.h:229
Model createCameraModel(UUID camera)
virtual ~DesignObjectLookup()
void selectEnclosed(UUID selection_id)
Dictionary< UUID, Geometry > m_geometry_objects
Definition DesignObjectLookup.h:252
virtual void updateModelTopLevel(const Model &object)
bool hasLayerID(const UUID &id, bool allow_deleted=false) const
bool hasObjectID(const UUID &id, bool allow_deleted=false) const
ResourceListener * m_language_change_listener
Definition DesignObjectLookup.h:256
virtual void appendSelected(Buffer< UUID > ids)
RDesignLock readLock(UUID id)
virtual void refreshScene(UUID scene_id, bool ignore_application_scene)
bool m_update_language
Definition DesignObjectLookup.h:262
void processSelection(SelectionInfo &info) const
virtual void deleteObject(UUID id)
WDesignLock writeLock(UUID id)
const Dictionary< UUID, DesignObject > & objects()
Definition DesignObjectLookup.h:189
Dictionary< UUID, DynamicPointer< DesignSelection > > m_selection_info
Definition DesignObjectLookup.h:254
bool m_update_station_visuals
Definition DesignObjectLookup.h:260
Scene scene(const UUID &id, bool allow_deleted=false) const
Dictionary< UUID, Scene > m_all_scene_objects
Definition DesignObjectLookup.h:242
virtual void setSelected(Buffer< UUID > ids)
const DynamicPointer< DesignSelection > & getSelectionInfo(const UUID &id)
void ensureLayerExistsInScene(const UUID &layer_id, const UUID &scene_id)
Buffer< Model > getModelsByType(const Buffer< String > &types) const
Dictionary< UUID, Model > m_application_root_objects
Definition DesignObjectLookup.h:249
void updateEffects(const Time &time, const std::function< void()> &wait_callback)
void addUpdateTarget(DesignObjectUpdateTarget *target)
RLock tryReadLock(uint08 milliseconds=10) const
Resource< Time > autosave_checkpoint_request_time
Definition DesignObjectLookup.h:221
Dictionary< UUID, Model > m_model_root_objects
Definition DesignObjectLookup.h:248
Model findLayer(const TranslatedString &layer) const
virtual Model restoreModel(UUID id)
Model layer(const UUID &layer_id, const UUID &scene_id, bool allow_deleted=false) const
const Dictionary< UUID, DesignObject > & deletedObjects()
Definition DesignObjectLookup.h:191
Material createMaterial()
const Dictionary< UUID, Effect > & effectObjects()
Definition DesignObjectLookup.h:190
Model findLayer(const String &layer, bool use_translation=true) const
Scene m_default_scene
Definition DesignObjectLookup.h:231
virtual void setActiveProject(UUID layer_id)
const Dictionary< UUID, Geometry > & geometryObjects()
Definition DesignObjectLookup.h:188
const Scene & defaultScene()
Definition DesignObjectLookup.h:181
bool hasModelID(const UUID &id, bool allow_deleted=false) const
void cleanupMemory(Buffer< UUID > deleted_objects)
bool hasGeometryID(const UUID &id) const
virtual void addGeometry(Geometry object)
Model modelOrLayer(const UUID &id, bool allow_deleted=false) const
virtual UUID activeProject() const
Definition DesignObjectLookup.h:110
virtual void eraseModel(UUID id)
const Dictionary< UUID, Model > & getAllSceneLayers(const UUID &id) const
void setSelectionEffect(SelectionEffect *effect)
void removeUpdateTarget(DesignObjectUpdateTarget *target)
virtual DesignTaskManager * taskManager() const
Resource< Time > modified_time
Definition DesignObjectLookup.h:219
Effect effect(const UUID &id, bool allow_deleted=false) const
virtual void addCameraModel(const UUID &camera, const Model &object)
Material createCameraMaterial(UUID camera)
const Dictionary< UUID, Model > & modelObjects()
Definition DesignObjectLookup.h:185
Resource< UUID > current_layer
Definition DesignObjectLookup.h:218
Resource< RGBColor > focus_color
Definition DesignObjectLookup.h:217
const void * lockPtr() const
Buffer< Model > getLayersByType(const String &type) const
virtual void addSelection(const DesignSelection &object)
Buffer< Model > getRootObjects(bool include_app_owned=false) const
Geometry geometry(const UUID &id, bool allow_deleted=false) const
bool m_update_station_font
Definition DesignObjectLookup.h:261
bool hasMaterialID(const UUID &id) const
Buffer< DesignParameter, uint04, ObjectAllocator< false > > designParameters() const
virtual void update(const Time &time, const std::function< void()> &wait_callback)
virtual void clearSelected()
Buffer< UUID > getModelIDsByType(const String &type) const
TimeSpan m_prefered_update_timespan
Definition DesignObjectLookup.h:259
Buffer< Model > getLayersByType(const Buffer< String > &types) const
RLock readLock(const std::function< void()> &wait_callback) const
virtual void runCommand(const DynamicPointer< DesignCommand > &command)
DesignTaskManager * m_task_controller
Definition DesignObjectLookup.h:240
Dictionary< UUID, Material > m_material_objects
Definition DesignObjectLookup.h:251
Buffer< Model > getRootObjects(UUID camera_id, bool include_app_owned=false) const
virtual void refreshModel(const Model &object)
Buffer< UUID > visibleModels() const
Model model(const UUID &id, bool allow_deleted=false) const
DesignParameterAccumulator accumulateDesignParameter(const DesignParameter &channel, const BitFlag &accumulation_flags) const
void invalidateStationVisuals(bool invalidate_visuals, bool invalidate_font)
const Dictionary< UUID, Scene > & sceneObjects()
Definition DesignObjectLookup.h:184
ResourceListener * m_invalidate_station_visuals_listener
Definition DesignObjectLookup.h:255
Dictionary< UUID, Dictionary< UUID, Model > > m_layer_objects
Definition DesignObjectLookup.h:250
Buffer< UUID > getRootObjectIDs(UUID camera_id, bool include_app_owned=false) const
void startUpdateThread(const TimeSpan &span, std::function< void(const Exception &)> exception_callback)
SelectionEffect * m_selection_effect
Definition DesignObjectLookup.h:238
virtual void addModel(Model object)
bool isCommandLocked() const
Dictionary< UUID, DesignObject > m_deleted_objects
Definition DesignObjectLookup.h:246
virtual void addMaterial(Material object)
WLock writeLock(const std::function< void()> &wait_callback)
UUID m_active_project
Definition DesignObjectLookup.h:230
Buffer< Model > getModelsByName(const String &name) const
Model layer(const UUID &id, bool allow_deleted=false) const
virtual void requestAutoSaveCheckpoint()
virtual DesignCommandManager * commandManager()
Buffer< DesignObjectUpdateTarget * > m_update_targets
Definition DesignObjectLookup.h:257
Bounds< 3, fltp08 > bounds() const
WLock tryWriteLock(uint08 milliseconds=10)
bool hasSceneID(const UUID &id, bool allow_deleted=false) const
Buffer< Model > getModelsByID(const Buffer< UUID > &ids) const
Dictionary< UUID, Model > m_model_objects
Definition DesignObjectLookup.h:244
bool hasLayerID(const UUID &id, const UUID &scene_id) const
ModelEditController * m_edit_controller
Definition DesignObjectLookup.h:233
virtual void addEffect(Effect object)
const ConstPointer< DesignSelection > & getSelectionInfo(const UUID &id) const
virtual Buffer< UUID > getInverseOf(const Buffer< UUID > &model_ids)
Material material(const UUID &id, bool allow_deleted=false) const
bool hasSelectionInfo(const UUID &id) const
Dictionary< UUID, Model > m_camera_root
Definition DesignObjectLookup.h:241
virtual void executePendingCommands()
Dictionary< UUID, Effect > m_effect_objects
Definition DesignObjectLookup.h:253
Buffer< Model > getModelsByType(const String &type) const
Time m_last_update_time
Definition DesignObjectLookup.h:258
virtual void postCommand(const DynamicPointer< DesignCommand > &command)
Resource< Time > autosave_request_time
Definition DesignObjectLookup.h:220
RLock tryReadLock(const TimeSpan &span) const
const Dictionary< UUID, Dictionary< UUID, Model > > & layerObjects()
Definition DesignObjectLookup.h:186
bool hasEffect(const UUID &id) const
Dictionary< UUID, UUID > m_erased_objects
Definition DesignObjectLookup.h:247
Buffer< DesignParameterAccumulator, uint04, ObjectAllocator< false > > accumulateDesignParameters(const BitFlag &accumulation_flags) const
virtual Project activeProjectModel() const
virtual void addLayer(Model layer)
virtual LogManager * logManager() const
void removeDeletedObject(UUID id)
Definition DesignObjectLookup.h:192
virtual void requestAutoSave()
LogManager * m_log_manager
Definition DesignObjectLookup.h:239
virtual void setActiveLayer(UUID layer_id)
const Dictionary< UUID, Material > & materialObjects()
Definition DesignObjectLookup.h:187
virtual void finishCommand(const DynamicPointer< DesignCommand > &command)
Buffer< UUID > getRootObjectIDs(bool include_app_owned=false) const
Dictionary< UUID, DesignObject > m_design_objects
Definition DesignObjectLookup.h:245
UUID m_uuid
Definition DesignObjectLookup.h:263
DesignObject object(const UUID &id) const
virtual Buffer< UUID > getDescendentsOf(const Buffer< UUID > &model_ids)
Dictionary< UUID, Scene > m_scene_objects
Definition DesignObjectLookup.h:243
virtual void addScene(Scene scene, bool ignore_application_scene=false)
DesignCommandManager * m_command_controller
Definition DesignObjectLookup.h:234
SelectionController * m_selection_controller
Definition DesignObjectLookup.h:232
WLock tryWriteLock(const TimeSpan &span)
void colorByChannel(UUID target, const DesignParameter &channel)
An object that will be call update, each time the lookup is updated.
Definition DesignObjectUpdateTarget.h:10
Searches a model heirarchy and pulls all parameter data based on the AccumationMode settings.
Definition DesignParameterAccumulator.h:67
A definition of data that is logically stored in the Model heirarchy. Data could be a property of a M...
Definition DesignParameter.h:46
A simple structure for storing a collection of data.
Definition DesignSelection.h:26
Manages all active and inactive tasks for a DesignObjectLookup.
Definition DesignTask.h:28
A hash-based key-value store, useful for quick associative lookups. Key features include:
Definition Dictionary.h:61
Provides a modifiable pointer that has shared ownership of a dynamically allocated object.
Definition Pointer.hpp:320
A core class that provides a dynamic effect to an object in a model heirarchy.
Definition Effect.h:45
Provides consistent interface to handle errors through the throw expression. All exceptions generated...
Definition Exception.hpp:47
A core class within the model heirarchy containing vertex-based data (Usually 3D data) within a set c...
Definition Geometry.h:64
A class that has any number of children that also feed into the log. Can be used to easily collect lo...
Definition LogManager.h:14
Container responsible for storing and setting the appearance of a Model or Geometry within the NDEVR ...
Definition Material.h:51
A core class that represents a node on model heirarchy. This node may contain a Geometry or one or mo...
Definition Model.h:58
A Model which represents a user-project. A project is a series of Scenes grouped together within a so...
Definition Project.h:41
Used to lock a particular model for editing (DEPRECIATED)
Definition DesignLock.h:43
Used to lock a particular variable for reading. Any number of readers can be created when no write lo...
Definition RWLock.h:91
A core part of the engine, stores variables that can be listened to with ResourceListener which will ...
Definition Toggle.h:41
A class that can subscribe to any number of Resources which will get updates when the Resource(s) hav...
Definition ResourceListener.h:62
The root Model that is responsible for storing the underlying data for all Scene Models.
Definition Model.h:492
Applies certain effects to a model that has been selected.
Definition SelectionEffect.h:12
Responsible for turning a user interaction into a selection within a DesignObjectLookup.
Definition Selector.h:50
The core String class for the NDEVR API.
Definition String.h:69
A thread is a single sequence stream within the software.
Definition Thread.h:67
Represents a timestamp with utilities for manipulation and conversion.
Definition Time.h:54
Stores a time span, or difference between two times, with an optional start time.
Definition TimeSpan.h:46
Any text displayed to the user should be defined as a TranslatedString which allows the program to lo...
Definition TranslatedString.h:13
A universally unique identifier (UUID) is a 128-bit number used to identify information in computer s...
Definition UUID.h:60
Used to lock a particular model for editing (DEPRECIATED)
Definition DesignLock.h:55
Used to lock a particular variable for writing. Only one write lock can be created when no read locks...
Definition RWLock.h:115
uint64_t uint08
-Defines an alias representing an 8 byte, unsigned integer
Definition BaseValues.hpp:106
Logic for automatically zooming a Camera or Viewport to a certain location or having certain objects ...
Definition ViewportAutoZoomFocus.h:14