Splits the control surface the game consumes from the RIO board into RIOBase (8 virtuals + the five analog scalars); the serial RIO is now one implementation of it. Adds two new ones: - PadRIO (L4CONTROLS=PAD): in-process RIO speaking the full surface from an XInput controller + PC keyboard using vRIO's default profile (left stick/WASD = stick, triggers/Q,E = pedals, right stick Y/PgUp,PgDn = rate throttle that holds position, A/Space = trigger, B/R = reverse, dpad/arrows = hat, Start,Back/F1,F2 = config). Samples in GetNextEvent so button latency does not depend on the 15 s menu-time analog cadence; hot-plugs pads; L4PADFLIP=XY inverts stick axes; lamp commands land in lampState[] for the planned on-screen cockpit panel. The stock VTVRIOMapper/lamp/button path runs unchanged. - PlasmaScreen (L4PLASMA=SCREEN): the 128x32 plasma glass as a desktop window in plasma orange (L4PLASMASCALE, default x4), rendering the same Video8BitBuffered surface the gauge system always drew; no COM port. Verified in the sandbox with vRIO off and no serial devices: boots to a running mission, controller hot-detected, plasma window drawing live game content (score readout). BUILD.md 4 documents the desktop environ.ini and bindings; roadmap updated. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
51 lines
1.1 KiB
C++
51 lines
1.1 KiB
C++
#pragma once
|
|
|
|
#include "l4vb8.h"
|
|
|
|
//########################################################################
|
|
//############################ PlasmaScreen ##############################
|
|
//########################################################################
|
|
//
|
|
// The cockpit's 128x32 plasma display rendered as a desktop window
|
|
// instead of streamed to serial hardware. The gauge system draws into
|
|
// the same Video8BitBuffered surface it always has; Update() just blits
|
|
// the buffer into a small "glass" window in plasma orange.
|
|
//
|
|
// Selected with L4PLASMA=SCREEN. L4PLASMASCALE sets the pixel size
|
|
// (default 4 -> a 512x128 window).
|
|
//
|
|
class PlasmaScreen :
|
|
public Video8BitBuffered
|
|
{
|
|
public:
|
|
enum
|
|
{
|
|
plasmaWidth=128,
|
|
plasmaHeight=32
|
|
};
|
|
|
|
PlasmaScreen();
|
|
|
|
~PlasmaScreen();
|
|
|
|
Logical
|
|
TestInstance() const;
|
|
|
|
Logical
|
|
Update(Logical forceall);
|
|
|
|
void
|
|
WaitForUpdate();
|
|
|
|
protected:
|
|
void
|
|
CreateGlassWindow();
|
|
|
|
void
|
|
*window; // HWND, kept untyped so this header stays lean
|
|
void
|
|
*bitmapInfo; // BITMAPINFOHEADER + 256-entry orange palette
|
|
int
|
|
scale;
|
|
};
|