重构 Autocal 采集页:单一队列与控制器驱动的主按钮

选点、对准、加载与录像分散在两个面板,状态靠隐藏相位判断。现改由不依赖 Qt 的采集控制器驱动,并加入录像选项、汇总平铺副本、保持到时自动结束、会话结束回到空闲,以及无设备时的模拟采集。已运行 Autocal 非 Qt 测试并通过范围内门禁;界面测试待 Windows 复核,未做实机验收。
This commit is contained in:
ykcheungab
2026-10-18 16:04:32 +08:00
parent 85d0b396e3
commit 06e06126ca
44 changed files with 7769 additions and 2218 deletions
@@ -75,3 +75,28 @@ def test_a_window_that_closes_still_lands_in_the_scratch_directory(qt_app):
after = INSTALLED.read_bytes() if INSTALLED.is_file() else None
assert after == before, "closing a test window rewrote the installed preferences"
def test_a_stored_recording_block_without_the_newer_keys_gets_each_default():
"""The upgrade path for the recording preference, through the same net.
A stored ``recording`` block replaces the whole default block, exactly like
``safety_limits``: a codec or the lossless flag added later would otherwise
read as absent and the recorder would be configured from a hole.
"""
import json
from orisys_app_shared.paths import preference_path
from orisys_autocal.preferences import load_preferences
from orisys_autocal.recording_options import RecordingOptions, default_options
path = preference_path()
path.parent.mkdir(parents=True, exist_ok=True)
path.write_text(json.dumps({"recording": {"video": False}}), encoding="utf-8")
options = default_options(load_preferences())
assert options == RecordingOptions(video=False)
assert options.codec == "mp4v"
assert options.lossless_frames is False