s-leger / archipack

Archipack for blender 2.79
https://blender-archipack.org
GNU General Public License v3.0
356 stars 49 forks source link

bmesh.update_edit_mesh(me, True) is incorrect #353

Closed SKYnv closed 1 year ago

SKYnv commented 1 year ago

Archipack version: 2.5.1

Blender version: 3.4

Os version: win 10

Description of the issue: https://docs.blender.org/api/current/bmesh.html#bmesh.update_edit_mesh

s-leger commented 1 year ago

Thanks for reporting, I'm unable to make it throw any error here ? As far as i can tell, looks like arguments are optional with default to true.

SKYnv commented 1 year ago

Thanks for reporting, I'm unable to make it throw any error here ? As far as i can tell, looks like arguments are optional with default to true.

Yes, but you have one bmesh.update_edit_mesh(me, False) at least. I just trying to do extrude wall from this dxf https://disk.yandex.ru/d/JH9UvPd64FWRSw and got errors. But now a can't reproduce that. Maybe it's because i made set origin to geom for dxf. rotate and apply rotation. Anyway I can't make walls from this imported dxf( only if I set wall thickness to 10 and walls created outside from plan.

Thanks!

s-leger commented 1 year ago

You parobably are facing with a huge scale issue in your imported dxf. Ensure that overall size is relevant, like walls should never require a 10 (meter) thickness, scale your blueprint according real world and apply scale.

SKYnv commented 1 year ago

You parobably are facing with a huge scale issue in your imported dxf. Ensure that overall size is relevant, like walls should never require a 10 (meter) thickness, scale your blueprint according real world and apply scale.

I've imported dxf with unit scale 0.001 and it's have a right size i think. (16mx10m in blender units)

s-leger commented 1 year ago

Ok, assuming a "real world" scale of your blueprint, you must keep the "max wall thickness" for detection as low as possible. A 0.7m should be a large maximum, and it is probably better to lower to something like 0.35 depending on larger wall in the project. When too large, the code is not able to properly sort walls polygons and will generate uncorrect results. Also keep in mind that walls are expected to be strictly parallel on both sides. Should it fail you still may rely on draw tool and snap to bleuprint vertex.