Go to the documentation of this file. 1 #ifndef CNOID_UTIL_SCENE_UPDATE_H
2 #define CNOID_UTIL_SCENE_UPDATE_H
29 typedef std::vector<SgObject*>
Path;
34 : path_(org.path_), action_(org.action_), initialPathCapacity_(0) { }
38 int action()
const {
return action_; }
39 bool hasAction(
int act)
const {
return action_ & act; }
48 path_.reserve(initialPathCapacity_);
54 [[deprecated(
"Use setAction.")]]
56 [[deprecated(
"Use clearPath()")]]
62 unsigned char initialPathCapacity_;
83 SgUpdateRef(
bool doCreateTmpUpdate) : isTmpUpdate(doCreateTmpUpdate) {
84 if(doCreateTmpUpdate){
91 operator bool()
const {
return pUpdate !=
nullptr; }
@ Added
Definition: SceneUpdate.h:15
Definition: SceneUpdate.h:66
@ Removed
Definition: SceneUpdate.h:16
void addAction(int act)
Definition: SceneUpdate.h:42
SgUpdateRef(SgUpdate *pUpdate)
Definition: SceneUpdate.h:81
bool hasAction(int act) const
Definition: SceneUpdate.h:39
@ REMOVED
Definition: SceneUpdate.h:24
SgUpdate()
Definition: SceneUpdate.h:31
void reservePathCapacity(int n)
Definition: SceneUpdate.h:37
SgUpdateRef(SgUpdate &update)
Definition: SceneUpdate.h:80
@ ADDED
Definition: SceneUpdate.h:23
~SgUpdate()
Definition: SceneUpdate.h:35
void clear()
Definition: SceneUpdate.h:57
const Path & path() const
Definition: SceneUpdate.h:43
Definition: SceneUpdate.h:10
int action() const
Definition: SceneUpdate.h:38
SgUpdate(int action)
Definition: SceneUpdate.h:32
void pushNode(SgObject *node)
Definition: SceneUpdate.h:44
SgUpdate & operator*()
Definition: SceneUpdate.h:93
Definition: SceneUpdate.h:73
void popNode()
Definition: SceneUpdate.h:45
void setInitialPathCapacity(unsigned char n)
Definition: SceneUpdate.h:36
Definition: AbstractSceneLoader.h:11
void setAction(int act)
Definition: SceneUpdate.h:41
SgUpdate * operator->()
Definition: SceneUpdate.h:94
Action
Definition: SceneUpdate.h:13
void clearPath()
Definition: SceneUpdate.h:46
void resetAction(int act=None)
Definition: SceneUpdate.h:55
@ BBOX_UPDATED
Definition: SceneUpdate.h:26
SgUpdateRef(const SgUpdateRef &org)
Definition: SceneUpdate.h:82
@ Modified
Definition: SceneUpdate.h:19
SgUpdate & withAction(int act)
Definition: SceneUpdate.h:40
@ GeometryModified
Definition: SceneUpdate.h:17
~SgUpdateRef()
Definition: SceneUpdate.h:90
SgUpdate(const SgUpdate &org)
Definition: SceneUpdate.h:33
@ MODIFIED
Definition: SceneUpdate.h:25
SgUpdateRef()
Definition: SceneUpdate.h:79
Definition: SceneGraph.h:28
@ NONE
Definition: SceneUpdate.h:22
@ AppearanceModified
Definition: SceneUpdate.h:18
SgUpdateRef(bool doCreateTmpUpdate)
Definition: SceneUpdate.h:83
std::vector< SgObject * > Path
Definition: SceneUpdate.h:29
SgTmpUpdate()
Definition: SceneUpdate.h:69
@ None
Definition: SceneUpdate.h:14