-
Hello, I have this visitor for the mesh clipping: struct ClipVisitor :
public PMP::Corefinement::Default_visitor<EMesh3>
{
void before_subface_creations(face_descriptor fsplit, const EMesh3 & tm) {
*ofaceindex = fsplit;
}
void after_subface_created(face_descriptor fnew, const EMesh3 & tm) {
if(*is_tm) {
if(tm.property_map<face_descriptor, std::size_t>("f:i").second) {
(*fmap_tm).insert(std::make_pair(fnew, *ofaceindex));
} else {
*is_tm = false;
(*fmap_clipper).insert(std::make_pair(fnew, *ofaceindex));
}
} else {
(*fmap_clipper).insert(std::make_pair(fnew, *ofaceindex));
}
}
void after_face_copy(
face_descriptor fsrc, const EMesh3 & tmsrc,
face_descriptor ftgt, const EMesh3 & tmtgt
) {
(*ftargets).insert(std::make_pair(ftgt, fsrc));
}
ClipVisitor()
: fmap_tm(new MapBetweenFaces()),
fmap_clipper(new MapBetweenFaces()),
ofaceindex(new face_descriptor()),
ftargets(new MapBetweenFaces()),
is_tm(new bool(true))
{}
std::shared_ptr<MapBetweenFaces> fmap_tm;
std::shared_ptr<MapBetweenFaces> fmap_clipper;
std::shared_ptr<MapBetweenFaces> ftargets;
std::shared_ptr<face_descriptor> ofaceindex;
std::shared_ptr<bool> is_tm;
}; And then I get this warning when compiling with gcc:
Would you know how to avoid this warning? |
Beta Was this translation helpful? Give feedback.
Answered by
stla
Apr 8, 2023
Replies: 1 comment
-
I found by googling, sorry. The declared variables must be in the same order as their initialization. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
stla
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I found by googling, sorry. The declared variables must be in the same order as their initialization.