Support PS3 by default
This commit is contained in:
@@ -66,10 +66,10 @@ namespace JabyEngine {
|
||||
}
|
||||
|
||||
namespace DMA {
|
||||
#ifdef SUPPORT_PS3
|
||||
#ifdef __SUPPORT_PS3__
|
||||
// The PS3 doesn't autoincrement the GPU MADR register so we have to do it
|
||||
extern uintptr_t MADR;
|
||||
#endif // SUPPORT_PS3
|
||||
#endif // __SUPPORT_PS3__
|
||||
|
||||
static void wait() {
|
||||
::JabyEngine::DMA_IO::GPU.wait();
|
||||
@@ -86,11 +86,11 @@ namespace JabyEngine {
|
||||
}
|
||||
|
||||
static void set_src(uintptr_t adr) {
|
||||
#ifdef SUPPORT_PS3
|
||||
#ifdef __SUPPORT_PS3__
|
||||
MADR = adr;
|
||||
#else
|
||||
DMA_IO::GPU.set_adr(adr);
|
||||
#endif // SUPPORT_PS3
|
||||
#endif // __SUPPORT_PS3__
|
||||
}
|
||||
|
||||
static void set_dst(const PositionU16& position, const SizeU16& size) {
|
||||
@@ -103,10 +103,10 @@ namespace JabyEngine {
|
||||
static void start(uint16_t blockCount, uint16_t wordsPerBlock = 0x10) {
|
||||
typedef DMA_IO::BCR::SyncMode1 SyncMode1;
|
||||
|
||||
#ifdef SUPPORT_PS3
|
||||
#ifdef __SUPPORT_PS3__
|
||||
DMA_IO::GPU.set_adr(MADR);
|
||||
MADR += (blockCount * wordsPerBlock) << 2;
|
||||
#endif // SUPPORT_PS3
|
||||
#endif // __SUPPORT_PS3__
|
||||
DMA_IO::GPU.block_ctrl.write(DMA_IO::BCR::from(SyncMode1::BlockSize.with(wordsPerBlock), SyncMode1::BlockAmount.with(blockCount)));
|
||||
DMA_IO::GPU.channel_ctrl.write(DMA_IO::CHCHR::StartGPUReceive());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user