Example #1
0
 void setBaseTransform(const Transform& baseTransform)
 {
     assert (individualTransforms.size() == 1);
     assert (absoluteTransforms.size() == 1);
     
     individualTransforms.front() = absoluteTransforms.front() = baseTransform;
 }
Example #2
0
 void pop()
 {
     assert (individual.size() > 1);
     
     individual.pop_back();
     Transform result = scale(1);
     for (Transforms::reverse_iterator it = individual.rbegin(),
             end = individual.rend(); it != end; ++it)
         result = multiply(result, *it);
     makeCurrent(result);
 }
Example #3
0
 void popTransform()
 {
     assert (individualTransforms.size() > 1);
     
     individualTransforms.pop_back();
     // TODO: If currentTransform() wouldn't have to be .back(), then I think
     // this could be optimized away and just be pop_back too. Or not?
     Transform result = scale(1);
     for (Transforms::reverse_iterator it = individualTransforms.rbegin(),
             end = individualTransforms.rend(); it != end; ++it)
         result = multiply(result, *it);
     makeCurrentTransform(result);
 }