| View previous topic :: View next topic |
| Author |
Message |
rinco
Joined: 21 Jan 2005 Posts: 255 Location: Canberra, Australia
|
Posted: Sun Aug 21, 2005 12:36 pm Post subject: Fullscreen SMS using SDL |
|
|
I can't seem to find the sources for Yoshi's port of SMS.
So I started from scratch.
1. Download http://membres.lycos.fr/cyxdown/smssdl/sms_sdl-0.9.4a-r7.1-src.zip
2. Create Makefile.psp
| Code: |
TARGET = sms
PSPSDK=$(shell psp-config --pspsdk-path)
PSPBIN = $(PSPSDK)/../bin
SDL_CONFIG = $(PSPBIN)/sdl-config
OBJS = main.o saves.o sdlsms.o filters.o \
../render.o ../sms.o ../system.o ../vdp.o \
../cpu/z80.o ../sound/emu2413.o ../sound/sn76496.o
INCDIR =
CFLAGS = -O2 -G0 -Wall $(shell $(SDL_CONFIG) --cflags) \
-I. -I.. -I../cpu -I../sound -DLSB_FIRST -DALIGN_DWORD
CXXFLAGS = $(CFLAGS) -fno-exceptions -fno-rtti -Wpointer-arith
ASFLAGS = $(CFLAGS)
LIBDIR =
LDFLAGS =
LIBS = $(shell $(SDL_CONFIG) --libs)
EXTRA_TARGETS = EBOOT.PBP
PSP_EBOOT_TITLE = SMS/SDL
include $(PSPSDK)/lib/build.mak
|
3. Overcome command line arguments and main=>SDL_main
| Code: |
#ifndef PSP
int main(int argc, char **argv)
{
#else
int SDL_main(int argc, char **dummy_argv)
{
const char *argv[] = { "EBOOT.PBP", "rinco.gg", "--joystick", "--fullscreen", NULL };
argc = 4;
#endif
|
4. build and install (and rename rom to rinco.gg)
So if someone can provide the Yoshi filebrowser, or make SDL_romselector.c... then that would be great. |
|
| Back to top |
|
 |
rinco
Joined: 21 Jan 2005 Posts: 255 Location: Canberra, Australia
|
Posted: Tue Aug 23, 2005 9:02 pm Post subject: |
|
|
to fix the sound, in sdlsms.c ...
| Code: |
static void sdlsms_sound_update()
{
int i;
short* p;
#ifndef PSP
SDL_LockAudio();
#endif
p = (short*)sdl_sound.current_pos;
for(i = 0; i < snd.bufsize; ++i) {
*p = snd.buffer[0][i];
++p;
*p = snd.buffer[1][i];
++p;
}
sdl_sound.current_pos = (char*)p;
sdl_sound.current_emulated_samples += snd.bufsize * 2 * sizeof(short);
#ifndef PSP
SDL_UnlockAudio();
#endif
}
|
|
|
| Back to top |
|
 |
Thanhda

Joined: 09 Apr 2005 Posts: 331 Location: Canada
|
Posted: Wed Aug 24, 2005 6:42 am Post subject: |
|
|
link doesnt work _________________ There are 10 types of people in the world: Those who understand binary, and those who don't... |
|
| Back to top |
|
 |
rinco
Joined: 21 Jan 2005 Posts: 255 Location: Canberra, Australia
|
|
| Back to top |
|
 |
Wraggster
Joined: 26 Aug 2005 Posts: 121
|
Posted: Wed Aug 31, 2005 12:19 pm Post subject: |
|
|
ive let Yoshi know your after the Sources :) _________________ Webmaster of http://www.dcemu.co.uk
DCEMU The Worlds Only Homebrew & Gaming Network of Sites. |
|
| Back to top |
|
 |
|