POV-Ray : Newsgroups : povray.beta-test : Height field defects Server Time
29 Jul 2024 04:29:20 EDT (-0400)
  Height field defects (Message 1 to 10 of 11)  
Goto Latest 10 Messages Next 1 Messages >>>
From: Slime
Subject: Height field defects
Date: 1 Feb 2004 03:00:09
Message: <401cb209$1@news.povray.org>
First off, let me thank the POV-Team for including my fix for height field
normals!

However, while checking out whether it got included or not, I noticed
another problem: along the right and upper edges of height fields, the
normals are undefined. I actually discovered this problem back when I was
working with the height field code before, but I guess it got overlooked. In
any case, the normals of the rightmost and topmost vertices of height fields
are not calculated, so seemingly random values from the allocated memory are
used instead. This scene demonstrates the problem:

camera {
  location <.8,1,-.5>
  look_at <.5,0,.5>
}

height_field
{
  function 32, 32 {pattern{bozo scale 1/3}}
  smooth
  scale <2,.5,2>/2
  pigment {rgb 1}
}

light_source {
  <.5,3.5,-.5>*0 + <-1,1,-1>*999
  rgb 1
}

Now, you will get different results than I did, because it's taking
uninitialized data from memory - it's actually different each time you
render. The areas to look at are the rightmost and uppermost parts of the
height field.

If I remember correctly, this problem can be fixed simply by replacing two
less-than signs with less-than-or-equal-to signs in the source code.

By the way: I noticed anti-aliasing was changed so that clipping occurs
after anti-aliasing. (You can see this effect on the edge of the height
field sometimes.) I'll be interested to see how this change turns out. =)

So... anyone care to render my scene and confirm the problem? Thanks =)

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


Post a reply to this message

From: ingo
Subject: Re: Height field defects
Date: 1 Feb 2004 03:28:21
Message: <Xns9482605C56C4Aseed7@news.povray.org>
in news:401cb209$1@news.povray.org Slime wrote:

> In
> any case, the normals of the rightmost and topmost vertices of height
> fields are not calculated, so seemingly random values from the
> allocated memory are used instead.

I subtracted two consecutive renders of your scene, in the resulting image 
is a white line where the left and bottom edges of the HF are. So bug 
confirmed

Athlon 1800+ 1.5GB Win2000.

Ingo


Post a reply to this message

From: Slime
Subject: Re: Height field defects
Date: 1 Feb 2004 14:16:36
Message: <401d5094$1@news.povray.org>
> I subtracted two consecutive renders of your scene, in the resulting image
> is a white line where the left and bottom edges of the HF are. So bug
> confirmed


The left and bottom? That's strange, I didn't have any problems with that
area.

The artifacts should be plainly visible - though as I said, you can't
necessarily see it immediately, since the uninitialized memory has to
already have been used for something else.

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


Post a reply to this message

From: Slime
Subject: Re: Height field defects
Date: 1 Feb 2004 14:24:37
Message: <401d5275$1@news.povray.org>
> > I subtracted two consecutive renders of your scene, in the resulting
image
> > is a white line where the left and bottom edges of the HF are. So bug
> > confirmed
>
>
> The left and bottom? That's strange, I didn't have any problems with that
> area.


After some thought, I suspect the white line you got in the difference was
caused by AA jittering, and not the bug I described.

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


Post a reply to this message

From: Slime
Subject: Re: Height field defects
Date: 1 Feb 2004 14:27:22
Message: <401d531a$1@news.povray.org>
I have posted two example images in povray.beta-test.binaries.

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


Post a reply to this message

From: ingo
Subject: Re: Height field defects
Date: 1 Feb 2004 15:06:51
Message: <Xns9482D6C9376DDseed7@news.povray.org>
in news:401d5275$1@news.povray.org Slime wrote:

> After some thought, I suspect the white line you got in the
> difference was caused by AA jittering, and not the bug I described.
> 

Oops, that could be.
I don't get the artifacts as shown in the images you posted.

Ingo


Post a reply to this message

From: Slime
Subject: Re: Height field defects
Date: 1 Feb 2004 15:09:44
Message: <401d5d08$1@news.povray.org>
> Oops, that could be.
> I don't get the artifacts as shown in the images you posted.


It seems like you might have to first increase the height field size (to
like 40x40 or 64x64 or whatever) and then reduce it again. Just keep
changing the size and rendering and re-rendering and eventually you'll get
it.

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


Post a reply to this message

From: Christoph Hormann
Subject: Re: Height field defects
Date: 1 Feb 2004 15:11:16
Message: <6230f1-fad.ln1@triton.imagico.de>
Slime wrote:
> [...]
> 
> If I remember correctly, this problem can be fixed simply by replacing two
> less-than signs with less-than-or-equal-to signs in the source code.

That seems correct, the Megapov patch changed this together with the 
Smoothing problem but this was not in 3.6.  Should be fixed in next beta.

Christoph

-- 
POV-Ray tutorials, include files, Sim-POV,
HCR-Edit and more: http://www.tu-bs.de/~y0013390/
Last updated 11 Jan. 2004 _____./\/^>_*_<^\/\.______


Post a reply to this message

From: Fabien Mosen
Subject: Re: Height field defects
Date: 1 Feb 2004 16:08:10
Message: <401d6aba@news.povray.org>
Slime wrote:
> I have posted two example images in povray.beta-test.binaries.

I get the same kind of artefacts.

Fabien.


Post a reply to this message

From: Warp
Subject: Re: Height field defects
Date: 1 Feb 2004 17:03:48
Message: <401d77c3@news.povray.org>
Strange, I don't get those artifacts.

  However, what worries me the most is that this heightfield should
be smooth but isn't. The grid is clearly visible and shouldn't. There's
something wrong here.
  It looks better than when rendered with 3.5, but I still think the grid
should not be visible.

  Does anyone know what's going on here?

  Compare it to this:

camera {
  location <.8,1,-.5>
  look_at <.5,0,.5>
}

#include "shapes.inc"
object
{ HF_Square(function {pattern{bozo scale 1/3}}, no, no, 32, yes, "", 0, 1)
  scale <2,.5,2>/2
  pigment {rgb 1}
}

light_source {
  <.5,3.5,-.5>*0 + <-1,1,-1>*999
  rgb 1
}


-- 
#macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb x]
[1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
-1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// - Warp -


Post a reply to this message

Goto Latest 10 Messages Next 1 Messages >>>

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