From c1f04f9135edca994cdc3adea4675be7fe36bd18 Mon Sep 17 00:00:00 2001
From: PiotrMrozik <piter012@vp.pl>
Date: Mon, 16 Dec 2024 13:36:42 +0100
Subject: [PATCH] fix naming conflict

---
 src/gpu/optixPrograms.cu            | 2 --
 test/src/scene/reflectivityTest.cpp | 4 ++--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/src/gpu/optixPrograms.cu b/src/gpu/optixPrograms.cu
index b19e160c..16b3cc95 100644
--- a/src/gpu/optixPrograms.cu
+++ b/src/gpu/optixPrograms.cu
@@ -166,8 +166,6 @@ extern "C" __global__ void __closesthit__()
 	}
 	intensity *= cosIncidentAngle;
 
-	float reflectivityAlpha = ctx.reflectivityAlpha;
-
 	Vec3f absPointVelocity{NAN};
 	Vec3f relPointVelocity{NAN};
 	float radialSpeed{NAN};
diff --git a/test/src/scene/reflectivityTest.cpp b/test/src/scene/reflectivityTest.cpp
index c537fecf..1f6b6eee 100644
--- a/test/src/scene/reflectivityTest.cpp
+++ b/test/src/scene/reflectivityTest.cpp
@@ -81,9 +81,9 @@ TEST_P(ReflectivityTest, read_value)
 
 	for (int i = 0; i < outCount; ++i) {
 		EXPECT_NEAR(((float) value), outIntensity.at(i), EPSILON_F);
-		float outDistance = outDistance.at(i);
+		float outDistanceValue = outDistance.at(i);
 		float intensity = outIntensity.at(i);
-		float reflectivityValue = alpha * outDistance * outDistance * intensity;
+		float reflectivityValue = alpha * outDistanceValue * outDistanceValue * intensity;
 
 		// Reflectivity test is conducted with greater epsilon.
 		// This is due to lack of distance impact on intensity.