8 #include "IMovableItemCallback.h"
9 #include "ISimGUICallback.h"
13 #include "IPhysicsMovableItem.h"
14 #include "IPhysicsBody.h"
16 #include "MovableItem.h"
54 m_ptSize.Set(200, 200, 0);
144 THROW_PARAM_ERROR(Al_Err_lInavlidPlaneSize, Al_Err_strInavlidPlaneSize,
"X Size", ptPoint.x);
146 THROW_PARAM_ERROR(Al_Err_lInavlidPlaneSize, Al_Err_strInavlidPlaneSize,
"Y Size", ptPoint.y);
156 void Plane::Size(std::string strXml,
bool bUseScaling)
165 Size(vPos, bUseScaling);
194 m_iWidthSegments = iVal;
225 m_iLengthSegments = iVal;
230 bool Plane::SetData(
const std::string &strDataType,
const std::string &strValue,
bool bThrowError)
234 if(RigidBody::SetData(strType, strValue,
false))
237 if(strType ==
"SIZE")
243 if(strType ==
"LENGTHSEGMENTS")
249 if(strType ==
"WIDTHSEGMENTS")
257 THROW_PARAM_ERROR(Al_Err_lInvalidDataType, Al_Err_strInvalidDataType,
"Data Type", strDataType);
262 void Plane::QueryProperties(CStdPtrArray<TypeProperty> &aryProperties)
264 RigidBody::QueryProperties(aryProperties);
266 aryProperties.Add(
new TypeProperty(
"Size", AnimatPropertyType::Float, AnimatPropertyDirection::Set));
267 aryProperties.Add(
new TypeProperty(
"LengthSegments", AnimatPropertyType::Integer, AnimatPropertyDirection::Set));
268 aryProperties.Add(
new TypeProperty(
"WidthSegments", AnimatPropertyType::Integer, AnimatPropertyDirection::Set));
271 void Plane::Load(
CStdXml &oXml)
273 RigidBody::Load(oXml);
Plane()
Default constructor.
virtual void Deserialize(std::string &strXml)
Deserializes a string into an xml document.
Base class file for all Animat simulation objects.
Declares the simulation recorder class.
virtual float GridY()
Gets the length of a segment for the y dimension of the plane.
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.
virtual bool FindElement(std::string strElementName, bool fThrowError=true)
Finds an element with the specified name.
Simulator * m_lpSim
The pointer to a Simulation.
virtual bool IntoElem()
Goes into the next element where the cursor is located.
Class that stores information about types for QueryProperty information.
Declares the key frame class.
virtual float CornerX()
Gets the corner x coordinate.
Declares the plane class.
virtual CStdFPoint Size()
Gets the size of the visible plane.
Declares the joint class.
Declares the organism class.
virtual int GetChildInt(std::string strElementName)
Gets an integer value from the element with the specified name.
bool Std_IsAboveMin(int iMinVal, int iVal, bool bThrowError, std::string strParamName, bool bInclusiveLimit)
Tests if a number is above a minimum value.
virtual float GridX()
Gets the width of a segment for the x dimension of the plane.
virtual void Resize()
Called when this object has been resized.
Declares the activated item class.
Declares a light manager object.
float m_fltDensity
Uniform density for the rigid body.
virtual int WidthSegments()
Gets the width segments.
Declares the bounding box class.
A standard xml manipulation class.
CStdFPoint m_oAbsPosition
virtual int LengthSegments()
Gets the length segments.
virtual ~Plane()
Destructor.
virtual float CornerY()
Gets the corner y coordinate.
virtual bool OutOfElem()
Goes out of the element where the cursor is located.
Declares the data chart manager class.
Declares the rigid body class.
std::string Std_CheckString(std::string strVal)
Converts a string to upper case and trims it.
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 float InverseDistanceUnits()
Gets the inverse distance units.
Declares the simulator class.
Declares the activated item manager class.
Declares the external stimuli manager class.
Declares the receptive field class.