Implement GroupImpl::Bounds (#1246)

* Implement/match DeviceImpl::HandleActivate

* Implement/match DeviceImpl::HandlePaint

* Implement GroupImpl::Unknown (71.63%)

* Fixes

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
This commit is contained in:
Anonymous Maarten
2024-12-20 19:48:31 +01:00
committed by GitHub
parent bfc6d460a8
commit 581ba0f5ae
4 changed files with 78 additions and 18 deletions

View File

@@ -49,28 +49,23 @@ Result DeviceImpl::SetDither(int dither)
return ResultVal(m_data->SetDither(dither));
}
// Probably wrong, not sure what's going on in this method.
// FUNCTION: LEGO1 0x100a2ce0
void DeviceImpl::InitFromD3DDevice(Device*)
void DeviceImpl::HandleActivate(WORD wParam)
{
// Device argument is intentionally unused.
IDirect3DRMWinDevice* winDevice;
if (ResultVal(m_data->QueryInterface(IID_IDirect3DRMWinDevice, (LPVOID*) &winDevice))) {
m_data->InitFromD3D((LPDIRECT3D) &winDevice, (LPDIRECT3DDEVICE) m_data);
winDevice->HandleActivate(wParam);
winDevice->Release();
}
}
// Really don't know what's going on here. Seems it will call down to Init
// but the decomp suggests it otherwise looks the same as InitFromD3D but Init
// takes widly different parameters.
// FUNCTION: LEGO1 0x100a2d20
void DeviceImpl::InitFromWindowsDevice(Device*)
void DeviceImpl::HandlePaint(HDC p_dc)
{
// Device argument is intentionally unused.
IDirect3DRMWinDevice* winDevice;
if (SUCCEEDED(m_data->QueryInterface(IID_IDirect3DRMWinDevice, (LPVOID*) &winDevice))) {
// m_data->Init(??);
winDevice->HandlePaint(p_dc);
winDevice->Release();
}
}
@@ -80,3 +75,6 @@ Result DeviceImpl::Update()
{
return ResultVal(m_data->Update());
}
// GLOBAL: LEGO1 0x100dd1d0
// IID_IDirect3DRMWinDevice