0
$\begingroup$

Suppose we are sampling camera rays of a perspective camera with a finite aperture. The PBRT implementation of the sampling scheme looks like this:

Float PerspectiveCamera::GenerateRay(const CameraSample &sample,
                                     Ray *ray) const {
    ProfilePhase prof(Prof::GenerateCameraRay);
    // Compute raster and camera sample positions
    Point3f pFilm = Point3f(sample.pFilm.x, sample.pFilm.y, 0);
    Point3f pCamera = RasterToCamera(pFilm);
    *ray = Ray(Point3f(0, 0, 0), Normalize(Vector3f(pCamera)));
    // Modify ray for depth of field
    if (lensRadius > 0) {
        // Sample point on lens
        Point2f pLens = lensRadius * ConcentricSampleDisk(sample.pLens);

        // Compute point on plane of focus
        Float ft = focalDistance / ray->d.z;
        Point3f pFocus = (*ray)(ft);

        // Update ray for effect of lens
        ray->o = Point3f(pLens.x, pLens.y, 0);
        ray->d = Normalize(pFocus - ray->o);
    }
    ray->time = Lerp(sample.time, shutterOpen, shutterClose);
    ray->medium = medium;
    *ray = CameraToWorld(*ray);
    return 1;
}

Let $X_0\in M$ and $\Omega_1\in S^2$ denote the sampled point on the camera and direction, respectively. The next surface point in a path tracer would be $$Y:=X+d_M(X,\Omega)\Omega,$$ where $$d_M(x,\omega):=\inf\left\{t>0:x+t\omega\in M\right\}\;\;\;\text{for }x\in M\text{ and }\omega\in S^2.$$ What is the conditional distribution of $Y$ given $(X,\Omega)$?

From page 303 in Veach's thesis the conditional distribution of $Y$ given $X$ should have a density with respect to the projected solid angle kernel $$\sigma_M^\perp(x,B):=\int_B\sigma_{S^2}({\rm d}\omega)|\langle\nu_M(x),\omega\rangle|\;\;\;\text{for }(x,B)\in M\times\mathcal B(S^2).$$

Formally, we assume that the lens is part of our scene geometry $M$, which is assumed to be an oriented embedded $C^1$-submanifold of $\mathbb R^3$, $\nu_M$ denotes the outer normal field on $M$ and $\sigma_M$ denotes the surface measure on $\mathcal B(M)$. Moreover, let $S^2$ denote the unit $2$-sphere, $$S^2(x):=\left\{y\in\mathbb R^3:|x-y|=1\right\}=x+S^2\;\;\;\text{for }x\in\mathbb R^3$$ and $$\omega_{x\to y}:=\frac{y-x}{|y-x|}\in S^2\;\;\;\text{for }x,y\in\mathbb R^3\text{ with }x\ne y.$$ For simplicity, assume that $$d_M(x,\omega):=\inf\left\{t>0:x+t\omega\in M\right\}<\infty\;\;\;\text{for all }x\in M\text{ and }\omega\in S^2\tag1$$

$\endgroup$
  • $\begingroup$ I noticed that you have been posting a lot in recent days. While I think it is great that you are interested in light transport, the mathematical level you are using to approach your problems is far too high for the majority of this community. Your questions are mostly research-oriented and, as such, I'm not sure how much this forum can help you. It is clear that you are coming from a pure math background like Veach. Realistically though, the intersection of people who fully understand his thesis and also lurk here is probably nil. I hope someone can prove me wrong... $\endgroup$ – Hubble Jan 17 at 0:27
  • $\begingroup$ @Hubble Thank you for your comment. $\endgroup$ – 0xbadf00d Jan 17 at 5:05
  • $\begingroup$ Is this what you're looking for? agraphicsguy.wordpress.com/2016/02/04/… $\endgroup$ – lightxbulb Jan 17 at 21:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.