Skip to content
Snippets Groups Projects
Commit 97ccb30a authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

better fix for getEdgeVertices in Quad9

parent b8ed889f
No related branches found
No related tags found
No related merge requests found
......@@ -283,10 +283,9 @@ class MQuadrangle9 : public MQuadrangle {
virtual void getEdgeRep(int num, double *x, double *y, double *z, SVector3 *n);
virtual void getEdgeVertices(const int num, std::vector<MVertex*> &v) const
{
// v.resize(3);
MQuadrangle::getEdgeVertices(num, v);
v.push_back(_vs[num]);
// v[2] = _vs[num];
v.resize(3);
MQuadrangle::_getEdgeVertices(num, v);
v[2] = _vs[num];
}
virtual int getNumFacesRep();
virtual void getFaceRep(int num, double *x, double *y, double *z, SVector3 *n);
......
......@@ -258,7 +258,12 @@ static void drawVertexLabel(drawContext *ctx, GEntity *e, MVertex *v,
glColor4ubv((GLubyte *) & CTX::instance()->color.mesh.vertexSup);
else
glColor4ubv((GLubyte *) & CTX::instance()->color.mesh.vertex);
glRasterPos3d(v->x(), v->y(), v->z());
double offset = (0.5 * CTX::instance()->mesh.pointSize +
0.3 * CTX::instance()->glFontSize) * ctx->pixel_equiv_x;
glRasterPos3d(v->x() + offset / ctx->s[0],
v->y() + offset / ctx->s[1],
v->z() + offset / ctx->s[2]);
ctx->drawString(str);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment