POV-Ray : Newsgroups : povray.binaries.images : "Images and memory use" example Server Time
5 Nov 2024 08:27:01 EST (-0500)
  "Images and memory use" example (Message 1 to 4 of 4)  
From: Tom York
Subject: "Images and memory use" example
Date: 11 Sep 2005 01:20:00
Message: <web.4323bddb39c4978ce0d101b60@news.povray.org>
This image is associated with the "Images and memory use?" thread in
p.general. The two panels in the image show the front of a box with ordinary
diffuse shading and a simple normal map. The box is lit by three lights,
red, green and blue, which are shining on to the box from the top-right,
bottom-left and bottom-right directions respectively. The box in the left
panel uses this for a normal:

normal {
  bump_map {
    png "bumptestin.png"
    interpolate 2
  }
}

bumptestin.png is just a couple of black circles drawn on a white
background. You can also do this with cells or another pattern instead of
the bump_map, it still "works".

The box on the right uses this:

#declare ImPig = pigment {
  image_map {
    png "bumptest.png"
    interpolate 2
  }
}

#declare ImFunc = function {
  pigment { ImPig }
}

normal {
  function { ImFunc(x,y,z).gray }
}

I don't understand why they look so different. I tried reducing the bump
strength using bump_size, but I couldn't get one to look like the other.
Lights, camera and geometry did not change. Also, if you use these two as
pigments instead of normals then they produce absolutely identical images.
What am I doing wrong?


Post a reply to this message


Attachments:
Download 'normalled.jpg' (17 KB)

Preview of image 'normalled.jpg'
normalled.jpg


 

From: Slime
Subject: Re: "Images and memory use" example
Date: 11 Sep 2005 01:23:38
Message: <4323bf5a$1@news.povray.org>
> I don't understand why they look so different.

I imagine the gradient of an image is calculated differently than the
gradiant of a function. Try setting the normal's accuracy to a low value
(like accuracy .000001 or whatever works best) to improve the sampling of
the function.

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

From: Tom York
Subject: Re: "Images and memory use" example
Date: 11 Sep 2005 01:35:00
Message: <web.4323c1ad57bb29a2e0d101b60@news.povray.org>
"Slime" <fak### [at] emailaddress> wrote:
> I imagine the gradient of an image is calculated differently than the
> gradiant of a function. Try setting the normal's accuracy to a low value
> (like accuracy .000001 or whatever works best) to improve the sampling of
> the function.

That was it; thanks! (An accuracy of 0.001 was sufficient)


Post a reply to this message

From: Slime
Subject: Re: "Images and memory use" example
Date: 11 Sep 2005 01:40:55
Message: <4323c367$1@news.povray.org>
> That was it; thanks! (An accuracy of 0.001 was sufficient)

Ah, yeah, the default is apparently .02, I thought it was lower.

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

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