#include <GReparentAgent.h>
Inheritance diagram for GBE::GReparentAgent:


Public Slots | |
| virtual void | receiveInfluence (GCS::GElementInfluence &influence) |
Public Member Functions | |
| GReparentAgent (QObject *parent=0, const char *name=0) | |
| virtual | ~GReparentAgent () |
Protected Member Functions | |
| void | performReparenting (const GCS::GElementID &new_parent, const GCS::GVector3 &pos_add, const GCS::GVector3 &rotate) |
If a reparent influence is received, the agent updates the parent/child information of the element and emits a reparent signal (NOT influence!) to let the GWE know about it.
This agent also handles reparenting of itself into another child of the same parent. This happens when this element is completely enclosed in another element of the same parent. On such cases a reparenting influence is sent to the current parent and the new child so they can update their child/parent data.
In all cases the reparented element has to perform form transformation because position and rotation is always relative to the current parent. The required transformation information is included in the reparenting influence which is sent by the element/agent that detects reparenting.
Position and size information is stored in the form attribute of an element. GRadiatingAgent is taking care of influence radiation which is required for this agent to work as these influences include the position and size information.
|
||||||||||||
|
Constructor. |
|
|
Virtual Destructor. |
|
||||||||||||||||
|
Do the actual reparenting. This is done by the reparented element. |
|
|
Analyses given influence and checks for reparenting if it's a GPositionalInfluence or performs reparenting work if it is a GReparentInfluence. Reimplemented from GCS::GAgent. |
1.3.6