POV-Ray : Newsgroups : povray.newusers : Normal bumpiness Server Time
26 Nov 2024 21:37:52 EST (-0500)
  Normal bumpiness (Message 1 to 6 of 6)  
From: Omega
Subject: Normal bumpiness
Date: 18 Nov 2003 11:20:01
Message: <web.3fba4674abf4a7bc6b7c745d0@news.povray.org>
Hi all

Yet another question..

I'm creating several spheres in a scene, and I added bumpiness with the
"normal" keyword.

I just discovered that each time I render the scene, the bumpiness stay the
same. Isn't a random function?

I thought it would change from one render to another.. but.. since I wanted
the bumpiness to stay the same, it's perfectly fine for me.. I also wanted
to make sure it will always behave like that.

Thanks!
O.


Post a reply to this message

From: Tim Nikias v2 0
Subject: Re: Normal bumpiness
Date: 18 Nov 2003 11:46:10
Message: <3fba4cd2$1@news.povray.org>
> I just discovered that each time I render the scene, the bumpiness stay
the
> same. Isn't a random function?

Povray makes use of pseudo-random streams, but for normals, it uses the
inbuilt patterns, and they're not random at all. And even if you use the
rand()-stream to actually randomize the "location" of the pattern, then it
will stay the same as long as the seed isn't changed. I'm not too sure about
different platforms though, some Guru needs to answer that.

-- 
"Tim Nikias v2.0"
Homepage: <http://www.nolights.de>
Email: tim.nikias (@) nolights.de


Post a reply to this message

From: Omega
Subject: Re: Normal bumpiness
Date: 18 Nov 2003 12:50:01
Message: <web.3fba5b524daf0e006b7c745d0@news.povray.org>
Tim Nikias v2.0 wrote:
>Povray makes use of pseudo-random streams, but for normals, it uses the
>inbuilt patterns, and they're not random at all. And even if you use the
>rand()-stream to actually randomize the "location" of the pattern, then it
>will stay the same as long as the seed isn't changed. I'm not too sure about
>different platforms though, some Guru needs to answer that.

Ok, as long as I have the assurance that the bump pattern won't change if I
don't move the sphere, it's fine.

Thanks!
O.


Post a reply to this message

From: Christopher James Huff
Subject: Re: Normal bumpiness
Date: 18 Nov 2003 14:16:05
Message: <cjameshuff-9FEC18.14125118112003@netplex.aussie.org>
In article <3fba4cd2$1@news.povray.org>,
 "Tim Nikias v2.0" <tim.nikias (@) nolights.de> wrote:

> > I just discovered that each time I render the scene, the bumpiness stay
> the
> > same. Isn't a random function?

Pseudo-random, and reproduceable.


> Povray makes use of pseudo-random streams, but for normals, it uses the
> inbuilt patterns, and they're not random at all. And even if you use the
> rand()-stream to actually randomize the "location" of the pattern, then it
> will stay the same as long as the seed isn't changed. I'm not too sure about
> different platforms though, some Guru needs to answer that.

The noise patterns will be identical on any platform. The only things 
that vary from render to render are jitter and crand, which is one 
reason they are discouraged in animations.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tagpovrayorg
http://tag.povray.org/


Post a reply to this message

From: Mike Williams
Subject: Re: Normal bumpiness
Date: 18 Nov 2003 14:43:16
Message: <SwanzDAtTnu$EwlP@econym.demon.co.uk>
Wasn't it Omega who wrote:
>Tim Nikias v2.0 wrote:
>>Povray makes use of pseudo-random streams, but for normals, it uses the
>>inbuilt patterns, and they're not random at all. And even if you use the
>>rand()-stream to actually randomize the "location" of the pattern, then it
>>will stay the same as long as the seed isn't changed. I'm not too sure about
>>different platforms though, some Guru needs to answer that.
>
>Ok, as long as I have the assurance that the bump pattern won't change if I
>don't move the sphere, it's fine.

You just have to be careful about how you move the object. In this first
example the two spheres have exactly the same bumps:

sphere {0,1 pigment {rgb 1}
 normal {bumps scale 0.1}
}

sphere {0,1 pigment {rgb 1}
 normal {bumps scale 0.1}
 translate <2,0,0>
}


But in this second example the patterns of the bumps are different.

sphere {0,1 pigment {rgb 1}
 normal {bumps scale 0.1}
}

sphere {0,1 pigment {rgb 1}
 translate <2,0,0>
 normal {bumps scale 0.1}
}


What happens is that POV has a sort of random bump field that pervades
the whole of 3d space, and which becomes visible only when you put a
surface in that space. In the first example, the two spheres pick up
their bumps from the same place in the 3d bump field, and then one of
them moves sideways taking those bumps with it.

In the second example the sphere moves sideways first, and then has
different bumps from the new location applied to it.

Syntax like the following is used in animations where you want the
object to keep the same pattern as it moves through space, like real
solid objects do. You can be assured that this will always keep the same
pattern - if it didn't it wouldn't be possible to represent a realistic
textured object in a POV animation.

sphere {0,1 pigment {rgb 1}
 pigment {bozo scale 0.1}
 normal {bumps scale 0.1}
 translate <2*clock,0,0>
}

-- 
Mike Williams
Gentleman of Leisure


Post a reply to this message

From: Omega
Subject: Re: Normal bumpiness
Date: 18 Nov 2003 15:15:01
Message: <web.3fba7cf54daf0e006b7c745d0@news.povray.org>
>You just have to be careful about how you move the object. In this first
>example the two spheres have exactly the same bumps:
>
> ...
>
>But in this second example the patterns of the bumps are different.
>
> ...
>
>What happens is that POV has a sort of random bump field that pervades
>the whole of 3d space, and which becomes visible only when you put a
>surface in that space. In the first example, the two spheres pick up
>their bumps from the same place in the 3d bump field, and then one of
>them moves sideways taking those bumps with it.

It's exactly what I observed. I had 25 spheres with the same pattern..
because I created all of them at 0,0,0. I just figured out what you
explained here and created the spheres at different places.. et voila!

Thanks for the help!
O.


Post a reply to this message

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