Commit 8fa49b14 authored by Matt Pharr's avatar Matt Pharr

Fix typo in 525a3ee6

Fixes #134, #135, and #136.
parent f5da1aea
......@@ -452,7 +452,7 @@ Float RealisticCamera::FocusThickLens(Float focusDistance) {
// Compute translation of lens, _delta_, to focus at _focusDistance_
Float f = fz[0] - pz[0];
Float z = -focusDistance;
Float c = (pz[1] - z - pz[0]) * (pz[1] - z * 4 * f - pz[0]);
Float c = (pz[1] - z - pz[0]) * (pz[1] - z - 4 * f - pz[0]);
CHECK_GT(c, 0) << "Coefficient must be positive. It looks focusDistance: " << focusDistance << " is too short for a given lenses configuration";
Float delta =
0.5f * (pz[1] - z + pz[0] - std::sqrt(c));
......
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