|
|
I am trying to work out how the normal vector in a
smooth triangle works(I posted a similar question in
povray.advanced-users and quickly realised I need to
back up a bit and start at the begining).
The docs say that the default for normals is 0.5, I assume
this is supposed to give me a regular(normal) surface. But
I put a smooth_triangle with 0.5 normals next to a plain ol'
triangle, each with the same pigment{Red}, and got two different
colors. Am I just making a dumb mistake? Or is this correct
for smooth_triangles?
Here's my code:
#include "colors.inc"
global_settings{
assumed_gamma 1.0
}
camera{
location <0.0, 1.0, -4.0>
direction <0, 0, 1>
right <1.33, 0, 0>
look_at <0.0, 0.0, 0.0>
}
light_source{
0*x
rgb <1.0,1.0,1.0>
translate <-10, 30, -30>
fade_distance 55
fade_power 100
}
plane { y, -1 pigment {color rgb <0.8,0.4,0.1>}}
sky_sphere{
pigment{
gradient y
color_map { [0.0 color blue 0.6] [1.0 color rgb 1] }
}
}
smooth_triangle{
< 0, 0, 0> < .5, .5, .5> // <Vertex1> <SurfaceNormal1>
< 1, 0, 0> < .5, .5, .5> // <Vertex2> <SurfaceNormal2>
< 0, 1, 0> < .5, .5, .5> // <Vertex3> <SurfaceNormal3>
pigment{Red}
}
triangle{
< 0, 0, 0> // <Vertex1>
<-1, 0, 0> // <Vertex2>
< 0, 1, 0> // <Vertex3>
pigment{Red}
}
--
...coffee?...yes please! extra sugar,extra cream...Thank you.
Post a reply to this message
|
|