POV-Ray : Newsgroups : povray.binaries.images : Experiments with light probes : Re: Experiments with light probes Server Time
20 May 2024 02:46:07 EDT (-0400)
  Re: Experiments with light probes  
From: Trevor G Quayle
Date: 2 Jun 2009 13:35:01
Message: <web.4a2561fb75b7d3c981c811d20@news.povray.org>
A couple more little pieces of advice based on my thoughts on clipkas comments:

1) Make sure the mirrorball is as close to the centre of the camera view as
possible when taking the shots, minimizing lens distortion effects that occur
when off-centre (eg: barrel distortion)

2)  When picking your matching points for rotation, as I said, try to be as
precise as possible.  Also try to use points of objects that are more distant.
This will minimize the parallax errors.   There will still be parallax errors in
objects closer, but at least it will be minimized for the scene as a whole.
Picking closer points, though it may seem easier to be more precise, will
likely cause much more parallax errors.

3) This is a little secret I didn't want to describe yet, as it can be tricky to
master and involves a little math:

Due to the fact that you are not getting a true orthographic shot of the
mirrorball, some of the back portion of the scene is actually missing due to
perspective.  The amount missing is related to the ratio of ball size to
distance of camera from ball.  However, when transforming and using the map, it
is assumed that it is a true 360 image.  This can cause some distortion as well,
especially with larger ball/distance ratios.  This distortion, if noticeable
enough, can cause errors when trying to match and combine your two images.  I
had developed a method to try to minimize this.  It is not perfect and can be a
little tedious:

(I will use a ball diameter of D=60 (R=30), distance of X=300 and image
resolution of I=1000x1000 for the examples)

R/X=0.1  ratio of ball size to distance

A=2*ASIN(R/X)=11.5deg : total included angle of perspective.  This also means
that the area missing from the rear of the mirrorball is ~11.5deg

A/360=0.0638 (~6.38%) Percent missing

Now take the mirrorball and transform it to angular.
Now we want to crop the angular map LARGER than the edge by an amount equal to
the percent missing

1000*0.0638=64

Therefore, add 64 pixels to each of the top, bottom and sides of the image.
There will be no image information in this area, but thats ok as this is in the
areas getting masked out amyways. Make sure under "Select/Select Options" that
"Restrict Selection to Image" is UNCHECKED.

Now there's one more tricky thing to do before proceeding.  If you scan over the
black crop areas, you'll note that their colour is "-1.#IO".  This will cause a
problem when combining as it is basically a null colour (not black) and HDRShop
doesnt handle it very well.  Make sure you have .BMP files set to open by an
appropriate editor by default in windows (I use goos old Windows Paint).  Go to
"File/Edit in Image Editor" and it should open up for editing.  Now flood the
perimeter black area to white or some other colour.  DO NOT EDIT ANYTHING ELSE.
 Save and close.  Back at HDRShop, click the "Hit OK when edit complete" button.
 It should update with the white borders now.  What happens here is that
everything is preserved as it was EXCEPT whatever was edited.  The borders
should be whatever colour you chose rather than showing the -1.#IO error

You can now proceed with point matching and masking/combining of the images from
the angular maps as before, but now we have compensated for the missing area.
Now this isn't exactly perfect due to the mirrorball not being 360deg, but it
should be much less noticeable.

As I said, this can be tricky and tedious, but I find it does help somewhat if
you can get it right.

-tgq


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.