mirror of
https://github.com/isledecomp/isle.git
synced 2026-01-21 07:11:16 +00:00
Implement ApplySystemEntriesToPalette except the memcpy calls
This commit is contained in:
parent
927fcd7cf1
commit
5c0883e0d5
@ -17,6 +17,24 @@ MxPalette::~MxPalette()
|
||||
}
|
||||
}
|
||||
|
||||
// OFFSET: LEGO1 0x100bf390
|
||||
void MxPalette::ApplySystemEntriesToPalette(LPPALETTEENTRY p_entries)
|
||||
{
|
||||
// FIXME: incomplete
|
||||
HDC hdc = GetDC(NULL);
|
||||
unsigned int rastercaps = GetDeviceCaps(hdc, RASTERCAPS);
|
||||
int sizepalettecaps;
|
||||
if ((rastercaps & RC_PALETTE) != 0) {
|
||||
sizepalettecaps = GetDeviceCaps(hdc, SIZEPALETTE);
|
||||
if(sizepalettecaps = 256) {
|
||||
GetSystemPaletteEntries(hdc,0,10,p_entries);
|
||||
GetSystemPaletteEntries(hdc,246,10,p_entries + 0xf6);
|
||||
ReleaseDC(NULL, hdc);
|
||||
}
|
||||
}
|
||||
// FIXME: we get g_defaultPalette here, we need to define that, then we cna do the memcpy's
|
||||
}
|
||||
|
||||
// OFFSET: LEGO1 100bf0b0
|
||||
MxPalette* MxPalette::Clone()
|
||||
{
|
||||
|
||||
@ -17,6 +17,7 @@ class MxPalette : public MxCore
|
||||
MxPalette();
|
||||
virtual ~MxPalette();
|
||||
|
||||
void ApplySystemEntriesToPalette(LPPALETTEENTRY p_entries);
|
||||
MxPalette* Clone();
|
||||
void GetDefaultPalette(LPPALETTEENTRY p_entries);
|
||||
MxResult GetEntries(LPPALETTEENTRY p_entries);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user