![]() |
VR-Forces 4.8 Class Documentation
|
This driver is responsible for creating DtWindowObjects The VR - Vantage Control Toolkit lets you create 2D window objects, such as lines, polygons and textboxes.This example shows how to add new window objects and manipulate them around the screen. More...

Public Types | |
| enum | DtDirection { Up = 0, Left = 1, Down = 2, Right = 4 } |
| Enum for moving window objects. More... | |
| typedef std::vector < DtWindowObjectAgent * > | DtWindowObjects |
| typedef vector for holding DtWindowObjectAgents More... | |
Public Member Functions | |
| DtWindowObjectsDriver (DtAgentManager &agentManager, const std::string &instanceName) | |
| CTOR. More... | |
| virtual | ~DtWindowObjectsDriver () |
| Virtual DTOR. More... | |
| virtual const std::string & | className () const |
| Get the class name as a string. More... | |
| virtual void | drawObject () |
| Draw a window object. More... | |
| virtual void | drawPolygon () |
| Draw a polygon. More... | |
| virtual void | drawLine () |
| Draw a line. More... | |
| virtual void | drawText () |
| Draw test. More... | |
| virtual void | drawEllipse () |
| Draw a ellipse. More... | |
| virtual void | activateObjectType (int objectType) |
| Select which type of window object to draw. More... | |
| virtual void | modifyActivateObjectId (bool increaseIdNumber) |
| Select which window object to current modify. More... | |
| virtual void | setParenting () |
| Set parenting on/off Alternates on method call. More... | |
| virtual void | modifyObjectVisibility () |
| Change the visibility of currently selected window object This will change the visibility of all its children. More... | |
| virtual void | shiftWindowObjectPosition (DtDirection direction) |
| Get the agent from the map at the param in key, get the position of the DtWindowObject() from the agent, then shift the position in the passed in direction by 0.1 This method will get the top parent window polygon from DtWindowObjectMap and move it around the screen, any attached children will move too. More... | |
| virtual void | scaleWindowObject (DtDirection direction) |
| Scale vertex methods This method will get the top parent window polygon from DtWindowObjectMap and scale it , any attached children will be scaled too. More... | |
| virtual void | rotateWindowObject () |
| Rotate the currently selected window object Rotates clockwise in rads. More... | |
| virtual DtWindowObjectAgent * | findWindowObjectAgent (int vecLocation) |
Public Member Functions inherited from makVrv::DtDriver | |
| DtDriver (DtAgentManager &agentManager, const std::string &instanceName) | |
| CTOR. More... | |
| virtual | ~DtDriver () |
| DTOR. More... | |
| virtual void | realizeConfiguration (const DtConfiguration &configuration) |
| Realize the driver using the configuration. More... | |
| virtual DtConfiguration | createConfiguration () const |
| Create a configuration for the driver. More... | |
| DtAgentManager & | agentManager () |
| Get the master scene for this host. More... | |
| virtual DtAgentManagerInterface & | sceneInterface () |
| Get the scene manager interface for creating agents. More... | |
| bool | started () const |
| Get this driver's active state. More... | |
| virtual const std::string & | instanceName () const |
| Get this driver's instance name. More... | |
| virtual bool | autoStart () const |
| Get whether this driver is set to automatically start if it is persistent. More... | |
| virtual void | setAutoStart (bool autoStart) |
| Set whether this driver automatically starts if it is persistent. More... | |
| virtual bool | isWindowDependent () const |
| Get whether this driver is set to automatically start when the first window is created and stop when the last window is destroyed. More... | |
| virtual void | setIsWindowDependent (bool dep) |
| Set whether this driver is set to automatically start when the first window is created and stop when the last window is destroyed. More... | |
| virtual void | setIsUserControllable (bool) |
| Set whether this driver can be started and stopped by the user. More... | |
| virtual bool | isUserControllable () const |
| Get whether this driver can be started and stopped by the user. More... | |
| virtual void | setIsPersistent (bool per) |
| Set if the driver is persistent and should be saved between runs. More... | |
| virtual bool | isPersistent () const |
| Get if the driver is persistent and should be saved between runs. More... | |
| virtual bool | isOnDriverSelectionList () const |
| Returns whether or not this driver is to be automatically started/stopped from the driver selection list. More... | |
| virtual void | setOnDriverSelectionList (bool) |
| Sets whether or not this item is on the driver selection list. More... | |
| bool | objectFromAgentManager (const DtUniqueID &id) const |
| check to see if the object was created using this driver's agent manager. More... | |
Protected Member Functions | |
| virtual bool | onStart () |
| Called when the driver is started by the display engine Restores state that existed the last time the driver was stopped. More... | |
| virtual bool | onStop () |
| Called when the driver is stopped by the display engine. More... | |
| virtual bool | onTick () |
| Stub implementation since this driver doesn't have anything that needs updating. More... | |
Protected Member Functions inherited from makVrv::DtDriver | |
| void | applyChangesAndDelete (DtElementChanges *changes) |
| Function for apply changes from a changes object and deleting it. More... | |
| void | reportElementCreated (DtElementID id, DtElementID parentId, DtElementEntry::ElementType type) |
| Report an element created. More... | |
| void | reportElementAttribute (DtElementID id, DtElementAttribute *attribute) |
| Report an element attribute changed. More... | |
| void | reportElementDestroyed (DtElementID id) |
| Report an element destroyed. More... | |
| void | start () |
| Start the driver. More... | |
| void | stop () |
| Stop the driver. More... | |
| bool | tick () |
| Tick the host driver. More... | |
| virtual void | slot_displayEngineAdded (const DtDeRecord &igRecord) |
| Called when a display engine is added. More... | |
| virtual void | setInstanceName (const std::string &name) |
| set the Instance name. More... | |
| virtual void | installAccessories () |
| Installs accessories on this driver. More... | |
| virtual void | uninstallAccessories () |
| Removes accessories from this driver. More... | |
Protected Attributes | |
| DtWindowObjects | myWindowAgents |
| Vector of the window agents. More... | |
| int | myActivatedObjectType |
| Location in the vector of the currently selected window object for control Checks vector bounds. More... | |
| int | myActivatedObjectId |
| The Object that is currently being moved This is a key for the myWindowAgentsMap. More... | |
| bool | myParenting |
| Whether the next created object will be a child of the previously created object. More... | |
| DtWindowSurfaceAgent * | mySurface |
| Surface for clipping window objects. More... | |
| DtWindowPolygonAgent * | mySurfaceClipBoxVisualPoly |
| Polygon for displaying clipping surface. More... | |
Protected Attributes inherited from makVrv::DtDriver | |
| DtAgentManager & | myAgentManager |
| bool | myStartedFlag |
| std::string | myName |
| DtConfiguration | myConfiguration |
| bool | myPersistentFlag |
| bool | myUserControllableFlag |
| bool | myRequestStateDiffPendingFlag |
| DtElementChanges | myChanges |
This driver is responsible for creating DtWindowObjects The VR - Vantage Control Toolkit lets you create 2D window objects, such as lines, polygons and textboxes.This example shows how to add new window objects and manipulate them around the screen.
This example allows you to create, translate( x&y ), rotate, scale( x&y ) # multiple different objects, using both a parenting and non parenting mode. The box that is initially displayed in white on screen is a visual representation of the DtWindowSurface's clipping box. The key bindings for the example are as follows : “Space” - creates a window object object of the selected type “1” - Sets window object type to Polygon “2” - Sets window object type to Line “3” - Sets window object type to Text Box “4” - Sets window object type to Eclipse “WASD” - Translate the object and it’s children around the screen “Left” & “Right” arrow keys - scale - / +in the x direction “Up” & “Down” arrow keys - scale - / +in the y direction "R" - Rotate object 90 degrees clockwise “, ” & “.” - The comma and period keys traverse up and down the vector the objects are stored in for individual control. “p” - Turns parenting off for newly created objects, for individual control. Parenting is on by default, and each newly created object is attached to the previously created object. “v” - Turns the currently selected window object's visibility on / off.
| typedef std::vector<DtWindowObjectAgent*> makVrv::DtWindowObjectsDriver::DtWindowObjects |
typedef vector for holding DtWindowObjectAgents
| makVrv::DtWindowObjectsDriver::DtWindowObjectsDriver | ( | DtAgentManager & | agentManager, |
| const std::string & | instanceName | ||
| ) |
CTOR.
|
virtual |
Virtual DTOR.
|
virtual |
Get the class name as a string.
Implements makVrv::DtDriver.
|
virtual |
Draw a window object.
Draws the type of object activated via keyboard inputs default is polygon
|
virtual |
Draw a polygon.
|
virtual |
Draw a line.
|
virtual |
Draw test.
|
virtual |
Draw a ellipse.
|
virtual |
Select which type of window object to draw.
|
virtual |
Select which window object to current modify.
|
virtual |
Set parenting on/off Alternates on method call.
|
virtual |
Change the visibility of currently selected window object This will change the visibility of all its children.
|
virtual |
Get the agent from the map at the param in key, get the position of the DtWindowObject() from the agent, then shift the position in the passed in direction by 0.1 This method will get the top parent window polygon from DtWindowObjectMap and move it around the screen, any attached children will move too.
|
virtual |
Scale vertex methods This method will get the top parent window polygon from DtWindowObjectMap and scale it , any attached children will be scaled too.
|
virtual |
Rotate the currently selected window object Rotates clockwise in rads.
|
virtual |
|
protectedvirtual |
Called when the driver is started by the display engine Restores state that existed the last time the driver was stopped.
Implements makVrv::DtDriver.
|
protectedvirtual |
Called when the driver is stopped by the display engine.
Implements makVrv::DtDriver.
|
protectedvirtual |
Stub implementation since this driver doesn't have anything that needs updating.
Implements makVrv::DtDriver.
|
protected |
Vector of the window agents.
|
protected |
Location in the vector of the currently selected window object for control Checks vector bounds.
|
protected |
The Object that is currently being moved This is a key for the myWindowAgentsMap.
|
protected |
Whether the next created object will be a child of the previously created object.
|
protected |
Surface for clipping window objects.
|
protected |
Polygon for displaying clipping surface.