notaz.gp2x.de
/
picodrive.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
more MAME fixes, some optimization
[picodrive.git]
/
platform
/
gp2x
/
code940
/
940shared.h
diff --git
a/platform/gp2x/code940/940shared.h
b/platform/gp2x/code940/940shared.h
index
c208e67
..
e4105d8
100644
(file)
--- a/
platform/gp2x/code940/940shared.h
+++ b/
platform/gp2x/code940/940shared.h
@@
-1,30
+1,33
@@
#include "../../../Pico/sound/ym2612.h"
\r
#include "../helix/pub/mp3dec.h"
\r
\r
#include "../../../Pico/sound/ym2612.h"
\r
#include "../helix/pub/mp3dec.h"
\r
\r
+// max 16 jobs
\r
enum _940_job_t {
\r
JOB940_INITALL = 1,
\r
enum _940_job_t {
\r
JOB940_INITALL = 1,
\r
+ JOB940_INVALIDATE_DCACHE,
\r
JOB940_YM2612RESETCHIP,
\r
JOB940_YM2612UPDATEONE,
\r
JOB940_YM2612RESETCHIP,
\r
JOB940_YM2612UPDATEONE,
\r
- JOB940_PICOSTATELOAD,
\r
JOB940_MP3DECODE,
\r
JOB940_MP3DECODE,
\r
- JOB940_
NUMJOBS
\r
+ JOB940_
PICOSTATELOAD,
\r
};
\r
\r
};
\r
\r
-
#define MAX_940JOBS
2
\r
+
//#define MAX_940JOBS
2
\r
\r
typedef struct
\r
{
\r
\r
typedef struct
\r
{
\r
- YM2612 ym2612;
/* current state of the emulated YM2612 */
\r
+ YM2612 ym2612; /* current state of the emulated YM2612 */
\r
HMP3Decoder mp3dec; /* mp3 decoder's handle */
\r
HMP3Decoder mp3dec; /* mp3 decoder's handle */
\r
- int
mix_buffer[44100/50*2];
/* this is where the YM2612 samples will be mixed to */
\r
+ int
ym_buffer[44100/50*2];
/* this is where the YM2612 samples will be mixed to */
\r
short mp3_buffer[2][1152*2]; /* buffers for mp3 decoder's output */
\r
} _940_data_t;
\r
\r
\r
typedef struct
\r
{
\r
short mp3_buffer[2][1152*2]; /* buffers for mp3 decoder's output */
\r
} _940_data_t;
\r
\r
\r
typedef struct
\r
{
\r
- int jobs[MAX_940JOBS]; /* jobs for second core */
\r
- int busy_; /* unused */
\r
+ int vstarts[8]; /* debug: 00: number of starts from each of 8 vectors */
\r
+ int last_lr; /* debug: 20: last exception's lr */
\r
+// int jobs[MAX_940JOBS]; /* jobs for second core */
\r
+// int busy_; /* unused */
\r
int length; /* number of samples to mix (882 max) */
\r
int stereo; /* mix samples as stereo, doubles sample count automatically */
\r
int baseclock; /* ym2612 settings */
\r
int length; /* number of samples to mix (882 max) */
\r
int stereo; /* mix samples as stereo, doubles sample count automatically */
\r
int baseclock; /* ym2612 settings */
\r
@@
-32,14
+35,12
@@
typedef struct
int writebuffsel; /* which write buffer to use (from 940 side) */
\r
UINT16 writebuff0[2048]; /* list of writes to ym2612, 1024 for savestates, 1024 extra */
\r
UINT16 writebuff1[2048];
\r
int writebuffsel; /* which write buffer to use (from 940 side) */
\r
UINT16 writebuff0[2048]; /* list of writes to ym2612, 1024 for savestates, 1024 extra */
\r
UINT16 writebuff1[2048];
\r
+ int ym_active_chs;
\r
int mp3_len; /* data len of loaded mp3 */
\r
int mp3_offs; /* current playback offset (just after last decoded frame) */
\r
int mp3_buffsel; /* which output buffer to decode to */
\r
int mp3_len; /* data len of loaded mp3 */
\r
int mp3_offs; /* current playback offset (just after last decoded frame) */
\r
int mp3_buffsel; /* which output buffer to decode to */
\r
- int vstarts[8]; /* debug: number of starts from each of 8 vectors */
\r
- int loopc; /* debug: main loop counter */
\r
+ int loopc; /* debug: main loop counter */
\r
int mp3_errors; /* debug: mp3 decoder's error counter */
\r
int mp3_lasterr; /* debug: mp3 decoder's last error */
\r
int mp3_errors; /* debug: mp3 decoder's error counter */
\r
int mp3_lasterr; /* debug: mp3 decoder's last error */
\r
- int last_irq_pc; /* debug: PC value when IRQ happened */
\r
int lastjob; /* debug: last job id */
\r
int lastjob; /* debug: last job id */
\r
- int lastbusy; /* debug: */
\r
} _940_ctl_t;
\r
} _940_ctl_t;
\r