POV-Ray : Newsgroups : povray.unofficial.patches : Why does POV-Ray allocate so many memory blocks for textures? : Why does POV-Ray allocate so many memory blocks for textures? Server Time
28 Jun 2024 14:49:35 EDT (-0400)
  Why does POV-Ray allocate so many memory blocks for textures?  
From: Ray Gardener
Date: 9 Jun 2003 00:27:19
Message: <3ee40ca7@news.povray.org>
I asked this before but no one explained it fully.
Mr. Froehlich mentioned something about Knuth,
numerous potential texture accesses during raytracing,
and implied that the answer should be patently obvious.

When POV loads a texture, it allocates a memory block
for each color channel and scanline of the image.
So a 256 pixel tall 24-bit RGB texture would take
256 x 3 = 768 memory blocks. I can't imagine that
this

The only two reasons I can imagine for using so many smaller
blocks is that

- The memory manager could page scanlines efficiently
  in and out of memory as they become popular and unpopular.
  But don't modern CPUs already do the paging automatically using some
small blocksize independant of higher-level
memory managers? I've never allocated textures
in such a fine-grained manner but have never
noticed a performance problem either.

Ray Gardener
Daylon Graphics Ltd.
"Heightfield modeling perfected"
http://www.daylongraphics.com


Post a reply to this message

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