Assemble the whole cockpit in a single window
The main game window becomes the cockpit shell (enlarged, clipping children); every display folds in as a chrome-less child pane in the pod interior arrangement: [ MFD UL ] [ MFD UC ] [ MFD UR ] [ plasma (reduced) ][ viewscreen (centered) ] [ MFD LL ] [ Map ] [ MFD LR ] The 3D scene presents into a black STATIC viewscreen child via Present's hDestWindowOverride (new gMainPresentWindow global) - no swap-chain changes, and STATIC's transparent hit-testing keeps mouse input over the 3D view flowing to the game window. MFDSplitView gains a parent/child mode; PlasmaScreen::Position reparents the glass into the shell. Main window class background goes black for the cockpit gaps. Verified by screenshot: live green gauges (LIFT CUT / BOOST / CHUTE / trigger-program screens) with their red button strips, the 3D canyon in the centered viewscreen, plasma score glass at its left, map with lit amber preset lamps - one window, 976x1132 client at 50% scale. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -27,6 +27,10 @@ using namespace std;
|
||||
|
||||
LPDIRECT3D9 gD3D = NULL;
|
||||
|
||||
// Single-window cockpit: viewscreen child window the scene presents into
|
||||
// (NULL = present to the device window as always).
|
||||
HWND gMainPresentWindow = NULL;
|
||||
|
||||
//STUBBED: DPL RB 1/14/07
|
||||
// when this is resolved it can be removed
|
||||
#include "..\DPLSTUB.h"
|
||||
@@ -6152,7 +6156,7 @@ void DPLRenderer::ExecuteImplementation(RendererComplexity, RendererOrigin::Inte
|
||||
|
||||
hr = mDevice->EndScene();
|
||||
|
||||
hr = mDevice->Present(NULL, NULL, NULL, NULL);
|
||||
hr = mDevice->Present(NULL, NULL, gMainPresentWindow, NULL);
|
||||
if (hr == D3DERR_DEVICELOST)
|
||||
{
|
||||
int bbCount = mPresentParams.BackBufferCount;
|
||||
@@ -6187,7 +6191,7 @@ void DPLRenderer::ExecuteIdle()
|
||||
|
||||
hr = mDevice->EndScene();
|
||||
|
||||
if (mDevice->Present(NULL, NULL, NULL, NULL) == D3DERR_DEVICELOST)
|
||||
if (mDevice->Present(NULL, NULL, gMainPresentWindow, NULL) == D3DERR_DEVICELOST)
|
||||
{
|
||||
int bbCount = mPresentParams.BackBufferCount;
|
||||
int bbWidth = mPresentParams.BackBufferWidth;
|
||||
|
||||
Reference in New Issue
Block a user