The pod drove five monochrome MFDs from the color channels of two video outputs - SVGA16 packs bit-slices of the shared gauge canvas into R/G/B of gauge window 3 (upper MFDs) and R/G of window 4 (lower MFDs), with the map palettized on the secondary and physically mounted portrait. The desktop reconstruction previously required an external BitBlt-mirror wrapper. With L4MFDSPLIT=1, SVGA16 renders each display into its own window (MFDSplitView, plain GDI) straight from the canvas + port bit-masks: five green-screen MFD windows and the 90CW-rotated Map, tiled in the pod grid to the right of the main view (L4MFDSCALE percent, default 50). The packed D3D windows stay hidden but keep presenting off-screen, leaving the original path untouched. Handles spanning mode (2-window setups). Also: the plasma glass now opens directly below the main view (clamped to the work area; L4PLASMAPOS=x,y overrides) per playtest feedback. Verified: window grid comes up as main + 5 MFDs + Map + plasma with the packed windows hidden; screenshots confirm a green MFD score readout and the portrait tactical map rendering correctly. dist packer and BUILD.md updated; the launcher wrapper is obsolete for split-mode use. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
54 lines
1.2 KiB
C++
54 lines
1.2 KiB
C++
#pragma once
|
|
|
|
#include "..\munga\style.h"
|
|
|
|
//########################################################################
|
|
//############################ MFDSplitView ##############################
|
|
//########################################################################
|
|
//
|
|
// One desktop window showing a single cockpit display, used by SVGA16's
|
|
// split mode (L4MFDSPLIT=1). The pod hardware packed the five monochrome
|
|
// MFDs into the color channels of two video outputs and mounted the map
|
|
// display rotated; on a desktop each display gets its own window instead.
|
|
//
|
|
// SVGA16 fills Pixels() (32bpp top-down, sourceWidth x sourceHeight as
|
|
// passed - already swapped by the caller for the rotated map) and calls
|
|
// Repaint(). Closing a view window just hides it.
|
|
//
|
|
class MFDSplitView
|
|
{
|
|
public:
|
|
MFDSplitView(
|
|
const char *title,
|
|
int source_width,
|
|
int source_height,
|
|
int client_width,
|
|
int client_height,
|
|
int x,
|
|
int y
|
|
);
|
|
|
|
~MFDSplitView();
|
|
|
|
Logical
|
|
TestInstance() const;
|
|
|
|
unsigned long *
|
|
Pixels()
|
|
{ return pixels; }
|
|
|
|
void
|
|
Repaint();
|
|
|
|
protected:
|
|
void
|
|
*window; // HWND
|
|
void
|
|
*blitInfo; // MFDViewBlit (header + source dims), see .cpp
|
|
unsigned long
|
|
*pixels;
|
|
int
|
|
sourceWidth,
|
|
sourceHeight;
|
|
};
|