s_glBlendSource
global · gx
- Address
0x85c1f8· 44 bytes, up to0x85c223- Type
uint32_t[11]- Meaning
- Holds the OpenGL source blend factor of each blend mode 0 to 10
- Confidence
- verified, proof one
- Finding
- gx/renderstate#blend-alpha-and-depth-tables
Finding: Blend, alpha and depth tables in gx: render state
Id 7 with mode 0 or 1 disables blending; modes 2 to 10 enable it with source and destination factors. Direct3D uses D3DBLEND tables 0x80a1fc (2, 2, 5, 5, 9, 9, 9, 6, 6, 5, 2) and 0x80a228 (1, 1, 6, 2, 1, 3, 2, 2, 1, 1, 2); OpenGL the enum tables 0x85c1f8 and 0x85c224. Id 8 above 0 sets the alpha test with reference ref (Direct3D ALPHAREF = ref, test always GREATEREQUAL; OpenGL glAlphaFunc(GL_GEQUAL, ref / 255)), and 0 or less turns it off. Id 17 picks the depth function from 0x80a298 (4, 3, 7, 2: lessequal, equal, greaterequal, less) or 0x85c364 (LEQUAL, EQUAL, GEQUAL, LESS).
The derivation is in the doc.