Let the flight recorder dump on its own when one frame flashes.

With flight = 1 and its thumbnails kept, the recorder now also writes a dump when a frame's picture differs strongly from the frame before and the frame after while those two agree, which is what a one-frame flicker looks like. Each thumbnail is reduced to 16x9 cells of mean brightness where the present thread already sees it complete, and a frame is a flash when at least three cells are more than 24 of 255 brighter or darker than in both neighbours, the neighbours being alike in those cells, around them and over the picture as a whole. A camera cut, a fade, a pan and shapes crossing the picture are no flash, and a frame beside one without a thumbnail is not judged. The dump is the one F8 writes, named "flash" with the frame's number in its header line, at most one every 30 seconds. flight_flash = 0 turns it off; flight_flash_diff and flight_flash_cells set the two thresholds.

On the thumbnails of earlier dumps the defaults flag the frames whose scene was white once and nothing in the runs without that fault. tests/flight_flash_check.py checks the test itself on drawn pictures.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
chrg6
2026-11-12 15:15:45 -05:00
parent 95dc476ee7
commit 202fd47ceb
9 changed files with 534 additions and 4 deletions

View File

@@ -858,6 +858,15 @@
# takes longer than flight_spike_ms (0 to 60000).
# flight = 0
# flight_spike_ms = 100
# The flight recorder also saves them after a one-frame flash: a frame whose picture differs from the frame before and
# the frame after while those two are alike (0: not). The three pictures are compared as 16x9 cells of mean
# brightness: at least flight_flash_cells cells (1 to 144) must be more than flight_flash_diff (4 to 255, of 255)
# brighter or darker than in both other frames. Lower values catch smaller and fainter flashes and take more of the
# game's own effects for one. At most one such save every 30 seconds; a flash the game means (lightning) counts
# too, and one while the camera turns fast does not. It needs the recorder's thumbnails. Read at start.
# flight_flash = 1
# flight_flash_diff = 24
# flight_flash_cells = 3
# GPU pass marks: after a GPU crash (device lost) the log names the render pass or dispatch the GPU had started and the
# last one it finished. Unset: on AMD GPUs (VK_AMD_buffer_marker). 1: also on NVIDIA GPUs
# (VK_NV_device_diagnostic_checkpoints), which NVIDIA says costs a little. 0: off.