diff --git a/specs/t27f/deck.t27 b/specs/t27f/deck.t27 index 5d7cabab99..30f3e7fdef 100644 --- a/specs/t27f/deck.t27 +++ b/specs/t27f/deck.t27 @@ -117,6 +117,11 @@ pub const MIN_FOCUS_R_PX : i32 = 60; /// on screen while the camera moves under it. pub const FADE_OUT_FRAMES : i32 = 8; +/// A still is one picture, not a video: nothing moves, so nothing fades. reel's still_frame is the +/// last frame of a scene, where card_alpha is 0 -- a still drawn with card_alpha would show no card. +/// Draw stills at the card's settled opacity instead. +pub const STILL_CARD_ALPHA : i32 = 1000; + /// The palette, 0xRRGGBB. pub const BACKDROP : i32 = 0x06060B; pub const AURORA_COUNT : i32 = 4; @@ -592,6 +597,21 @@ test the_card_fades_and_never_pops { } } +test a_still_shows_the_whole_card { + var n : i32 = MIN_SCENE_FRAMES; + while (n <= 300) { + // the still's card is the card the video shows once it has landed, never the faded one + assert STILL_CARD_ALPHA == card_alpha(TRANSITION_FRAMES, n); + assert STILL_CARD_ALPHA != card_alpha(n - 1, n); + var k : i32 = 0; + while (k < n) { + assert card_alpha(k, n) <= STILL_CARD_ALPHA; + k = k + 1; + } + n = n + 1; + } +} + test text_reads_on_glass { const under : i32 = worst_under_card(); assert luma(TEXT) - under >= MIN_TEXT_CONTRAST;