Some cleanups + we don't need a non-libretro codepath
This commit is contained in:
@@ -101,12 +101,7 @@ void FCEUI_DisableSpriteLimitation(int a);
|
|||||||
/* -1 = no change, 0 = show, 1 = hide, 2 = internal toggle */
|
/* -1 = no change, 0 = show, 1 = hide, 2 = internal toggle */
|
||||||
void FCEUI_SetRenderDisable(int sprites, int bg);
|
void FCEUI_SetRenderDisable(int sprites, int bg);
|
||||||
|
|
||||||
#ifdef __LIBRETRO__
|
|
||||||
FCEUGI *FCEUI_LoadGame(const char *name, uint8_t *buf, size_t bufsize);
|
FCEUGI *FCEUI_LoadGame(const char *name, uint8_t *buf, size_t bufsize);
|
||||||
#else
|
|
||||||
/* name=path and file to load. returns 0 on failure, 1 on success */
|
|
||||||
FCEUGI *FCEUI_LoadGame(const char *name);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef COPYFAMI
|
#ifdef COPYFAMI
|
||||||
/* Fake UNIF board to start new CFHI instance */
|
/* Fake UNIF board to start new CFHI instance */
|
||||||
@@ -149,9 +144,7 @@ void FCEUI_SetRenderedLines(int ntscf, int ntscl, int palf, int pall);
|
|||||||
below this directory. */
|
below this directory. */
|
||||||
void FCEUI_SetBaseDirectory(char *dir);
|
void FCEUI_SetBaseDirectory(char *dir);
|
||||||
|
|
||||||
#ifdef __LIBRETRO__
|
|
||||||
void FCEUI_SetSaveDirectory(char *sav_dir);
|
void FCEUI_SetSaveDirectory(char *sav_dir);
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
/* Tells FCE Ultra to copy the palette data pointed to by pal and use it.
|
/* Tells FCE Ultra to copy the palette data pointed to by pal and use it.
|
||||||
|
|||||||
@@ -188,9 +188,6 @@ static uint32_t Dummy = 0;
|
|||||||
static uint32_t current_palette = 0;
|
static uint32_t current_palette = 0;
|
||||||
static unsigned serialize_size;
|
static unsigned serialize_size;
|
||||||
|
|
||||||
int PPUViewScanline=0;
|
|
||||||
int PPUViewer=0;
|
|
||||||
|
|
||||||
/* extern forward decls.*/
|
/* extern forward decls.*/
|
||||||
extern FCEUGI *GameInfo;
|
extern FCEUGI *GameInfo;
|
||||||
extern uint8 *XBuf;
|
extern uint8 *XBuf;
|
||||||
@@ -201,8 +198,6 @@ extern int option_ramstate;
|
|||||||
|
|
||||||
/* emulator-specific callback functions */
|
/* emulator-specific callback functions */
|
||||||
|
|
||||||
void UpdatePPUView(int refreshchr) { }
|
|
||||||
|
|
||||||
const char * GetKeyboard(void)
|
const char * GetKeyboard(void)
|
||||||
{
|
{
|
||||||
return "";
|
return "";
|
||||||
@@ -288,9 +283,6 @@ void FCEUD_DispMessage(char *m)
|
|||||||
environ_cb(RETRO_ENVIRONMENT_SET_MESSAGE, &msg);
|
environ_cb(RETRO_ENVIRONMENT_SET_MESSAGE, &msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FCEUD_NetworkClose(void)
|
|
||||||
{ }
|
|
||||||
|
|
||||||
void FCEUD_SoundToggle (void)
|
void FCEUD_SoundToggle (void)
|
||||||
{
|
{
|
||||||
FCEUI_SetSoundVolume(sndvolume);
|
FCEUI_SetSoundVolume(sndvolume);
|
||||||
@@ -300,7 +292,6 @@ FILE *FCEUD_UTF8fopen(const char *n, const char *m)
|
|||||||
{
|
{
|
||||||
if (n)
|
if (n)
|
||||||
return fopen(n, m);
|
return fopen(n, m);
|
||||||
else
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -22,11 +22,7 @@
|
|||||||
#ifndef __FCEU_TYPES_H
|
#ifndef __FCEU_TYPES_H
|
||||||
#define __FCEU_TYPES_H
|
#define __FCEU_TYPES_H
|
||||||
|
|
||||||
#ifdef __LIBRETRO__
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#else
|
|
||||||
#include <inttypes.h>
|
|
||||||
#endif
|
|
||||||
typedef int8_t int8;
|
typedef int8_t int8;
|
||||||
typedef int16_t int16;
|
typedef int16_t int16;
|
||||||
typedef int32_t int32;
|
typedef int32_t int32;
|
||||||
|
|||||||
@@ -81,7 +81,6 @@ extern uint8 PAL;
|
|||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
int PAL;
|
int PAL;
|
||||||
int NetworkPlay;
|
|
||||||
int SoundVolume;
|
int SoundVolume;
|
||||||
int TriangleVolume;
|
int TriangleVolume;
|
||||||
int SquareVolume[2];
|
int SquareVolume[2];
|
||||||
|
|||||||
10
src/file.h
10
src/file.h
@@ -1,28 +1,18 @@
|
|||||||
#ifndef _FCEU_FILE_H
|
#ifndef _FCEU_FILE_H
|
||||||
#define _FCEU_FILE_H
|
#define _FCEU_FILE_H
|
||||||
|
|
||||||
#ifdef __LIBRETRO__
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
uint8 *data;
|
uint8 *data;
|
||||||
uint32 size;
|
uint32 size;
|
||||||
uint32 location;
|
uint32 location;
|
||||||
} MEMWRAP;
|
} MEMWRAP;
|
||||||
#endif
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
#ifdef __LIBRETRO__
|
|
||||||
MEMWRAP *fp;
|
MEMWRAP *fp;
|
||||||
#else
|
|
||||||
void *fp; /* FILE* or ptr to ZIPWRAP */
|
|
||||||
#endif
|
|
||||||
uint32 type; /* 0=normal file, 1=gzip, 2=zip */
|
uint32 type; /* 0=normal file, 1=gzip, 2=zip */
|
||||||
} FCEUFILE;
|
} FCEUFILE;
|
||||||
|
|
||||||
#ifdef __LIBRETRO__
|
|
||||||
FCEUFILE *FCEU_fopen(const char *path, const char *ipsfn, char *mode, char *ext, uint8 *buffer, size_t bufsize);
|
FCEUFILE *FCEU_fopen(const char *path, const char *ipsfn, char *mode, char *ext, uint8 *buffer, size_t bufsize);
|
||||||
#else
|
|
||||||
FCEUFILE *FCEU_fopen(const char *path, const char *ipsfn, char *mode, char *ext);
|
|
||||||
#endif
|
|
||||||
int FCEU_fclose(FCEUFILE*);
|
int FCEU_fclose(FCEUFILE*);
|
||||||
uint64 FCEU_fread(void *ptr, size_t size, size_t nmemb, FCEUFILE*);
|
uint64 FCEU_fread(void *ptr, size_t size, size_t nmemb, FCEUFILE*);
|
||||||
uint64 FCEU_fwrite(void *ptr, size_t size, size_t nmemb, FCEUFILE*);
|
uint64 FCEU_fwrite(void *ptr, size_t size, size_t nmemb, FCEUFILE*);
|
||||||
|
|||||||
@@ -32,7 +32,6 @@
|
|||||||
#include "general.h"
|
#include "general.h"
|
||||||
#include "fceu-endian.h"
|
#include "fceu-endian.h"
|
||||||
#include "fceu-memory.h"
|
#include "fceu-memory.h"
|
||||||
#include "ppuview.h"
|
|
||||||
|
|
||||||
#include "cart.h"
|
#include "cart.h"
|
||||||
#include "palette.h"
|
#include "palette.h"
|
||||||
@@ -1241,7 +1240,6 @@ int FCEUPPU_Loop(int skip) {
|
|||||||
|
|
||||||
for (scanline = 0; scanline < totalscanlines; ) { /* scanline is incremented in DoLine. Evil. :/ */
|
for (scanline = 0; scanline < totalscanlines; ) { /* scanline is incremented in DoLine. Evil. :/ */
|
||||||
deempcnt[deemp]++;
|
deempcnt[deemp]++;
|
||||||
/* if ((PPUViewer) && (scanline == PPUViewScanline)) UpdatePPUView(1); */
|
|
||||||
DoLine();
|
DoLine();
|
||||||
if (scanline < normal_scanlines || scanline == totalscanlines)
|
if (scanline < normal_scanlines || scanline == totalscanlines)
|
||||||
overclocked = 0;
|
overclocked = 0;
|
||||||
|
|||||||
@@ -1,13 +0,0 @@
|
|||||||
#ifndef _FCEU_PPUVIEW_H
|
|
||||||
#define _FCEU_PPUVIEW_H
|
|
||||||
|
|
||||||
extern int PPUViewScanline;
|
|
||||||
extern int PPUViewer;
|
|
||||||
extern int scanline;
|
|
||||||
|
|
||||||
void PPUViewDoBlit();
|
|
||||||
void DoPPUView();
|
|
||||||
void UpdatePPUView(int refreshchr);
|
|
||||||
|
|
||||||
|
|
||||||
#endif
|
|
||||||
Reference in New Issue
Block a user