mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2026-04-22 01:52:43 +00:00
Make lightmapped graphics ignore lighting engine (#1025)
The dynamic lighting engine conflicted with lightmapped graphics. Now lightmapped graphics will ignore the lighting engine. Making them work together is something for the future. Co-authored-by: MysterD <myster@d>
This commit is contained in:
parent
a164caa412
commit
a3bfd4a740
1 changed files with 2 additions and 2 deletions
|
|
@ -730,7 +730,7 @@ static void OPTIMIZE_O3 gfx_sp_vertex(size_t n_vertices, size_t dest_index, cons
|
|||
|
||||
Vec3f globalLightCached[2];
|
||||
Vec3f vertexColorCached;
|
||||
if (rsp.geometry_mode & G_LIGHTING) {
|
||||
if ((rsp.geometry_mode & G_LIGHTING) && !(rsp.geometry_mode & G_LIGHT_MAP_EXT)) {
|
||||
for (int i = 0; i < 2; i++) {
|
||||
for (int j = 0; j < 3; j++)
|
||||
globalLightCached[i][j] = gLightingColor[i][j] / 255.0f;
|
||||
|
|
@ -911,7 +911,7 @@ static void OPTIMIZE_O3 gfx_sp_vertex(size_t n_vertices, size_t dest_index, cons
|
|||
d->color.b *= color[2] / 255.0f;
|
||||
}
|
||||
// if lighting engine is enabled and we should affect all vertex colored surfaces or the lighting engine geometry mode is on
|
||||
} else if (le_is_enabled() && (affectAllVertexColored || (rsp.geometry_mode & G_LIGHTING_ENGINE_EXT))) {
|
||||
} else if (le_is_enabled() && !(rsp.geometry_mode & G_LIGHT_MAP_EXT) && (affectAllVertexColored || (rsp.geometry_mode & G_LIGHTING_ENGINE_EXT))) {
|
||||
Color color = { gLEAmbientColor[0], gLEAmbientColor[1], gLEAmbientColor[2] };
|
||||
CTX_BEGIN(CTX_LIGHTING);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue