Reasonable but harmless clang warning cleanup
This commit is contained in:
parent
26e8652a24
commit
d127123513
|
|
@ -205,7 +205,7 @@ MovableCoordinateFrame::MovableCoordinateFrame(float size)
|
||||||
// nothing here
|
// nothing here
|
||||||
}
|
}
|
||||||
|
|
||||||
void MovableCoordinateFrame::Render(QGLWidget* gla)
|
void MovableCoordinateFrame::Render(QGLWidget* gla, QPainter *p)
|
||||||
{
|
{
|
||||||
glPushMatrix();
|
glPushMatrix();
|
||||||
|
|
||||||
|
|
@ -215,7 +215,7 @@ void MovableCoordinateFrame::Render(QGLWidget* gla)
|
||||||
|
|
||||||
glMultMatrix(Inverse(mrot));
|
glMultMatrix(Inverse(mrot));
|
||||||
|
|
||||||
CoordinateFrame::Render(gla);
|
CoordinateFrame::Render(gla,p);
|
||||||
|
|
||||||
glPopMatrix();
|
glPopMatrix();
|
||||||
}
|
}
|
||||||
|
|
@ -272,7 +272,7 @@ Quaternionf MovableCoordinateFrame::GetRotation()
|
||||||
void MovableCoordinateFrame::Rot(float angle_deg,const Point3f axis)
|
void MovableCoordinateFrame::Rot(float angle_deg,const Point3f axis)
|
||||||
{
|
{
|
||||||
Similarityf s;
|
Similarityf s;
|
||||||
s.SetRotate(math::ToRad(angle_deg),(rotation).Rotate(axis));
|
s.SetRotate(math::ToRad(angle_deg),(rotation).Rotate(axis));
|
||||||
Move(s);
|
Move(s);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -361,10 +361,10 @@ void MovableCoordinateFrame::RotateToAlign(const Point3f source, const Point3f d
|
||||||
// must find a axis to flip on
|
// must find a axis to flip on
|
||||||
Plane3f plane(0,source);
|
Plane3f plane(0,source);
|
||||||
axis=plane.Projection(Point3f(1,0,0)); // project a "random" point on source's normal plane
|
axis=plane.Projection(Point3f(1,0,0)); // project a "random" point on source's normal plane
|
||||||
if(axis.Norm() < EPSILON){ // source was ~ [1,0,0]...
|
if(axis.Norm() < EPSILON){ // source was ~ [1,0,0]...
|
||||||
axis=plane.Projection(Point3f(0,1,0));
|
axis=plane.Projection(Point3f(0,1,0));
|
||||||
assert(axis.Norm() > EPSILON); // this point must be good
|
assert(axis.Norm() > EPSILON); // this point must be good
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
rotation = rotation * Quaternionf(angle,axis);
|
rotation = rotation * Quaternionf(angle,axis);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -148,7 +148,7 @@ public:
|
||||||
|
|
||||||
@param glw the GL widget.
|
@param glw the GL widget.
|
||||||
*/
|
*/
|
||||||
virtual void Render(QGLWidget* glw);
|
virtual void Render(QGLWidget* glw,QPainter* p = NULL);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@brief Reset the position and/or the rotation of the coordinate frame.
|
@brief Reset the position and/or the rotation of the coordinate frame.
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue