diff --git a/Core/FileFormats/RagnarokRSW.lua b/Core/FileFormats/RagnarokRSW.lua index 5eeb9c21..77f9f8c7 100644 --- a/Core/FileFormats/RagnarokRSW.lua +++ b/Core/FileFormats/RagnarokRSW.lua @@ -236,19 +236,8 @@ function RagnarokRSW:DecodeEnvironmentalLightSources() }, } - -- Composite blending (additive + multiplicative components) ~> scenewide color tint - local contrastCorrectionColor = { - red = (directionalLight.diffuseColor.red + ambientLight.diffuseColor.red) - - directionalLight.diffuseColor.red * ambientLight.diffuseColor.red, - green = (directionalLight.diffuseColor.green + ambientLight.diffuseColor.green) - - directionalLight.diffuseColor.green * ambientLight.diffuseColor.green, - blue = (directionalLight.diffuseColor.blue + ambientLight.diffuseColor.blue) - - directionalLight.diffuseColor.blue * ambientLight.diffuseColor.blue, - } - self.directionalLight = directionalLight self.ambientLight = ambientLight - self.contrastCorrectionColor = contrastCorrectionColor self.prebakedShadowmapAlpha = tonumber(environmentalLightInfo.shadowmap_alpha) end diff --git a/Tests/FileFormats/RagnarokRSW.spec.lua b/Tests/FileFormats/RagnarokRSW.spec.lua index 4bae5ac5..38efc0b5 100644 --- a/Tests/FileFormats/RagnarokRSW.spec.lua +++ b/Tests/FileFormats/RagnarokRSW.spec.lua @@ -49,10 +49,6 @@ describe("RagnarokRSW", function() assertEqualNumbers(rsw.ambientLight.diffuseColor.blue, 0.35, 1E-3) assertEquals(rsw.prebakedShadowmapAlpha, 0.5) - assertEqualNumbers(rsw.contrastCorrectionColor.red, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.green, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.blue, 0.5775, 1E-3) - assertEquals(rsw.boundingBox.top, 12) assertEquals(rsw.boundingBox.bottom, 777) assertEquals(rsw.boundingBox.left, 512) @@ -200,10 +196,6 @@ describe("RagnarokRSW", function() assertEqualNumbers(rsw.ambientLight.diffuseColor.blue, 0.35, 1E-3) assertEquals(rsw.prebakedShadowmapAlpha, 0.5) - assertEqualNumbers(rsw.contrastCorrectionColor.red, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.green, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.blue, 0.5775, 1E-3) - assertEquals(rsw.boundingBox.top, 12) assertEquals(rsw.boundingBox.bottom, 777) assertEquals(rsw.boundingBox.left, 512) @@ -351,10 +343,6 @@ describe("RagnarokRSW", function() assertEqualNumbers(rsw.ambientLight.diffuseColor.blue, 0.35, 1E-3) assertEquals(rsw.prebakedShadowmapAlpha, 0.5) - assertEqualNumbers(rsw.contrastCorrectionColor.red, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.green, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.blue, 0.5775, 1E-3) - assertEquals(rsw.boundingBox.top, 12) assertEquals(rsw.boundingBox.bottom, 777) assertEquals(rsw.boundingBox.left, 512) @@ -502,10 +490,6 @@ describe("RagnarokRSW", function() assertEqualNumbers(rsw.ambientLight.diffuseColor.blue, 0.35, 1E-3) assertEquals(rsw.prebakedShadowmapAlpha, 0.5) - assertEqualNumbers(rsw.contrastCorrectionColor.red, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.green, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.blue, 0.5775, 1E-3) - assertEquals(rsw.boundingBox.top, 12) assertEquals(rsw.boundingBox.bottom, 777) assertEquals(rsw.boundingBox.left, 512) @@ -645,10 +629,6 @@ describe("RagnarokRSW", function() assertEqualNumbers(rsw.ambientLight.diffuseColor.blue, 0.35, 1E-3) assertEqualNumbers(rsw.prebakedShadowmapAlpha, 0.5, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.red, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.green, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.blue, 0.5775, 1E-3) - assertEquals(rsw.boundingBox.top, 12) assertEquals(rsw.boundingBox.bottom, 777) assertEquals(rsw.boundingBox.left, 512) @@ -788,10 +768,6 @@ describe("RagnarokRSW", function() assertEqualNumbers(rsw.ambientLight.diffuseColor.blue, 0.35, 1E-3) assertEqualNumbers(rsw.prebakedShadowmapAlpha, 0.5, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.red, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.green, 0.5775, 1E-3) - assertEqualNumbers(rsw.contrastCorrectionColor.blue, 0.5775, 1E-3) - assertEquals(rsw.boundingBox.top, 12) assertEquals(rsw.boundingBox.bottom, 777) assertEquals(rsw.boundingBox.left, 512) diff --git a/Tools/rsw-to-json.lua b/Tools/rsw-to-json.lua index 8f36e3be..e417d864 100644 --- a/Tools/rsw-to-json.lua +++ b/Tools/rsw-to-json.lua @@ -25,7 +25,6 @@ local sceneObjects = { buildNumber = rsw.buildNumber, directionalLight = rsw.directionalLight, ambientLight = rsw.ambientLight, - contrastCorrectionColor = rsw.contrastCorrectionColor, prebakedShadowmapAlpha = rsw.prebakedShadowmapAlpha, animatedProps = rsw.animatedProps, spatialAudioSources = rsw.spatialAudioSources,