#118: the flash overlay lands in the REAL compositor (L4VB16) + [ckflash] probe
The first visibility fix painted L4GLASSWIN -- a window the operator's single-window layout never shows. The main-window cockpit compositor is BTDrawCockpitPanels (L4VB16): same under-the-surface masking, so the RIO flash was again invisible. The 3b overlay now re-draws flashing lamps (state & 3) above the surfaces there, tick-phased; [ckflash] (BT_LAMP_LOG) logs each animated draw. Verified in-engine: addr 0x27 state 0x37 alternating shade 1 -> 3. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
5f79dcee3b
commit
86a6bbb9cb
@@ -1180,6 +1180,36 @@ void BTDrawCockpitPanels(LPDIRECT3DDEVICE9 device)
|
||||
}
|
||||
}
|
||||
|
||||
// 3b) FLASHING lamps re-draw ON TOP of the surfaces (#118): the alarm
|
||||
// invites (gotoEngineering / engEject, RIO flash bits state & 3)
|
||||
// were invisible under the imagery -- only the protruding edge
|
||||
// pixels blinked, and the operator "never saw it flash". The pod's
|
||||
// keys were physical backlit buttons beside the CRT; when one
|
||||
// carries a FLASH state, give it its full face back.
|
||||
for (int i = 0; i < L.buttonCount; i++)
|
||||
{
|
||||
const BTCockpitBtn &b = L.buttons[i];
|
||||
int state = CkLampState(b.address);
|
||||
if ((state & 3) == 0) continue; // not flashing
|
||||
int shade = BTLampBrightnessOf(state, tick);
|
||||
{
|
||||
static int s_flog = -1;
|
||||
if (s_flog < 0) s_flog = (getenv("BT_LAMP_LOG") != 0) ? 1 : 0;
|
||||
static unsigned long s_lastLog = 0;
|
||||
if (s_flog && tick - s_lastLog > 1000)
|
||||
{
|
||||
s_lastLog = tick;
|
||||
DEBUG_STREAM << "[ckflash] addr 0x" << std::hex << b.address
|
||||
<< " state 0x" << state << std::dec << " shade " << shade
|
||||
<< " at (" << b.x << "," << b.y << ")\n" << std::flush;
|
||||
}
|
||||
}
|
||||
D3DCOLOR fill, border;
|
||||
CkLampColors(b.colorClass, shade, b.inert, &fill, &border);
|
||||
CkFill(device, b.x, b.y, b.w, b.h, border);
|
||||
CkFill(device, b.x + 1, b.y + 1, b.w - 2, b.h - 2, fill);
|
||||
}
|
||||
|
||||
// 4) Flight-block labels (on top; the blue faces aren't covered by surfaces).
|
||||
for (int i = 0; i < L.buttonCount; i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user