Skip to content

Commit

Permalink
Remove use of existing pointers in lambda function since scaling migh…
Browse files Browse the repository at this point in the history
…t create a new Model in the future.
  • Loading branch information
tkuchida committed Nov 14, 2017
1 parent 514fefb commit 471fb34
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions Applications/Scale/test/testScale.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -581,12 +581,20 @@ void scalePhysicalOffsetFrames()

State& s = model->initSystem();

const std::string pathToAct1 = act1->getAbsolutePathString();
const std::string pathToAct2 = act2->getAbsolutePathString();

// Ensure PathPoints are coincident before scaling.
auto testPathPointLoc =
[&](const State& s, const std::string& msg) -> void
{
const PathPointSet& pps1 = act1->getGeometryPath().getPathPointSet();
const PathPointSet& pps2 = act2->getGeometryPath().getPathPointSet();
const PathActuator& pa1 =
model->getComponent<PathActuator>(pathToAct1);
const PathActuator& pa2 =
model->getComponent<PathActuator>(pathToAct2);

const PathPointSet& pps1 = pa1.getGeometryPath().getPathPointSet();
const PathPointSet& pps2 = pa2.getGeometryPath().getPathPointSet();

for (int i = 0; i < 2; ++i)
{
Expand Down

0 comments on commit 471fb34

Please sign in to comment.