Commit 13f73b32 authored by Matt Pharr's avatar Matt Pharr

Fix PBRT_FLOAT_AS_DOUBLE build error in ptex code.

Issue #151.
parent 77bde84f
......@@ -126,8 +126,10 @@ template <>
inline Spectrum fromResult<Spectrum>(int nc, float *result) {
if (nc == 1)
return Spectrum(result[0]);
else
return Spectrum::FromRGB(result);
else {
Float rgb[3] = { result[0], result[1], result[2] };
return Spectrum::FromRGB(rgb);
}
}
template <typename T>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment