source: cpp/frams/model/modelobj.h @ 1299

Last change on this file since 1299 was 1277, checked in by Maciej Komosinski, 10 months ago

Added Model.is_valid

File size: 1.2 KB
Line 
1#ifndef _MODELOBJ_H_
2#define _MODELOBJ_H_
3
4#include "model.h"
5
6extern ParamEntry modelobj_paramtab[];
7
8class ModelObj : public Model
9{
10public:
11#define STATRICKCLASS ModelObj
12
13        PARAMGETDEF(geno);
14        PARAMPROCDEF(p_newfromstring);
15        PARAMPROCDEF(p_newfromgeno);
16        PARAMPROCDEF(p_newwithcheckpoints);
17
18#define GETDELEGATE(name,type,value) PARAMGETDEF(name) {arg1->set ## type (value);}
19        GETDELEGATE(numparts, Int, getPartCount())
20        GETDELEGATE(numjoints, Int, getJointCount())
21        GETDELEGATE(numneurons, Int, getNeuroCount())
22        GETDELEGATE(numconnections, Int, getConnectionCount())
23        GETDELEGATE(numcheckpoints, Int, getCheckpointCount())
24#undef GETDELEGATE
25       
26        PARAMGETDEF(is_valid);
27        PARAMPROCDEF(p_getpart);
28        PARAMPROCDEF(p_getjoint);
29        PARAMPROCDEF(p_getneuro);
30        PARAMGETDEF(bboxsize);
31        PARAMPROCDEF(p_getcheckpoint);
32        PARAMGETDEF(shape_type);
33        PARAMGETDEF(solid_model);
34
35#undef STATRICKCLASS
36
37        static ExtObject makeStaticObject(Model* g);
38        static ExtObject makeDynamicObject(Model* g);
39        static Model* fromObject(const ExtValue& v, bool warn = true);
40        static ParamInterface* getInterface();
41        static Param& getStaticParam();
42        static Param& getDynamicParam();
43};
44
45#endif
Note: See TracBrowser for help on using the repository browser.