POV-Ray : Newsgroups : povray.unofficial.patches : Why the scaling of normals in megapov is wrong Server Time
2 Sep 2024 18:14:01 EDT (-0400)
  Why the scaling of normals in megapov is wrong (Message 11 to 15 of 15)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Nieminen Juha
Subject: Re: Why the scaling of normals in megapov is wrong
Date: 16 Dec 1999 02:55:12
Message: <38589ae0@news.povray.org>
Jerome M. BERGER <jbe### [at] enstfr> wrote:
: But when you scale a normal
: by 5, the way pov does it is equivalent to scaling by <5, 1, 5>

  Wrong. The slope doesn't change. Thus, the apparent depth is scaled by 5,
not by 1.
  To really scale the apparent depth by 1 instead of 5, the slopes would
have to be scaled by 1/5. Povray does not do this. This is easy to test:
Make an object with a normal modifier. Scale that object 100 times larger
and move the camera and the light source 100 times farther away. If what
you say was true, now the slopes would be 1/100 of the original and the
apparent depth would have not changed, so the normal modifier should be
almost invisible. This, of course, is not so. The slopes are not changed
and the apparent depth gets scaled by 100 too.
  Now make this same test in megapov. What happens is that megapov will
scale the _slopes_ by 100 as well, which means that the apparent depth
of the surface would be 10000 after scaling.

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Jerome M  BERGER
Subject: Re: Why the scaling of normals in megapov is wrong
Date: 16 Dec 1999 13:36:01
Message: <385930C3.D2196B53@enst.fr>
Nieminen Juha wrote:
> 
> Jerome M. BERGER <jbe### [at] enstfr> wrote:
> : But when you scale a normal
> : by 5, the way pov does it is equivalent to scaling by <5, 1, 5>
> 
>   Wrong. The slope doesn't change. Thus, the apparent depth is scaled by 5,
> not by 1.
	No, the slope *does* change... Try it.

>   To really scale the apparent depth by 1 instead of 5, the slopes would
> have to be scaled by 1/5. Povray does not do this. This is easy to test:
> Make an object with a normal modifier. Scale that object 100 times larger
> and move the camera and the light source 100 times farther away. If what
> you say was true, now the slopes would be 1/100 of the original and the
> apparent depth would have not changed, so the normal modifier should be
> almost invisible. This, of course, is not so. The slopes are not changed
> and the apparent depth gets scaled by 100 too.
	I did precisely this test and if the normal is inside a normal_map I
get what you said, but if the normal is on its own it *is* almost
invisible...

>   Now make this same test in megapov. What happens is that megapov will
> scale the _slopes_ by 100 as well, which means that the apparent depth
> of the surface would be 10000 after scaling.
	I just did the test with megapov 0.2 and the scene was the same no
matter what scale factor I used...

		Jerome
-- 
*******************************

* they'll tell you what can't * mailto:ber### [at] inamecom
* be done and why...          * http://www.enst.fr/~jberger
* Then do it.                 *
*******************************


Post a reply to this message

From: Nieminen Juha
Subject: Re: Why the scaling of normals in megapov is wrong
Date: 17 Dec 1999 05:54:45
Message: <385a1675@news.povray.org>
Jerome M. BERGER <jbe### [at] enstfr> wrote:
: 	I did precisely this test and if the normal is inside a normal_map I
: get what you said, but if the normal is on its own it *is* almost
: invisible...

  Well, I did the same and the apparent depth of the surface doesn't change
at all. All the images render identically no matter what value of 'Size' you
specify here:

#declare Size=1;
#debug concat("Size=",str(Size,1,0),"\n")

camera { location -z*4*Size look_at 0 angle 35 }
light_source { <100,200,-150>*Size, 1 }
sphere
{ 0,Size
  pigment { rgb x } finish { specular .5 }
  normal { bumps .5 scale .1*Size }
}


-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Jerome M  BERGER
Subject: Re: Why the scaling of normals in megapov is wrong
Date: 17 Dec 1999 13:34:13
Message: <36794E56.8002F8C8@enst.fr>
Nieminen Juha wrote:
> 
>   Well, I did the same and the apparent depth of the surface doesn't change
> at all. All the images render identically no matter what value of 'Size' you
> specify here:
> 
	I've just seen a post by Nathan saying that standard pov already
handled properly normals such as bumps and waves... I used a crackle for
my tests, which wasn't correct.

		Jerome
-- 
*******************************

* they'll tell you what can't * mailto:ber### [at] inamecom
* be done and why...          * http://www.enst.fr/~jberger
* Then do it.                 *
*******************************


Post a reply to this message

From: Nieminen Juha
Subject: Re: Why the scaling of normals in megapov is wrong
Date: 19 Dec 1999 13:28:56
Message: <385d23e8@news.povray.org>
Jerome M. BERGER <jbe### [at] enstfr> wrote:
: 	I've just seen a post by Nathan saying that standard pov already
: handled properly normals such as bumps and waves... I used a crackle for
: my tests, which wasn't correct.

  So the answer is: Some pattern types work fine, others don't.
  This definitely should be fixed.

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

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