NES PPU - palette viewer works

This commit is contained in:
andres.delikat 2011-03-08 21:17:31 +00:00
parent 5f130aabd9
commit def79375dd
2 changed files with 6 additions and 3 deletions

View File

@ -49,7 +49,7 @@ namespace BizHawk.MultiClient
if (!this.IsHandleCreated || this.IsDisposed) return;
for (int x = 0; x < 16; x++)
{
PaletteView.bgPalettes[x].SetValue(Nes.ppu.PALRAM[PaletteView.bgPalettes[x].address]);
PaletteView.bgPalettes[x].SetValue(Nes.ConvertColor(Nes.ppu.PALRAM[PaletteView.bgPalettes[x].address]));
PaletteView.spritePalettes[x].SetValue(Nes.ppu.PALRAM[PaletteView.spritePalettes[x].address]);
}
PaletteView.Refresh();

View File

@ -29,8 +29,11 @@ namespace BizHawk.MultiClient
public void SetValue(int val)
{
value = val;
color = Color.FromArgb(val);
unchecked
{
value = val | (int)0xFF000000;
}
color = Color.FromArgb(value);
}
public Color GetColor()