|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
29. June Mike Andrews posted an image to
povray.binaries.images:
"Perlin's Improved Noise comparison ... (24K)"
The same day he also posted code for his test image to
povray.binaries.scene-files:
"Perlin's Improved Noise - SDL version"
I have now had a look at his code and have made a macro
that can produce noise functions that don't have the
"defects" of earlier Perlin noise functions. (I haven't
really verified this, but the results seems ok so far.)
My macro can be found in my reply today to his post
in povray.binaries.scene-files
I haven't yet looked at the source code for the noise
generators in POV-Ray v3.5 (or v3.6), so I don't know
if any or all of them use the "old" Perlin noise.
--
Tor Olav
http://subcube.net
http://subcube.com
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Tor Olav Kristensen wrote:
>
> 29. June Mike Andrews posted an image to
> povray.binaries.images:
> "Perlin's Improved Noise comparison ... (24K)"
>
> The same day he also posted code for his test image to
> povray.binaries.scene-files:
> "Perlin's Improved Noise - SDL version"
>
> I have now had a look at his code and have made a macro
> that can produce noise functions that don't have the
> "defects" of earlier Perlin noise functions. (I haven't
> really verified this, but the results seems ok so far.)
There are two critical issues about the noise generator: 1) possible
regularities. This does not only mean regular structures in the noise
pattern like in current ng3 but also periodicity and degeneration of the
function in 'far areas'. This all can be really tricky to test of
course. 2) performance. This is quite impossible to conclude from an
SDL version.
Christoph
--
POV-Ray tutorials, include files, Sim-POV,
HCR-Edit and more: http://www.tu-bs.de/~y0013390/
Last updated 01 May. 2004 _____./\/^>_*_<^\/\.______
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Christoph Hormann wrote:
> Tor Olav Kristensen wrote:
...
> There are two critical issues about the noise generator: 1) possible
> regularities. This does not only mean regular structures in the noise
> pattern like in current ng3 but also periodicity and degeneration of the
> function in 'far areas'. This all can be really tricky to test of
> course.
You can give the periodic interval as an argument to the
macro. This makes it easy to study the periodicity when
the interval is set small.
Do you know where the 'far areas' are and how the functions
typically degenerates ?
> 2) performance. This is quite impossible to conclude from an
> SDL version.
Why is that ?
The macro can produce noise functions that behave simlar
to f_noise3d()
--
Tor Olav
http://subcube.net
http://subcube.com
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Tor Olav Kristensen wrote:
>
> You can give the periodic interval as an argument to the
> macro. This makes it easy to study the periodicity when
> the interval is set small.
For most purposes the noise generator should have a periodicity as large
as possible.
> Do you know where the 'far areas' are and how the functions
> typically degenerates ?
try rendering:
camera {
orthographic
location <0,0,1>
look_at <0,0,0>
right 1*x
up 1*y
}
box {
<-0.5, -0.5, 0>, <0.5, 0.5, 0>
texture {
pigment {
bozo
color_map {
[0.0 color rgb 0.0 ]
[1.0 color rgb 1.0 ]
}
scale 0.01
translate 3e7*x
}
finish {
ambient 1.0
diffuse 0.0
}
}
}
> > 2) performance. This is quite impossible to conclude from an
>
>> SDL version.
>
>
> Why is that ?
>
> The macro can produce noise functions that behave simlar
> to f_noise3d()
But much slower. The noise generator is quite critical for the render
speed in a lot of scenes. That's why the Windows version of POV-Ray
contains a special hand optimized version of the noise function.
Christoph
--
POV-Ray tutorials, include files, Sim-POV,
HCR-Edit and more: http://www.tu-bs.de/~y0013390/
Last updated 01 May. 2004 _____./\/^>_*_<^\/\.______
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Christoph Hormann wrote:
> Tor Olav Kristensen wrote:
>
>>
>> You can give the periodic interval as an argument to the
>> macro. This makes it easy to study the periodicity when
>> the interval is set small.
>
>
> For most purposes the noise generator should have a periodicity as large
> as possible.
>
>> Do you know where the 'far areas' are and how the functions
>> typically degenerates ?
>
>
> try rendering:
>
> camera {
> orthographic
> location <0,0,1>
> look_at <0,0,0>
> right 1*x
> up 1*y
> }
>
> box {
> <-0.5, -0.5, 0>, <0.5, 0.5, 0>
> texture {
> pigment {
> bozo
> color_map {
> [0.0 color rgb 0.0 ]
> [1.0 color rgb 1.0 ]
> }
> scale 0.01
> translate 3e7*x
> }
> finish {
> ambient 1.0
> diffuse 0.0
> }
> }
> }
I see. But this works ok:
pigment {
function { f_noise3d(x + 3e7, y, z) }
color_map {
[0.0 color rgb 0.0 ]
[1.0 color rgb 1.0 ]
}
scale 0.01
}
>> > 2) performance. This is quite impossible to conclude from an
>>
>>> SDL version.
>>
>>
>>
>> Why is that ?
>>
>> The macro can produce noise functions that behave simlar
>> to f_noise3d()
>
>
> But much slower. The noise generator is quite critical for the render
> speed in a lot of scenes. That's why the Windows version of POV-Ray
> contains a special hand optimized version of the noise function.
Nice to know.
--
Tor Olav
http://subcube.net
http://subcube.com
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Tor Olav Kristensen wrote:
...
> I have now had a look at his code and have made a macro
> that can produce noise functions that don't have the
> "defects" of earlier Perlin noise functions. (I haven't
> really verified this, but the results seems ok so far.)
...
- But now the results doesn't seem ok any longer.
When I render this scene, I can see vertical and
horizontal "lines" in the noise.
#declare NoiseFn = PerlinNoise3DFunction(478696, 300, 0, 1)
box {
<-0.5, -0.5, 0>, <0.5, 0.5, 0>
texture {
pigment {
function { NoiseFn(x, y, z) }
color_map {
[0.0 color rgb 0.0 ]
[1.0 color rgb 1.0 ]
}
scale 0.01
}
finish {
ambient 1.0
diffuse 0.0
}
}
}
camera {
orthographic
location <0,0,1>
look_at <0,0,0>
right 1*x
up 1*y
}
If make the macro not use the POV-Ray's rand() function,
the noise improves a bit.
--
Tor Olav
http://subcube.net
http://subcube.com
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Tor Olav Kristensen wrote:
...
> When I render this scene, I can see vertical and
> horizontal "lines" in the noise.
Hmmm... When I replace "NoiseFn(x, y, z)" in the
code below with "f_noise_generator(x, y, z, 3)" from
"functions.inc" I see the same short "lines".
With "f_noise_generator(x, y, z, 2)" I get no such
lines. - The results seems more random with this
noise generator.
> #declare NoiseFn = PerlinNoise3DFunction(478696, 300, 0, 1)
>
> box {
> <-0.5, -0.5, 0>, <0.5, 0.5, 0>
> texture {
> pigment {
> function { NoiseFn(x, y, z) }
> color_map {
> [0.0 color rgb 0.0 ]
> [1.0 color rgb 1.0 ]
> }
> scale 0.01
> }
> finish {
> ambient 1.0
> diffuse 0.0
> }
> }
> }
>
> camera {
> orthographic
> location <0,0,1>
> look_at <0,0,0>
> right 1*x
> up 1*y
> }
>
> If make the macro not use the POV-Ray's rand() function,
> the noise improves a bit.
>
--
Tor Olav
http://subcube.net
http://subcube.com
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Tor Olav Kristensen wrote:
>
> Hmmm... When I replace "NoiseFn(x, y, z)" in the
> code below with "f_noise_generator(x, y, z, 3)" from
> "functions.inc" I see the same short "lines".
>
> With "f_noise_generator(x, y, z, 2)" I get no such
> lines. - The results seems more random with this
> noise generator.
This is exactly the problem of NG3.
Christoph
--
POV-Ray tutorials, include files, Sim-POV,
HCR-Edit and more: http://www.tu-bs.de/~y0013390/
Last updated 01 May. 2004 _____./\/^>_*_<^\/\.______
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Christoph Hormann wrote:
> Tor Olav Kristensen wrote:
>
>>
>> Hmmm... When I replace "NoiseFn(x, y, z)" in the
>> code below with "f_noise_generator(x, y, z, 3)" from
>> "functions.inc" I see the same short "lines".
>>
>> With "f_noise_generator(x, y, z, 2)" I get no such
>> lines. - The results seems more random with this
>> noise generator.
>
>
> This is exactly the problem of NG3.
OK, so it's not my coding that is bad.
I see now that this problem has been discussed before in
a thread that Ingo started in povray.beta-test.binaries
back in 22. Oct. 2001: "noise_generator histograms"
http://tinyurl.com/25c39
--
Tor Olav
http://subcube.net
http://subcube.com
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|