mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-20 20:49:12 +12:00
[GPU] Surface cache vol 1
This commit is contained in:
parent
57ef4e25e7
commit
ecbb33b906
7 changed files with 276 additions and 0 deletions
|
@ -59,6 +59,31 @@ void GPU::writeInternalReg(u32 index, u32 value, u32 mask) {
|
|||
fixedAttribMask = (value >> 16) & 0xfff; // Determines which vertex attributes are fixed for all vertices
|
||||
break;
|
||||
|
||||
case ColourBufferLoc: {
|
||||
u32 loc = (value & 0x0fffffff) << 3;
|
||||
renderer.setColourBufferLoc(loc);
|
||||
break;
|
||||
};
|
||||
|
||||
case ColourBufferFormat: {
|
||||
u32 format = (value >> 16) & 7;
|
||||
renderer.setColourFormat(format);
|
||||
break;
|
||||
}
|
||||
|
||||
case DepthBufferLoc: {
|
||||
u32 loc = (value & 0x0fffffff) << 3;
|
||||
renderer.setDepthBufferLoc(loc);
|
||||
break;
|
||||
}
|
||||
|
||||
case FramebufferSize: {
|
||||
const u32 width = value & 0x7ff;
|
||||
const u32 height = ((value >> 12) & 0x3ff) + 1;
|
||||
renderer.setFBSize(width, height);
|
||||
break;
|
||||
}
|
||||
|
||||
case VertexFloatUniformIndex:
|
||||
shaderUnit.vs.setFloatUniformIndex(value);
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue