Move pointer assignments from CopyFromSpec() to PointToLocal().
Note that these internal pointers are inherited from the public structs and are unused internally. PiperOrigin-RevId: 652414750 Change-Id: I5e42503bce8e9019291ec0a1f8c4278438474e9b
This commit is contained in:
committed by
Copybara-Service
parent
3d28a1d8c7
commit
cf61d88e41
+22
-22
@@ -202,6 +202,13 @@ void mjCMesh::PointToLocal() {
|
||||
spec.plugin.name = &plugin_name;
|
||||
spec.plugin.instance_name = &plugin_instance_name;
|
||||
spec.info = &info;
|
||||
file = &file_;
|
||||
content_type = &content_type_;
|
||||
uservert = &vert_;
|
||||
usernormal = &normal_;
|
||||
userface = &face_;
|
||||
usertexcoord = &texcoord_;
|
||||
userfacetexcoord = &facetexcoord_;
|
||||
}
|
||||
|
||||
|
||||
@@ -215,14 +222,7 @@ void mjCMesh::CopyFromSpec() {
|
||||
face_ = spec_face_;
|
||||
texcoord_ = spec_texcoord_;
|
||||
facetexcoord_ = spec_facetexcoord_;
|
||||
file = &file_;
|
||||
content_type = &content_type_;
|
||||
maxhullvert_ = spec.maxhullvert;
|
||||
uservert = &vert_;
|
||||
usernormal = &normal_;
|
||||
userface = &face_;
|
||||
usertexcoord = &texcoord_;
|
||||
userfacetexcoord = &facetexcoord_;
|
||||
plugin.active = spec.plugin.active;
|
||||
plugin.instance = spec.plugin.instance;
|
||||
plugin.name = spec.plugin.name;
|
||||
@@ -1993,6 +1993,16 @@ void mjCSkin::PointToLocal() {
|
||||
spec.vertid = &spec_vertid_;
|
||||
spec.vertweight = &spec_vertweight_;
|
||||
spec.info = &info;
|
||||
file = &spec_file_;
|
||||
material = &spec_material_;
|
||||
vert = &spec_vert_;
|
||||
texcoord = &spec_texcoord_;
|
||||
face = &spec_face_;
|
||||
bodyname = &spec_bodyname_;
|
||||
bindpos = &spec_bindpos_;
|
||||
bindquat = &spec_bindquat_;
|
||||
vertid = &spec_vertid_;
|
||||
vertweight = &spec_vertweight_;
|
||||
}
|
||||
|
||||
|
||||
@@ -2017,16 +2027,6 @@ void mjCSkin::CopyFromSpec() {
|
||||
bindquat_ = spec_bindquat_;
|
||||
vertid_ = spec_vertid_;
|
||||
vertweight_ = spec_vertweight_;
|
||||
file = &spec_file_;
|
||||
material = &spec_material_;
|
||||
vert = &spec_vert_;
|
||||
texcoord = &spec_texcoord_;
|
||||
face = &spec_face_;
|
||||
bodyname = &spec_bodyname_;
|
||||
bindpos = &spec_bindpos_;
|
||||
bindquat = &spec_bindquat_;
|
||||
vertid = &spec_vertid_;
|
||||
vertweight = &spec_vertweight_;
|
||||
}
|
||||
|
||||
|
||||
@@ -2399,6 +2399,11 @@ void mjCFlex::PointToLocal() {
|
||||
spec.texcoord = &spec_texcoord_;
|
||||
spec.elem = &spec_elem_;
|
||||
spec.info = &info;
|
||||
material = &material_;
|
||||
vertbody = &vertbody_;
|
||||
vert = &vert_;
|
||||
texcoord = &texcoord_;
|
||||
elem = &elem_;
|
||||
}
|
||||
|
||||
|
||||
@@ -2419,11 +2424,6 @@ void mjCFlex::CopyFromSpec() {
|
||||
vert_ = spec_vert_;
|
||||
texcoord_ = spec_texcoord_;
|
||||
elem_ = spec_elem_;
|
||||
material = &material_;
|
||||
vertbody = &vertbody_;
|
||||
vert = &vert_;
|
||||
texcoord = &texcoord_;
|
||||
elem = &elem_;
|
||||
|
||||
// clear precompiled asset. TODO: use asset cache
|
||||
nedge = 0;
|
||||
|
||||
Reference in New Issue
Block a user