source: NonGTP/FCollada/FCDocument/FCDPhysicsMaterial.h @ 964

Revision 964, 1.3 KB checked in by igarcia, 19 years ago (diff)
RevLine 
[964]1/*
2        Copyright (C) 2005-2006 Feeling Software Inc.
3        MIT License: http://www.opensource.org/licenses/mit-license.php
4*/
5
6#ifndef _FCD_PHYSICSMATERIAL_H_
7#define _FCD_PHYSICSMATERIAL_H_
8
9#include "FCDocument/FCDEntity.h"
10
11class FCDocument;
12
13class FCOLLADA_EXPORT FCDPhysicsMaterial : public FCDEntity
14{
15private:
16        DeclareObjectType;
17        float staticFriction;
18        float dynamicFriction;
19        float restitution;
20
21public:
22        FCDPhysicsMaterial(FCDocument* document);
23        virtual ~FCDPhysicsMaterial();
24
25        // Accessors
26        virtual Type GetType() const { return FCDEntity::PHYSICS_MATERIAL; }
27        float GetStaticFriction() const { return staticFriction; }
28        void  SetStaticFriction(float _staticFriction) { staticFriction = _staticFriction; }
29        float GetDynamicFriction() const { return dynamicFriction; }
30        void  SetDynamicFriction(float _dynamicFriction) { dynamicFriction = _dynamicFriction; }
31        float GetRestitution() const { return restitution; }
32        void  SetRestitution(float _restitution) { restitution = _restitution;}
33
34        // Cloning
35        FCDPhysicsMaterial* Clone();
36
37        // Parse COLLADA document's <material> element
38        virtual FUStatus LoadFromXML(xmlNode* physicsMaterialNode);
39
40        // Write out the <material> element to the COLLADA xml tree
41        virtual xmlNode* WriteToXML(xmlNode* parentNode) const;
42};
43
44#endif // _FCD_MATERIAL_H_
Note: See TracBrowser for help on using the repository browser.