POV-Ray : Newsgroups : povray.documentation.inbuilt : Should the sky_sphere tutorial be changed? Server Time
29 Mar 2024 06:19:30 EDT (-0400)
  Should the sky_sphere tutorial be changed? (Message 1 to 3 of 3)  
From: Warp
Subject: Should the sky_sphere tutorial be changed?
Date: 25 Feb 2003 07:35:56
Message: <3e5b632b@news.povray.org>
There's a problem in the sky_sphere tutorial which I think should be
corrected. I'm talking about the "Adding some clouds" section.

  Ok, the example is good in the sense that it demonstrates how you can
use multiple pigments in a sky sphere. However, the generated clouds don't
look good at all, and I have seen several times how it teaches a bad habit
to people (ie. to put clouds in the sky sphere).

  The reason why the clouds look bad is that the sky sphere is like a
sphere which is centered at the camera, while the real sky is like a sphere
which is centered more than 6000 km below the camera.

  The easiest way of getting realistic-looking clouds is, of course, using
a plane. The sky_sphere can be used for coloring the sky, like this:

camera { location <0,-1,-10> look_at 0 }
light_source { <1000,2000,-200>, 1 }
plane { y,-2 pigment { green 1 } }
sphere { 0,1.2 pigment { rgb 0 } finish { reflection 1 } }

sky_sphere
{ pigment
  { gradient y color_map
    { [0 rgb <.8,.9,1>]
      [.2 rgb <.2,.5,1>]
      [1 blue 1]
    }
  }
}

plane
{ -y,-100
  pigment
  { bozo color_map
    { [0 rgb .5]
      [.1 rgb 1 filter .2]
      [.5 rgbf 1]
    }
    turbulence .8
    scale 100
  }
  finish { ambient 1 }
}


  I wonder if the tutorial should be changed a bit so that it doesn't teach
the bad habit of putting the clouds in the sky_sphere.

-- 
plane{-x+y,-1pigment{bozo color_map{[0rgb x][1rgb x+y]}turbulence 1}}
sphere{0,2pigment{rgbt 1}interior{media{emission 1density{spherical
density_map{[0rgb 0][.5rgb<1,.5>][1rgb 1]}turbulence.9}}}scale
<1,1,3>hollow}text{ttf"timrom""Warp".1,0translate<-1,-.1,2>}//  - Warp -


Post a reply to this message

From: hughes, b 
Subject: Re: Should the sky_sphere tutorial be changed?
Date: 25 Feb 2003 09:17:06
Message: <3e5b7ae2@news.povray.org>
"Warp" <war### [at] tagpovrayorg> wrote in message
news:3e5b632b@news.povray.org...
>
>   Ok, the example is good in the sense that it demonstrates how you can
> use multiple pigments in a sky sphere. However, the generated clouds don't
> look good at all, and I have seen several times how it teaches a bad habit
> to people (ie. to put clouds in the sky sphere).
>
>   The easiest way of getting realistic-looking clouds is, of course, using
> a plane.

Hmm, yeah... although, bad habit or not it's all about using the sky_sphere
not planes. Clouds happen to be easy if you do it that way. I made an
attempt to change it anyhow, just to see how it might look if done a little
differently. What occured to me while doing so I began to wonder why the
light source wasn't moved into position where the faked Sun is at. If
anything, I think I'd change that. But I was also able to get a fairly
decent cloudy sky by simply rotating the gradient color map separate from
the clouds and scaling the clouds much smaller in the y direction.
Here's the whole scene file, below, and you can probably guess that in
making such changes the whole section of the tutorial would need to be
redone. It's overkill. However, if the clouds were transformed differently,
i.e. scale <0.2,0.05,0.2> and not rotated with the background colors, it
should be suitable without making further changes IMHO.

  #include "colors.inc"
  camera {
    location <0, 1, -4>
    look_at <0, 2, 0>
    angle 80
  }
  light_source { 1000*z, color White parallel point_at 0 rotate -15*x }
  sphere {
    2*y, 1
    pigment { color rgb <1, 1, 1> }
    finish { ambient 0.2 diffuse 0 reflection 0.6 }
  }
  sky_sphere {
    pigment {
      gradient y
      color_map {
        [0.000 0.002 color rgb <1.0, 0.4, 0.3>
                     color rgb <1.0, 0.3, 0.2>] // sun's outer edge
        [0.002 0.100 color rgb <0.8, 0.2, 0.1>
                     color rgb <0.7, 0.3, 0.4>]
        [0.100 1.000 color rgb <0.7, 0.3, 0.4>
                     color rgb <0.2, 0.4, 0.8>]
      }
      scale 2
      translate -y
    rotate -135*x
    }
    pigment {
      bozo
      turbulence 0.65
      octaves 6
      omega 0.7
      lambda 2
      color_map {
          [0.0 0.1 color rgb <0.85, 0.85, 0.85>
                   color rgb <0.75, 0.75, 0.75>]
          [0.1 0.5 color rgb <0.75, 0.75, 0.75>
                   color rgbt <1, 1, 1, 1>]
          [0.5 1.0 color rgbt <1, 1, 1, 1>
                   color rgbt <1, 1, 1, 1>]
      }
      scale <0.2, 0.05, 0.2>
      rotate -15*x
    }
  }
  plane {
    y, 0
    pigment { color Green }
    finish { ambient 0.3 diffuse 0.7 }
  }
  fog {
   fog_type 2
   fog_alt 1
   fog_offset 0
   distance 20
   color <0.6,0.5,0.5>
  }


Post a reply to this message

From: Abe
Subject: Re: Should the sky_sphere tutorial be changed?
Date: 25 Feb 2003 09:30:06
Message: <web.3e5b7cbf2476b494fdc08dd80@news.povray.org>
Warp wrote:
>  There's a problem in the sky_sphere tutorial which I think should be
>corrected. I'm talking about the "Adding some clouds" section.
>
>  Ok, the example is good in the sense that it demonstrates how you can
>use multiple pigments in a sky sphere. However, the generated clouds don't
>look good at all, and I have seen several times how it teaches a bad habit
>to people (ie. to put clouds in the sky sphere).
>
>  The reason why the clouds look bad is that the sky sphere is like a
>sphere which is centered at the camera, while the real sky is like a sphere
>which is centered more than 6000 km below the camera.
>
>  The easiest way of getting realistic-looking clouds is, of course, using
>a plane. The sky_sphere can be used for coloring the sky, like this:
>
>camera { location <0,-1,-10> look_at 0 }
>light_source { <1000,2000,-200>, 1 }
>plane { y,-2 pigment { green 1 } }
>sphere { 0,1.2 pigment { rgb 0 } finish { reflection 1 } }
>
>sky_sphere
>{ pigment
>  { gradient y color_map
>    { [0 rgb <.8,.9,1>]
>      [.2 rgb <.2,.5,1>]
>      [1 blue 1]
>    }
>  }
>}
>
>plane
>{ -y,-100
>  pigment
>  { bozo color_map
>    { [0 rgb .5]
>      [.1 rgb 1 filter .2]
>      [.5 rgbf 1]
>    }
>    turbulence .8
>    scale 100
>  }
>  finish { ambient 1 }
>}
>
>
>  I wonder if the tutorial should be changed a bit so that it doesn't teach
>the bad habit of putting the clouds in the sky_sphere.
>
>plane{-x+y,-1pigment{bozo color_map{[0rgb x][1rgb x+y]}turbulence 1}}
>sphere{0,2pigment{rgbt 1}interior{media{emission 1density{spherical
>density_map{[0rgb 0][.5rgb<1,.5>][1rgb 1]}turbulence.9}}}scale
><1,1,3>hollow}text{ttf"timrom""Warp".1,0translate<-1,-.1,2>}//  - Warp -
>

I feel (and have felt for some time) pretty strongly about making changes in
this area of the documentation as you suggest. What I'm not sure about is
how in depth about rendering clouds this tutorial should go since it is
mainly addressing the sky_sphere feature and not skies in general. Perhaps
the best is what you already suggested in the Pov sdl example above with a
few sentences explaining why it is not necessarily desirable to apply a
cloud pigment to the sky_sphere. However, if the tutorial were to expand
into the areas of skies in general, I can think many principles and
techniques which would have to be mentioned in order to provide at least a
comprehensive outline. Much of this would be very specific, and would be
going beyond the general range of the documentation as it stands.

There is also another section in the sky_sphere tutorial on adding a sun,
where I feel the technique espoused offers somewhat limited flexibility. I
see a layered pigment here as being more appropriate which would allow the
sun to be controlled independently of the sky colors and also to enable
maintaining the vertical gradient of the sky colors regardless of the
position of the sun.

--
Abe
============
http://www2.taconic.net/bullfrog/sky
============


Post a reply to this message

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