Commit 774f4e5e authored by Matthias Möller's avatar Matthias Möller
Browse files

fix drawmodes

refs #1758

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@17691 383ad7c9-94d9-4d36-a494-682f7c89f535
parent e13db932
......@@ -324,7 +324,7 @@ void SkeletonNodeT<SkeletonType>::draw(GLState& _state, const DrawModes::DrawMod
// draw points
//
if (_drawMode == DrawModes::POINTS)
if (_drawMode & DrawModes::POINTS)
{
Vec4f jointColor;
getJointColor(_state.diffuse_color(), jointColor);
......@@ -403,22 +403,22 @@ void SkeletonNodeT<SkeletonType>::draw(GLState& _state, const DrawModes::DrawMod
// draw bones
//
if ( (_drawMode == DrawModes::WIREFRAME)
|| (_drawMode == DrawModes::SOLID_FLAT_SHADED)
|| (_drawMode == DrawModes::SOLID_FACES_COLORED)
|| (_drawMode == DrawModes::SOLID_FACES_COLORED_FLAT_SHADED) )
if ( (_drawMode & DrawModes::WIREFRAME)
|| (_drawMode & DrawModes::SOLID_FLAT_SHADED)
|| (_drawMode & DrawModes::SOLID_FACES_COLORED)
|| (_drawMode & DrawModes::SOLID_FACES_COLORED_FLAT_SHADED) )
{
Vec4f baseColor = _state.ambient_color();
if ( (_drawMode == DrawModes::SOLID_FLAT_SHADED)
|| (_drawMode == DrawModes::SOLID_FACES_COLORED_FLAT_SHADED) ){
if ( (_drawMode & DrawModes::SOLID_FLAT_SHADED)
|| (_drawMode & DrawModes::SOLID_FACES_COLORED_FLAT_SHADED) ){
ACG::GLState::shadeModel(GL_FLAT);
ACG::GLState::enable(GL_LIGHTING);
}
if (_drawMode == DrawModes::SOLID_FACES_COLORED)
if (_drawMode & DrawModes::SOLID_FACES_COLORED)
ACG::GLState::shadeModel(GL_FLAT);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment