Commit 36cc14cb authored by Jan Möbius's avatar Jan Möbius
Browse files

Get skeleton colors for new renderer from material nodes

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@15894 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 5f6914cb
......@@ -776,11 +776,9 @@ void SkeletonNodeT<SkeletonType>::getRenderObjects(IRenderer* _renderer,
Vec4f jointColor;
getJointColor(_mat->specularColor(), jointColor);
getJointColor(_mat->diffuseColor(), jointColor);
// draw points
for (unsigned int i = 0; i < _drawMode.getNumLayers(); ++i)
{
const DrawModes::DrawModeProperties* props = _drawMode.getLayer(i);
......@@ -840,7 +838,7 @@ void SkeletonNodeT<SkeletonType>::getRenderObjects(IRenderer* _renderer,
ro.setupShaderGenFromDrawmode(props);
Vec4f baseColor = _mat->ambientColor();
ro.setMaterial(_mat);
// draw the bones
for(it = skeleton_.begin(); it != skeleton_.end(); ++it) {
......@@ -854,10 +852,6 @@ void SkeletonNodeT<SkeletonType>::getRenderObjects(IRenderer* _renderer,
if (parent == 0)
continue;
//select joint color
ro.emissive = Vec3f(baseColor[0], baseColor[1], baseColor[2]);
ro.specular = Vec3f(0.0f, 0.0f, 0.0f);
Vec3d parentPos = pose->globalTranslation(parent->id());
Vec3d jointPos = pose->globalTranslation(joint->id());
......
Supports Markdown
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