fix(annotation): apply object context scaling

This commit is contained in:
Hakan Seven committed 2026-08-02 03:02:11 +03:00
1 parent c4c673336c
commit 5909540ebf
4 files changed
+103 -9

No files matched your search

+14
View File
@@ -361,6 +361,20 @@ pub(crate) fn tessellate_entity(
let e = contextual.as_ref();
let h = e.common().handle;
let sel = selected.contains(&h);
// Per-object annotation contexts store each representation relative to the
// native/default scale. Resolve that ratio once before TEXT/MTEXT,
// DIMENSION, and MULTILEADER reach their independent tessellation paths.
let anno_scale = if matches!(
e,
EntityType::Text(_)
| EntityType::MText(_)
| EntityType::Dimension(_)
| EntityType::MultiLeader(_)
) {
crate::scene::annotative::effective_annotation_scale(document, e, anno_scale)
} else {
anno_scale
};
// Frustum + LOD cull for non-Insert, non-Viewport entities. Insert is
// handled separately (its WCS bbox depends on the block defn AABB ×