POV-Ray : Newsgroups : povray.binaries.images : Sponza WIP's : Re: Sponza WIP's Server Time
10 Aug 2024 07:17:40 EDT (-0400)
  Re: Sponza WIP's  
From: Przemek Loesch
Date: 17 Nov 2004 12:55:01
Message: <web.419b8fe41d492024deb6c0fb0@news.povray.org>
Samuel Benge <stb### [at] hotmailcom> wrote:
> What does that do? Does it involve the matrix keyword?

Not at all. I have never used "matrix" keyword but if I am not mistaken it
describes transformation of an object in 3D space. Actually I want to use
array[n][n], but technically it can be called matrix.
My idea is to create matrixes like this:
#declare array_for_single_point = array[5][5];
And then to fill this array with values based on depth map. The values are
scales for neighbours' colors.
For example - array for point which is exactly in focal distance looks like
this:
|0  0  0  0  0|
|0  0  0  0  0|
|0  0  25 0  0|
|0  0  0  0  0|
|0  0  0  0  0|
and for point which is completelly out of focus:
|1  1  1  1  1|
|1  1  1  1  1|
|1  1  1  1  1|
|1  1  1  1  1|
|1  1  1  1  1|
For all other points which are in between the values are in range 0-25.
The final value of color for the given point is averaged based on matrix
content.
I don't have any working code yet and even I'am not sure if it works like
this. If you are interested in please study "convolution_matrix.pov" and
"pprocess.inc" from MegaPov samples.
Przemek


Post a reply to this message

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