Present replay 3D with the cursor and open Analyze on a remembered video
Replay left the 3D pane on the rest mesh or a sparse overlay, and Analyze skipped the setup dialog unless the file was re-picked. Live Run no longer starts a chain on a video path. Verified with Studio tests for flush, overlay mask, Analyze open, live-video refusal, and locales.
This commit is contained in:
@@ -674,3 +674,52 @@ def test_the_first_frame_is_the_prompt_s_default_reference(
|
||||
assert dialog.reference_spin.value() == 4
|
||||
finally:
|
||||
dialog.deleteLater()
|
||||
|
||||
|
||||
def test_the_prompt_restores_a_prior_reference_and_no_calibration(
|
||||
bare_clip, window, qt_app
|
||||
):
|
||||
"""Reopening Analysis setup must show the answers from the last pass."""
|
||||
facts = bare_video.probe(bare_video.resolve_video(bare_clip))
|
||||
dialog = VideoAnalysisDialog(
|
||||
video=bare_clip,
|
||||
facts=facts,
|
||||
catalog=scan_sensor_catalog(),
|
||||
window=window,
|
||||
initial_profile="shipped/box",
|
||||
prefer_no_calibration=True,
|
||||
initial_reference_frame=4,
|
||||
)
|
||||
try:
|
||||
assert dialog.reference_spin.value() == 4
|
||||
assert dialog.choice().reference_frame == 4
|
||||
assert dialog.calibration_combo.currentData() == "none"
|
||||
assert dialog.choice().calibration is None
|
||||
finally:
|
||||
dialog.deleteLater()
|
||||
|
||||
|
||||
def test_analysis_setup_reopens_the_prompt_after_the_first_pass(
|
||||
bare_clip, window, monkeypatch
|
||||
):
|
||||
"""View ▸ Analysis setup… asks again; a new reference frame starts a new pass."""
|
||||
open_bare_video(window, bare_clip, monkeypatch, reference=None)
|
||||
settle(window)
|
||||
first = window.replay_ctl.recording_directory()
|
||||
assert first is not None
|
||||
assert bare_video.is_synthetic(first)
|
||||
|
||||
# The box stitch probe consumes the first decoded frames; a reference that names
|
||||
# one of them is refused. Frame 10 is past that offset on this clip.
|
||||
seen: list = []
|
||||
answer_prompt(monkeypatch, profile="shipped/box", reference=10, seen=seen)
|
||||
window.replay_ctl.on_analysis_setup()
|
||||
settle(window)
|
||||
|
||||
assert seen, "Analysis setup did not open the dialog"
|
||||
second = window.replay_ctl.recording_directory()
|
||||
assert second is not None
|
||||
block = bare_video.read_synthetic(second)
|
||||
assert block is not None
|
||||
assert int(block["reference_frame"]) == 10
|
||||
assert window.replay_ctl.available_result() is not None
|
||||
|
||||
Reference in New Issue
Block a user