aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTakamichi Horikawa <takamichiho@gmail.com>2017-12-02 14:42:47 +0900
committerTakamichi Horikawa <takamichiho@gmail.com>2017-12-02 14:42:47 +0900
commit00f1d8d6cacf48139b976f3a25c040d51e1abe74 (patch)
tree92462ead9fa0483e885f361adf7ed4e72217f219
parente3026d0792b4ff154cc6a53bfb8120ede6bf6197 (diff)
updated sdl
-rw-r--r--sdl/main.c8
-rw-r--r--sdl/unix/Makefile1
-rw-r--r--sdl/win/Makefile11
3 files changed, 14 insertions, 6 deletions
diff --git a/sdl/main.c b/sdl/main.c
index f4bd752..4000e26 100644
--- a/sdl/main.c
+++ b/sdl/main.c
@@ -152,13 +152,17 @@ int main(int argc, char **argv) {
SDL_Quit();
return 1;
}
-
- g.fp = fmdsp_pacc_init(pc, &pacc);
+ g.fp = fmdsp_pacc_alloc();
if (!g.fp) {
SDL_Log("Cannot initialize fmdsp\n");
SDL_Quit();
return 1;
}
+ if (!fmdsp_pacc_init(g.fp, pc, &pacc)) {
+ SDL_Log("Cannot initialize fmdsp\n");
+ SDL_Quit();
+ return 1;
+ }
fmdsp_pacc_set(g.fp, &g.work, &g.opna, &g.fftin);
fmplayer_font_rom_load(&g.font16);
fmdsp_pacc_set_font16(g.fp, &g.font16);
diff --git a/sdl/unix/Makefile b/sdl/unix/Makefile
index 274f40d..601dd41 100644
--- a/sdl/unix/Makefile
+++ b/sdl/unix/Makefile
@@ -16,6 +16,7 @@ OBJS+=fft.o
TARGET:=fmplayersdl
CFLAGS:=-Wall -Wextra -O2 -g
+CFLAGS+=-DLIBOPNA_ENABLE_LEVELDATA
CFLAGS+=-DPACC_GL_3
#CFLAGS+=-DPACC_GL_ES
#CFLAGS+=-DPACC_GL_ES -DPACC_GL_3
diff --git a/sdl/win/Makefile b/sdl/win/Makefile
index 0f63d19..74ddf0e 100644
--- a/sdl/win/Makefile
+++ b/sdl/win/Makefile
@@ -5,18 +5,21 @@ vpath %.c ../../libopna
vpath %.c ../../common
vpath %.c ../../fmdriver
vpath %.c ../../fft
-SDLCONFIG:=i686-w64-mingw32-sdl2-config
-CC:=i686-w64-mingw32-gcc
+#ARCH=x86_64
+ARCH=i686
+SDLCONFIG:=$(ARCH)-w64-mingw32-sdl2-config
+CC:=$(ARCH)-w64-mingw32-gcc
OBJS:=main.o
OBJS+=pacc-gl.o
-OBJS+=fmdsp-pacc.o font_fmdsp_small.o fmdsp_platform_win.o
+OBJS+=fmdsp-pacc.o font_fmdsp_small.o fmdsp_platform_win.o font_rom.o
OBJS+=opna.o opnafm.o opnassg.o opnadrum.o opnaadpcm.o opnatimer.o opnassg-sinc-c.o opnassg-sinc-sse2.o
OBJS+=fmdriver_pmd.o fmdriver_fmp.o ppz8.o fmdriver_common.o
-OBJS+=fmplayer_file.o fmplayer_work_opna.o fmplayer_file_win.o fmplayer_drumrom_win.o
+OBJS+=fmplayer_file.o fmplayer_work_opna.o fmplayer_file_win.o fmplayer_drumrom_win.o fmplayer_fontrom_win.o winfont.o
OBJS+=fft.o
TARGET:=fmplayersdl.exe
CFLAGS:=-Wall -Wextra -O2
+CFLAGS+=-DLIBOPNA_ENABLE_LEVELDATA
CFLAGS+=-DFMPLAYER_FILE_WIN_UTF8
CFLAGS+=-DPACC_GL_3
#CFLAGS+=-DPACC_GL_ES