Remove S9xSetPalette

This commit is contained in:
BearOso 2020-08-06 16:26:12 -05:00
parent 793b3f623f
commit e322bbf109
9 changed files with 5 additions and 33 deletions

View File

@ -40,7 +40,6 @@ void S9xInitDisplay (int, char **);
void S9xDeinitDisplay (void); void S9xDeinitDisplay (void);
void S9xTextMode (void); void S9xTextMode (void);
void S9xGraphicsMode (void); void S9xGraphicsMode (void);
void S9xSetPalette (void);
void S9xToggleSoundChannel (int); void S9xToggleSoundChannel (int);
bool8 S9xOpenSnapshotFile (const char *, bool8, STREAM *); bool8 S9xOpenSnapshotFile (const char *, bool8, STREAM *);
void S9xCloseSnapshotFile (STREAM); void S9xCloseSnapshotFile (STREAM);

View File

@ -318,10 +318,6 @@
<p> <p>
If your port can match Snes9x's built-in <code>SoundChannelXXX</code> command (see <code>controls.cpp</code>), you may choose to use this function. Otherwise return <code>NULL</code>. Basically, turn on/off the sound channel <code>c</code> (0-7), and turn on all channels if <code>c</code> is 8. If your port can match Snes9x's built-in <code>SoundChannelXXX</code> command (see <code>controls.cpp</code>), you may choose to use this function. Otherwise return <code>NULL</code>. Basically, turn on/off the sound channel <code>c</code> (0-7), and turn on all channels if <code>c</code> is 8.
</p> </p>
<h3><code>void S9xSetPalette (void)</code></h3>
<p>
Called when the SNES color palette has changed. Use this function if your system needs to change its color palette to match the SNES's. Otherwise, leave it empty.
</p>
<h3><code>void S9xSyncSpeed (void)</code></h3> <h3><code>void S9xSyncSpeed (void)</code></h3>
<p> <p>
Called at the end of <code>S9xMainLoop</code> function, when emulating one frame has been done. You should adjust the frame rate in this function. Called at the end of <code>S9xMainLoop</code> function, when emulating one frame has been done. You should adjust the frame rate in this function.

View File

@ -221,7 +221,6 @@ void S9xEndScreenRefresh (void)
{ {
uint32 saved = PPU.CGDATA[0]; uint32 saved = PPU.CGDATA[0];
IPPU.ColorsChanged = FALSE; IPPU.ColorsChanged = FALSE;
S9xSetPalette();
PPU.CGDATA[0] = saved; PPU.CGDATA[0] = saved;
} }

1
gfx.h
View File

@ -216,7 +216,6 @@ bool8 S9xInitUpdate (void);
bool8 S9xDeinitUpdate (int, int); bool8 S9xDeinitUpdate (int, int);
bool8 S9xContinueUpdate (int, int); bool8 S9xContinueUpdate (int, int);
void S9xReRefresh (void); void S9xReRefresh (void);
void S9xSetPalette (void);
void S9xSyncSpeed (void); void S9xSyncSpeed (void);
// called instead of S9xDisplayString if set to non-NULL // called instead of S9xDisplayString if set to non-NULL

View File

@ -1498,10 +1498,6 @@ bool8 S9xInitUpdate()
return true; return true;
} }
void S9xSetPalette()
{
}
void S9xTextMode() void S9xTextMode()
{ {
} }

View File

@ -607,10 +607,10 @@ static void update_variables(void)
var.key = "snes9x_echo_buffer_hack"; var.key = "snes9x_echo_buffer_hack";
var.value = NULL; var.value = NULL;
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var)) if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var))
Settings.SeparateEchoBuffer = !strcmp(var.value, "disabled") ? false : true; Settings.SeparateEchoBuffer = !strcmp(var.value, "disabled") ? false : true;
else else
Settings.SeparateEchoBuffer = false; Settings.SeparateEchoBuffer = false;
var.key = "snes9x_blargg"; var.key = "snes9x_blargg";
@ -1133,7 +1133,7 @@ bool retro_load_game(const struct retro_game_info *game)
if (rom_loaded) if (rom_loaded)
{ {
/* If we're in RGB565 format, switch frontend to that */ /* If we're in RGB565 format, switch frontend to that */
if (RED_SHIFT_BITS == 11) if (RED_SHIFT_BITS == 11)
{ {
enum retro_pixel_format fmt = RETRO_PIXEL_FORMAT_RGB565; enum retro_pixel_format fmt = RETRO_PIXEL_FORMAT_RGB565;
if (!environ_cb || !environ_cb(RETRO_ENVIRONMENT_SET_PIXEL_FORMAT, &fmt)) if (!environ_cb || !environ_cb(RETRO_ENVIRONMENT_SET_PIXEL_FORMAT, &fmt))
@ -2135,7 +2135,6 @@ bool8 S9xInitUpdate() { return TRUE; }
void S9xExtraUsage() {} void S9xExtraUsage() {}
bool8 S9xOpenSoundDevice() { return TRUE; } bool8 S9xOpenSoundDevice() { return TRUE; }
bool S9xPollAxis(unsigned int, short*) { return FALSE; } bool S9xPollAxis(unsigned int, short*) { return FALSE; }
void S9xSetPalette() {}
void S9xParseArg(char**, int&, int) {} void S9xParseArg(char**, int&, int) {}
void S9xExit() {} void S9xExit() {}
bool S9xPollPointer(unsigned int, short*, short*) { return false; } bool S9xPollPointer(unsigned int, short*, short*) { return false; }

View File

@ -408,9 +408,4 @@ void S9xTextMode (void)
void S9xGraphicsMode (void) void S9xGraphicsMode (void)
{ {
return; return;
} }
void S9xSetPalette (void)
{
return;
}

View File

@ -1793,9 +1793,4 @@ bool S9xDisplayPollPointer (uint32 id, int16 *x, int16 *y)
*y = GUI.mouse_y; *y = GUI.mouse_y;
return (true); return (true);
} }
void S9xSetPalette (void)
{
return;
}

View File

@ -211,12 +211,6 @@ RECT CalculateDisplayRect(unsigned int sourceWidth,unsigned int sourceHeight,
return drawRect; return drawRect;
} }
// we no longer support 8bit modes - no palette necessary
void S9xSetPalette( void)
{
return;
}
bool8 S9xInitUpdate (void) bool8 S9xInitUpdate (void)
{ {
return (TRUE); return (TRUE);