uniform disk sampling failed hypothesis test, did i miss some point?

47 views
Skip to first unread message

卡卡西

unread,
Jun 7, 2017, 4:58:43 AM6/7/17
to pbrt




Srinath Ravichandiran

unread,
Jun 7, 2017, 8:34:20 AM6/7/17
to pbrt
Hi

The Warp::squareToUniformDiskPdf(const Point2f& pt) function passes points all over the uniform square and not just within the disk. Hence you are returning a pdf value of 1/2pi for all points (and hence your integrated density is uniform over the test region). You will have to do a rejection test to check if the point is within the disk (basically x^2 + y^2 <= 1) and return 1/2pi for only those points and zero everywhere else.

On Wednesday, 7 June 2017 04:58:43 UTC-4, 卡卡西 wrote:




卡卡西

unread,
Jun 7, 2017, 8:58:42 AM6/7/17
to pbrt
Hi, thanks very much for your reply, it works finally :)

在 2017年6月7日星期三 UTC+8下午8:34:20,Srinath Ravichandiran写道:
Reply all
Reply to author
Forward
0 new messages