RotateTranslateOperation Class Reference

A operation to rotate and translate a object. More...

#include <MemoryX/gui-plugins/SceneEditor/controller/RotateTranslateOperation.h>

+ Inheritance diagram for RotateTranslateOperation:

Public Member Functions

const OperationPtr createInverseOperation () const override
 Returns a new operation, which reverts the rotation and translatioon of the object. More...
 
bool isExecuteable () override
 Returns true, if the SceneObject is mutable. More...
 
 RotateTranslateOperation (const std::shared_ptr< memoryxcontroller::MemoryXController > &memoryXController, const std::shared_ptr< scene3D::Scene > &scene, const std::string &objectId, const SbRotation &oldRotation, const SbRotation &newRotation, const SbVec3f &oldPosition, const SbVec3f &newPosition)
 Creates a new operation, which rotates and translates a object. More...
 
- Public Member Functions inherited from Operation
std::string getObjectId () const
 Returns the ID of the object, this Operation is working on. More...
 
 Operation (const std::shared_ptr< memoryxcontroller::MemoryXController > &memoryXController, const std::shared_ptr< scene3D::Scene > &scene)
 A constructor. More...
 
 Operation (const std::shared_ptr< memoryxcontroller::MemoryXController > &memoryXController, const std::shared_ptr< scene3D::Scene > &scene, const std::string &objectId)
 A constructor. More...
 

Protected Member Functions

void executeOnScene () override
 Rotates and translates the object in the Scene. More...
 
void executeOnWorkingMemory () override
 Rotates and translates the object in the WorkingMemory. More...
 
- Protected Member Functions inherited from Operation
const std::shared_ptr< memoryxcontroller::MemoryXControllergetMemoryXController () const
 Returns the the MemoryXController to execute the Operation at. More...
 
const std::shared_ptr< scene3D::ScenegetScene () const
 Returns the the Scene to execute the Operation at. More...
 
void setObjectId (const std::string &objectId)
 Sets the ID, this operation is working on. More...
 

Detailed Description

A operation to rotate and translate a object.

See also
controller::Operation

Definition at line 46 of file RotateTranslateOperation.h.

Constructor & Destructor Documentation

◆ RotateTranslateOperation()

RotateTranslateOperation ( const std::shared_ptr< memoryxcontroller::MemoryXController > &  memoryXController,
const std::shared_ptr< scene3D::Scene > &  scene,
const std::string &  objectId,
const SbRotation &  oldRotation,
const SbRotation &  newRotation,
const SbVec3f &  oldPosition,
const SbVec3f &  newPosition 
)

Creates a new operation, which rotates and translates a object.

Parameters
memoryXControllerThe MemoryXController to rotate and translate the object on.
sceneThe scene to rotate and translate the object on.
objectIdThe object to rotate and translate.
oldRotationThe old rotation of the object.
newRotationThe new rotation of the object.
oldPositionThe old position of the object.
newPositionThe new position of the object.
See also
controller::Operation::Operation

Definition at line 35 of file RotateTranslateOperation.cpp.

Member Function Documentation

◆ createInverseOperation()

const controller::OperationPtr createInverseOperation ( ) const
overridevirtual

Returns a new operation, which reverts the rotation and translatioon of the object.

Returns
The operation, which reverts the rotation and translatioon of the object.
See also
controller::Operation::createInverseOperation

Implements Operation.

Definition at line 44 of file RotateTranslateOperation.cpp.

◆ executeOnScene()

void executeOnScene ( )
overrideprotectedvirtual

Rotates and translates the object in the Scene.

See also
controller::Operation::executeOnScene

Implements Operation.

Definition at line 55 of file RotateTranslateOperation.cpp.

◆ executeOnWorkingMemory()

void executeOnWorkingMemory ( )
overrideprotectedvirtual

Rotates and translates the object in the WorkingMemory.

See also
controller::Operation::executeOnWorkingMemory

Implements Operation.

Definition at line 50 of file RotateTranslateOperation.cpp.

◆ isExecuteable()

bool isExecuteable ( )
overridevirtual

Returns true, if the SceneObject is mutable.

Returns
true, if the SceneObject is mutable; false otherwise.

Reimplemented from Operation.

Definition at line 77 of file RotateTranslateOperation.cpp.


The documentation for this class was generated from the following files: