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
|