8 #include "IMovableItemCallback.h"
9 #include "ISimGUICallback.h"
15 #include "IPhysicsMovableItem.h"
16 #include "IPhysicsBody.h"
18 #include "MovableItem.h"
76 {
Std_TraceMsg(0,
"Caught Error in desctructor of SimulationWindowMgr\r\n",
"", -1,
false,
true);}
128 if(lpWin)
delete lpWin;
134 if(lpWin)
delete lpWin;
135 THROW_ERROR(Std_Err_lUnspecifiedError, Std_Err_strUnspecifiedError);
149 for(
int iIndex=0; iIndex<iCount; iIndex++)
168 for(
int iIdx=0; iIdx<iCount; iIdx++)
179 THROW_ERROR(Al_Err_lSimWindowNotFound, Al_Err_strSimWindowNotFound);
221 for(
int iIndex=0; iIndex<iCount; iIndex++)
255 for(
int iIndex=0; iIndex<iCount; iIndex++)
269 for(
int iIndex=0; iIndex<iCount; iIndex++)
284 for(
int iIndex=0; iIndex<iCount; iIndex++)
297 for(
int iIndex=0; iIndex<iCount; iIndex++)
301 void SimulationWindowMgr::Load(
CStdXml &oXml)
320 THROW_TEXT_ERROR(Al_Err_lSimWinPosInvalid, Al_Err_strSimWinPosInvalid,
"POS: (" + STR(
m_ptPosition.x) +
", " + STR(
m_ptPosition.y) +
")");
327 THROW_TEXT_ERROR(Al_Err_lSimWinSizeInvalid, Al_Err_strSimWinSizeInvalid,
"Size: (" + STR(
m_ptSize.x) +
", " + STR(
m_ptSize.y) +
")");
335 for(
int iIndex=0; iIndex<iCount; iIndex++)
348 std::string strModuleName = oXml.
GetChildString(
"ModuleName",
"");
376 std::string strModuleName, strType;
387 THROW_TEXT_ERROR(Al_Err_lConvertingClassToType, Al_Err_strConvertingClassToType,
"SimulationWindow");
396 if(lpWin)
delete lpWin;
402 if(lpWin)
delete lpWin;
403 THROW_ERROR(Std_Err_lUnspecifiedError, Std_Err_strUnspecifiedError);
virtual void ResetSimulation()
Resets the simulation back to time 0.
Base class file for all Animat simulation objects.
virtual void ResetSimulation()
Resets the simulation back to time 0.
Declares the nervous system class.
Declares the simulation recorder class.
virtual void SetSystemPointers(Simulator *lpSim, Structure *lpStructure, NeuralModule *lpModule, Node *lpNode, bool bVerify)
Sets the system pointers.
CStdFPoint m_ptPosition
If this is a stand-alone group window then this is the position of the group window.
virtual bool FindChildElement(std::string strElementName, bool fThrowError=true)
Finds a child element by name.
Root namespace for the base simulation library for AnimatLab.
Declares the body part class.
Simulator * m_lpSim
The pointer to a Simulation.
virtual void UpdateBackgroundColor()
Updates the background color for all simulation windows.
Information about the standard error.
virtual bool IntoElem()
Goes into the next element where the cursor is located.
Base class for a simulation window.
SimulationWindow * LoadSimulationWindow(CStdXml &oXml)
Loads a simulation window.
virtual void Initialize()
Initializes this object.
virtual bool HasContainedWindow()
Query if this object has contained window.
Declares the simulation window manager class.
Declares the link base class.
Declares the key frame class.
Declares the joint class.
Declares the organism class.
CStdPtrArray< SimulationWindow > m_aryWindows
Array of SimulationWindow objects.
Hud * m_lpHudMgr
Manager for heads-up display items.
CStdFPoint m_ptSize
If this is a stand-alone group window then this is the size of the group window.
Declares the activated item class.
Declares the data column class.
virtual CStdSerialize * CreateObject(std::string strModule, std::string strClassName, std::string strType, bool bThrowError=true)
Creates an object using a class factory.
Declares a light manager object.
Declares the simulation Windows Form.
Declares the bounding box class.
virtual void RemoveSimulationWindow(HWND win)
Removes the simulation window described by the HWND win.
Declares the gain base class.
virtual void Reset()
Resets this object.
virtual void Close()
Closes all windows.
virtual void Initialize()=0
Initializes this object.
A standard xml manipulation class.
virtual std::string GetChildString(std::string strElementName)
Gets a string value from the element with the specified name.
virtual void Initialize()
Initializes this object.
virtual void CloseAllWindows()
Closes all windows internally.
~SimulationWindowMgr(void)
Destructor.
virtual void Load(StdUtils::CStdXml &oXml)
Loads the item using an XML data packet.
void Std_TraceMsg(const int iLevel, std::string strMessage, std::string strSourceFile, int iSourceLine, bool bLogToFile, bool bPrintHeader)
Traces a message to the debugger window.
virtual int NumberOfChildren()
Gets the number of children of the current element.
virtual bool OutOfElem()
Goes out of the element where the cursor is located.
Declares the data chart class.
virtual void OnGetFocus()
Called by the GUI when this window gets the focus.
SimulationWindowMgr(void)
Default constructor.
virtual SimulationWindow * FindSimulationWindow(HWND win, int &iIndex, bool bThrowError=true)
Searches for simulation window with the specified HWND.
Declares the data chart manager class.
Declares the rigid body class.
virtual bool Update()
Updates all of the windows.
virtual bool IntoChildElement(std::string strElementName, bool bThrowError=true)
Goes into the child element with the specified name.
bool Std_LoadPoint(CStdXml &oXml, std::string strName, CStdIPoint &oPoint, bool bThrowError)
Standard load point.
Declares the structure class.
Declares the odor type class.
virtual void SetupCameras()
Sets up the cameras for each window.
virtual SimulationWindow * AddSimulationWindow(std::string strModule, std::string strType, bool bInit, HWND win, std::string strHudXml)
Adds a simulation window.
virtual void VerifySystemPointers()
Verify that system pointers have been set correctly.
virtual void Close()=0
Closes this window.
Declares the simulator class.
Declares the neural module class.
virtual bool FindChildByIndex(int iIndex, bool bThrowError=true)
Finds a child element by index.
Declares the activated item manager class.
virtual HWND WindowID()
Gets the HWND window identifier.
Declares the external stimuli manager class.
Declares the receptive field class.