Skip to content

Commit

Permalink
Fix for issue #3541: Normalize xDir vector for Hole feature to correc…
Browse files Browse the repository at this point in the history
…t hole diameter.
  • Loading branch information
eivindkv committed Jul 28, 2018
1 parent 2ca81da commit c2ada8e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Mod/PartDesign/App/FeatureHole.cpp
Expand Up @@ -985,6 +985,9 @@ App::DocumentObjectExecReturn *Hole::execute(void)
else
xDir = gp_Vec(0, -zDir.Z(), zDir.Y());

// Normalize xDir; this is needed as the computation above does not necessarily give a unit-length vector.
xDir.Normalize();

if ( method == "Dimension" )
length = Depth.getValue();
else if ( method == "UpToFirst" ) {
Expand Down

0 comments on commit c2ada8e

Please sign in to comment.