Skip to content

Commit

Permalink
Arch: Fixed SectionPlane outside objects bug in ArchSectionPlane - Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
yorikvanhavre committed Mar 1, 2021
1 parent c1408f1 commit deaf748
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/Mod/Arch/ArchSectionPlane.py
Expand Up @@ -211,11 +211,11 @@ def getCutShapes(objs,cutplane,onlySolids,clip,joinArch,showHidden,groupSshapesB

cutface,cutvolume,invcutvolume = ArchCommands.getCutVolume(cutplane,shapes,clip)
shapes = []
if cutvolume:
for o, shapeList in objectShapes:
tmpSshapes = []
for sh in shapeList:
for sol in sh.Solids:
for o, shapeList in objectShapes:
tmpSshapes = []
for sh in shapeList:
for sol in sh.Solids:
if cutvolume:
if sol.Volume < 0:
sol.reverse()
c = sol.cut(cutvolume)
Expand All @@ -235,6 +235,8 @@ def getCutShapes(objs,cutplane,onlySolids,clip,joinArch,showHidden,groupSshapesB
if showHidden:
c = sol.cut(invcutvolume)
hshapes.append(c)
else:
shapes.extend(sol.Solids)

if len(tmpSshapes) > 0:
sshapes.extend(tmpSshapes)
Expand Down

0 comments on commit deaf748

Please sign in to comment.