diff options
author | notaz | 2011-12-04 23:33:50 +0200 |
---|---|---|
committer | notaz | 2011-12-05 01:08:25 +0200 |
commit | ddbaf678c49d33cf60f1eac5069e3275baa2c685 (patch) | |
tree | 6ed9f1a9d0dd5673baabf909cb6338fb1941c104 /libpcsxcore/gpu.h | |
parent | adb4b2c6fff620ecd65e3786a2f961413507c1a4 (diff) | |
download | pcsx_rearmed-ddbaf678c49d33cf60f1eac5069e3275baa2c685.tar.gz pcsx_rearmed-ddbaf678c49d33cf60f1eac5069e3275baa2c685.tar.bz2 pcsx_rearmed-ddbaf678c49d33cf60f1eac5069e3275baa2c685.zip |
move some gpu status handling to core
this removes need to update each gpu plugin when this stuff is changed
Diffstat (limited to 'libpcsxcore/gpu.h')
-rw-r--r-- | libpcsxcore/gpu.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/libpcsxcore/gpu.h b/libpcsxcore/gpu.h new file mode 100644 index 0000000..d02dca4 --- /dev/null +++ b/libpcsxcore/gpu.h @@ -0,0 +1,20 @@ + +/* + * q: Why bother with GPU stuff in a plugin-based emu core? + * a: mostly because of busy bits, we have all the needed timing info + * that GPU plugin doesn't. + */ + +#define PSXGPU_LCF (1<<31) +#define PSXGPU_nBUSY (1<<26) +#define PSXGPU_ILACE (1<<22) + +#define HW_GPU_STATUS psxHu32ref(0x1814) + +// TODO: handle com too +#define PSXGPU_TIMING_BITS (PSXGPU_LCF | PSXGPU_nBUSY) + +#define gpuSyncPluginSR() { \ + HW_GPU_STATUS &= PSXGPU_TIMING_BITS; \ + HW_GPU_STATUS |= GPU_readStatus() & ~PSXGPU_TIMING_BITS; \ +} |