From 98093a4e8dd1795e04563bd2ae3a45c0a5ce24c5 Mon Sep 17 00:00:00 2001 From: Robert Beckebans Date: Mon, 14 Jan 2013 00:24:11 +0100 Subject: [PATCH] Added long neck GCC compiler workaround from dhewm3 --- neo/d3xp/anim/Anim_Blend.cpp | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/neo/d3xp/anim/Anim_Blend.cpp b/neo/d3xp/anim/Anim_Blend.cpp index cacf5f16..1a261da2 100644 --- a/neo/d3xp/anim/Anim_Blend.cpp +++ b/neo/d3xp/anim/Anim_Blend.cpp @@ -5490,19 +5490,21 @@ bool idAnimator::GetJointLocalTransform( jointHandle_t jointHandle, int currentT // FIXME: overkill CreateFrame( currentTime, false ); - if( jointHandle > 0 ) - { - idJointMat m = joints[ jointHandle ]; - m /= joints[ modelJoints[ jointHandle ].parentNum ]; - offset = m.ToVec3(); - axis = m.ToMat3(); - } - else + // RB: long neck GCC compiler bug workaround from dhewm3 ... + if( jointHandle == 0 ) { offset = joints[ jointHandle ].ToVec3(); axis = joints[ jointHandle ].ToMat3(); + + return true; } + idJointMat m = joints[ jointHandle ]; + m /= joints[ modelJoints[ jointHandle ].parentNum ]; + offset = m.ToVec3(); + axis = m.ToMat3(); + // RB end + return true; }