|
![](/i/fill.gif) |
Chris Huff <chr### [at] yahoo com> wrote:
: r, g, b - unclipped RGB colors.
: x, y, z - intersection point.
: u, v - UV coordinates.
: depth - distance to intersection point.
: inorm_x, inorm_y, inorm_z - surface normal at intersection point.
: pnorm_x, pnorm_y, pnorm_z - perturbed surface normal.
: dir_x, dir_y, dir_z - ray direction(if I succeed in adding it to
: the available information).
Don't tell me all this is stored into memory in order to be able to apply
the post processing?
Hmm... Let's count.
If we make a 1024x768 image that would be 786432 pixels.
I suppose that the floating point numers are of 'double' type, which means
8 bytes (in PC and most other systems).
This means that for each pixel the rgb info will take 3*8 bytes, the
intersection point 3*8 bytes, the uv-coordinates 2*8 bytes, the depth 8
bytes, surface normals and perturbed normals 6*8 bytes and finally the ray
direction 3*8 bytes.
Summing all this up we get:
786432*(3*8+3*8+2*8+8+6*8+3*8) = 113246208 bytes = 108 Megabytes.
Taking into account that the average computer has 128 Megabytes of memory,
that would eat it up pretty efficiently.
If all this is not stored into memory, then forget this :)
--
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/
Post a reply to this message
|
![](/i/fill.gif) |