为二维与三维深度色标增加每帧自适应选项。

默认仍锁定本会话首帧,勾选后两视图按当前帧有效深度共用同一范围。已用深度色标与显示设置测试验证。
This commit is contained in:
ykcheungab
2026-10-07 09:34:57 +08:00
parent 425f0dc9e2
commit 97e80d3d38
14 changed files with 254 additions and 69 deletions
+3
View File
@@ -473,6 +473,7 @@ def test_the_display_settings_round_trip():
flow_off_px=0.35,
flow_grid_spacing=12,
max_arrows=250,
depth_scale_adaptive=True,
color_scale=ColorScale(
descriptor=FieldDescriptor("flow_magnitude", "px", "approximate", False),
lower=0.25,
@@ -495,6 +496,8 @@ def test_the_display_settings_round_trip():
assert restored.color_scale is not None
assert (restored.color_scale.lower, restored.color_scale.upper) == (0.25, 4.5)
assert restored.color_scale.mode == "fixed"
assert restored.depth_scale_adaptive is True
assert scene3d_prefs.settings_from_prefs({}).depth_scale_adaptive is False
def test_a_saved_descriptor_is_never_restored_as_a_measurement():