diff --git a/include/viennaray/rayTraceKernel.hpp b/include/viennaray/rayTraceKernel.hpp index 2b00a76..0515724 100644 --- a/include/viennaray/rayTraceKernel.hpp +++ b/include/viennaray/rayTraceKernel.hpp @@ -176,8 +176,12 @@ template class rayTraceKernel { const auto &ray = rayHit.ray; std::array origin = { - ray.org_x + ray.dir_x * rndm, ray.org_y + ray.dir_y * rndm, - ray.org_z + ray.dir_z * rndm}; + static_cast(ray.org_x + + ray.dir_x * rndm), + static_cast(ray.org_y + + ray.dir_y * rndm), + static_cast(ray.org_z + + ray.dir_z * rndm)}; std::array direction{0, 0, 0}; for (int i = 0; i < D; ++i) { diff --git a/include/viennaray/rayUtil.hpp b/include/viennaray/rayUtil.hpp index 176db60..f1b0713 100644 --- a/include/viennaray/rayUtil.hpp +++ b/include/viennaray/rayUtil.hpp @@ -81,8 +81,8 @@ namespace rayInternal { using rtcNumericType = float; template -constexpr double DiskFactor = 0.5 * (D == 3 ? 1.7320508 : 1.41421356237) * - (1 + 1e-5); +constexpr double DiskFactor = + 0.5 * (D == 3 ? 1.7320508 : 1.41421356237) * (1 + 1e-5); /* ------------- Vector operation functions ------------- */ template