mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
Fix #3417. Apply 50mm offset to camera to ensure text isn't "behind" the camera. This 50mm convention is used in quite a few places, we should standardise it.
This commit is contained in:
@@ -93,7 +93,7 @@ class Drawing(blenderbim.core.tool.Drawing):
|
||||
camera = get_camera_from_annotation_object(obj) or bpy.context.scene.camera
|
||||
|
||||
current_pos = camera.matrix_world.inverted() @ obj.location
|
||||
current_pos.z = -camera.data.clip_start
|
||||
current_pos.z = -camera.data.clip_start - 0.05
|
||||
current_pos = camera.matrix_world @ current_pos
|
||||
obj.location = current_pos
|
||||
|
||||
@@ -1497,6 +1497,7 @@ class Drawing(blenderbim.core.tool.Drawing):
|
||||
drawing = tool.Ifc.get_entity(camera)
|
||||
|
||||
filtered_elements = cls.get_drawing_elements(drawing) | cls.get_drawing_spaces(drawing)
|
||||
filtered_elements.add(drawing)
|
||||
for view_layer_object in bpy.context.view_layer.objects:
|
||||
element = tool.Ifc.get_entity(view_layer_object)
|
||||
if not element:
|
||||
|
||||
Reference in New Issue
Block a user