mirror of https://github.com/mgba-emu/mgba.git
DS Video: Fix size of VRAM zeroes buffer and const correctness
This commit is contained in:
parent
e6fd4f5e7a
commit
4fd170ac38
1
CHANGES
1
CHANGES
|
@ -20,6 +20,7 @@ Bugfixes:
|
|||
- DS Video: Properly deinitialize
|
||||
- DS GX: Mask off invalid bits of the palette base
|
||||
- DS: Properly close save file on close
|
||||
- DS Video: Fix size of VRAM zeroes buffer
|
||||
Misc:
|
||||
- DS GX: Clean up and unify texture mapping
|
||||
- DS Core: Add symbol loading
|
||||
|
|
|
@ -145,8 +145,8 @@ struct DSGXRenderer {
|
|||
void (*getScanline)(struct DSGXRenderer* renderer, int y, const color_t** output);
|
||||
void (*writeRegister)(struct DSGXRenderer* renderer, uint32_t address, uint16_t value);
|
||||
|
||||
uint16_t* tex[4];
|
||||
uint16_t* texPal[6];
|
||||
const uint16_t* tex[4];
|
||||
const uint16_t* texPal[6];
|
||||
|
||||
uint16_t* toonTable;
|
||||
};
|
||||
|
@ -187,8 +187,8 @@ struct DSGX {
|
|||
int pendingVertexIds[8];
|
||||
bool reverseWinding;
|
||||
|
||||
uint16_t* tex[4];
|
||||
uint16_t* texPal[6];
|
||||
const uint16_t* tex[4];
|
||||
const uint16_t* texPal[6];
|
||||
|
||||
int mtxMode;
|
||||
int pvMatrixPointer;
|
||||
|
|
|
@ -20,8 +20,8 @@ struct DSGXSoftwarePolygon {
|
|||
unsigned polyId;
|
||||
DSGXPolygonAttrs polyParams;
|
||||
DSGXTexParams texParams;
|
||||
uint16_t* texBase;
|
||||
uint16_t* palBase;
|
||||
const uint16_t* texBase;
|
||||
const uint16_t* palBase;
|
||||
int texFormat;
|
||||
int blendFormat;
|
||||
int texW;
|
||||
|
|
|
@ -104,13 +104,13 @@ struct DSVideoRenderer {
|
|||
|
||||
uint16_t* palette;
|
||||
uint16_t* vram;
|
||||
uint16_t* vramABG[32];
|
||||
uint16_t* vramAOBJ[32];
|
||||
uint16_t* vramABGExtPal[4];
|
||||
const uint16_t* vramABG[32];
|
||||
const uint16_t* vramAOBJ[32];
|
||||
const uint16_t* vramABGExtPal[4];
|
||||
uint16_t* vramAOBJExtPal;
|
||||
uint16_t* vramBBG[32];
|
||||
uint16_t* vramBOBJ[32];
|
||||
uint16_t* vramBBGExtPal[4];
|
||||
const uint16_t* vramBBG[32];
|
||||
const uint16_t* vramBOBJ[32];
|
||||
const uint16_t* vramBBGExtPal[4];
|
||||
uint16_t* vramBOBJExtPal;
|
||||
|
||||
bool disableABG[4];
|
||||
|
@ -134,12 +134,12 @@ struct DSVideo {
|
|||
|
||||
uint16_t palette[1024];
|
||||
uint16_t* vram;
|
||||
uint16_t* vramABG[32];
|
||||
uint16_t* vramAOBJ[32];
|
||||
const uint16_t* vramABG[32];
|
||||
const uint16_t* vramAOBJ[32];
|
||||
uint16_t* vramABGExtPal[4];
|
||||
uint16_t* vramAOBJExtPal;
|
||||
uint16_t* vramBBG[32];
|
||||
uint16_t* vramBOBJ[32];
|
||||
const uint16_t* vramBBG[32];
|
||||
const uint16_t* vramBOBJ[32];
|
||||
uint16_t* vramBBGExtPal[4];
|
||||
uint16_t* vramBOBJExtPal;
|
||||
union DSOAM oam;
|
||||
|
|
|
@ -45,7 +45,7 @@ static const uint32_t _vramSize[9] = {
|
|||
0x04000
|
||||
};
|
||||
|
||||
static uint16_t _zeroes[0x2000] = {0};
|
||||
static const uint16_t _zeroes[0x10000] = {0};
|
||||
|
||||
enum DSVRAMBankMode {
|
||||
MODE_A_BG = 0,
|
||||
|
|
Loading…
Reference in New Issue