|
|
A general update on some latest experiments. I played with adding in recusive,
adaptive subsampling to help speed things up a little bit. This was only done
for the number of sample traces run around each intersection point: start with a
minimum number of traces, if intersections are found, recurse to additional
traces until the maximum depth or confidence level is reached
Three variables get set:
1) minimum recursion depth
2) maximum recursion depth
3) confidence level
Both minimum and maximum recursion depth are 2^x values so (0=1, 1=2, 2=4, etc)
usually I would always set minimum to 2 which means 4 samples are traced at
0,90,180 & 270 degrees. Confidence is based on the percent change of the
returned value from one recursion level to the next.
As a sample I ran my elephant model through it. The general numbers:
model height: 200 (bounding box 313 diagonal)
resolution: 500 (based on bounding box diagonal)
control depth: 15
control angle: 85
surface offset: 0.05
At this resolution, 251,001 initial traces are sent (501x501). Of these, 55,024
succeed in hitting the object (22%). This is expected because of how I am
choosing my sample grid size: given a general object size of 200 units, and a
grid of 313 units means that at best, the model fill ~41% of the grid. This is
something I may yet work on tuning.
For the testing, I used a base maximum depth of 5 (2^5 = 32 samples). At this
depth, the maximum number of traces possible is 8,032,032 on the full sample
grid (including both object intersection and normal sample traces
251,001+251,001*32), and 2,011,769 based on the successful object trace hits.
1)
min RD = 5
max RD = 5
conf = 1
total traces = 2,011,769 (100%)
parse time 112sec
2)
min RD = 2
max RD = 5
conf = 1
total traces = 1,600,309 (80%)
parse time 97sec (87%)
3)
min RD = 2
max RD = 5
conf = 0.9
total traces = 1,103,477 (55%)
parse time 76sec (68%)
4) for comparison
min RD = 2
max RD = 2
conf = 1
total traces = 471,097
parse time 48sec
Note that there is a difference between 1 & 2 despite a conficence level of 1 as
if no sample intersections are found on the first pass, the algorithm kicks out.
This is not as dramatic an impact as I was hoping for, but it does have some
value in helping with render time.
-tgq
Post a reply to this message
Attachments:
Download 'trac.jpg' (143 KB)
Preview of image 'trac.jpg'
|
|