From 180eb77733da46e0eda7e182d023cb45f25fa1d2 Mon Sep 17 00:00:00 2001 From: DeepSOIC Date: Sun, 18 Oct 2015 17:18:38 +0300 Subject: [PATCH] CompoundFilter/Explode: proper fix of placement bug --- CompoundFilter.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/CompoundFilter.py b/CompoundFilter.py index a257b4d..576d707 100644 --- a/CompoundFilter.py +++ b/CompoundFilter.py @@ -139,10 +139,13 @@ class _CompoundFilter: obj.Shape = markers.getNullShapeShape(scale) raise ValueError('Nothing passes through the filter') #Feeding empty compounds to FreeCAD seems to cause rendering issues, otherwise it would have been a good idea to output nothing. - if len(rst) > 1 or True: + if len(rst) > 1: obj.Shape = Part.makeCompound(rst) else: # don't make compound of one shape, output it directly - obj.Shape = rst[0] + sh = rst[0] + sh = sh.transformGeometry(sh.Placement.toMatrix()) + sh.Placement = FreeCAD.Placement() + obj.Shape = sh return