POV-Ray : Newsgroups : povray.general : Skies and Clouds Server Time
28 Nov 2024 02:49:44 EST (-0500)
  Skies and Clouds (Message 1 to 8 of 8)  
From: fls13
Subject: Skies and Clouds
Date: 25 Aug 2007 17:20:01
Message: <web.46d09be8688b92c936d75c9e0@news.povray.org>
I've monkeyed about trying to get the right look the past couple weekends
and have stumbled upon something I'm happy with and would like to share.
The solution i've found is 2 spheres, the skysphere, for the sky itself,
and another sphere properly textured for the clouds.

It's a fairly simple solution that doesn't rely on the built in pigments and
questionable color mapping and provides, I think, more realistic results
pretty quick and easy.

Now it's the inner cloud sphere that proved tricky, but my solution is this.
I found a number of cloud transparency maps on the internet for renders of
earth from space. I manip and use them for the transparency and then crop
and manip actual cloud photos for the color part of the texture. Then I can
rotate the cloud sphere and get any variety of sky I like.

Here are my skysphere settings for 4 distinct times of day. Of course you
can adjust the gradient to suit your own purposes, but the colors were
pulled and averaged from a number of photos, so they're pretty accurate:

// ***********************************
//  SKYSPHERE CODE
// ***********************************

//Sunrise
sky_sphere {
  pigment {
    gradient y
    color_map {
        [(1-cos(radians(20)))/2 color rgb <1,0.552941176,0.184313725>]
        [(1-cos(radians(60)))/2 color rgb
<0.474509804,0.525490196,0.62745098>]
        [(1-cos(radians(90)))/2 color rgb
<0.196078431,0.329411765,0.580392157>]
         }
  }
}


//Daysky
sky_sphere {
  pigment {
    gradient y
    color_map {
        [(1-cos(radians(50)))/2 color rgb <0.6,0.721568627,0.764705882>]
        [(1-cos(radians(60)))/2 color rgb
<0.482352941,0.674509804,0.839215686>]
        [(1-cos(radians(90)))/2 color rgb
<0.364705882,0.584313725,0.803921569>]
         }
  }
}

//Overcast
sky_sphere {
  pigment {
    gradient y
    color_map {
        [(1-cos(radians(50)))/2 color rgb
<0.835294118,0.831372549,0.811764706>]
        [(1-cos(radians(60)))/2 color rgb
<0.749019608,0.756862745,0.760784314>]
        [(1-cos(radians(90)))/2 color rgb
<0.62745098,0.623529412,0.631372549>]
         }
  }
}

//Nightsky
sky_sphere {
  pigment {
    gradient y
    color_map {
        [(1-cos(radians(30)))/2 color rgb
<0.254901961,0.290196078,0.48627451>]
        [(1-cos(radians(45)))/2 color rgb
<0.141176471,0.17254902,0.294117647>]
        [(1-cos(radians(90)))/2 color rgb
<0.133333333,0.137254902,0.207843137>]
         }
  }
}

// ***********************************
//  END SKYSPHERE CODE
// ***********************************


Post a reply to this message

From: Warp
Subject: Re: Skies and Clouds
Date: 25 Aug 2007 18:20:30
Message: <46d0ab2e@news.povray.org>
fls13 <fls### [at] netzeronet> wrote:
> I've monkeyed about trying to get the right look the past couple weekends
> and have stumbled upon something I'm happy with and would like to share.
> The solution i've found is 2 spheres, the skysphere, for the sky itself,
> and another sphere properly textured for the clouds.

  Wouldn't using a plane for the clouds be easier?

-- 
                                                          - Warp


Post a reply to this message

From: fls13
Subject: Re: Skies and Clouds
Date: 25 Aug 2007 23:20:05
Message: <web.46d0f0a38ed03b7599f93230@news.povray.org>
>   Wouldn't using a plane for the clouds be easier?
>
> --
>                                                           - Warp

Depends on what your goals are. A slight rotation of the clouds sphere gives
a completely different look and when you combine that with the variations in
the skyspheres, for me, it's quick and easy to get whatever and exactly what
you want.


Post a reply to this message

From: Thomas de Groot
Subject: Re: Skies and Clouds
Date: 26 Aug 2007 03:14:36
Message: <46d1285c@news.povray.org>
"fls13" <fls### [at] netzeronet> schreef in bericht 
news:web.46d0f0a38ed03b7599f93230@news.povray.org...
>>   Wouldn't using a plane for the clouds be easier?
>>
>> --
>>                                                           - Warp
>
> Depends on what your goals are. A slight rotation of the clouds sphere 
> gives
> a completely different look and when you combine that with the variations 
> in
> the skyspheres, for me, it's quick and easy to get whatever and exactly 
> what
> you want.
>
>
In cases like these, I generally use flatened spheres for the clouds. Only 
problem is the horizon, but that is often hidden by either haze or 
topography/buildings.

Thanks for the code by the way!

Thomas


Post a reply to this message

From: Warp
Subject: Re: Skies and Clouds
Date: 26 Aug 2007 03:39:54
Message: <46d12e49@news.povray.org>
fls13 <fls### [at] netzeronet> wrote:
> Depends on what your goals are. A slight rotation of the clouds sphere gives
> a completely different look and when you combine that with the variations in
> the skyspheres, for me, it's quick and easy to get whatever and exactly what
> you want.

  You can achieve the same thing with a translate on the plane.

  The problem with using a sphere is that you need to make it really
large and put its origin very far away (below) the camera for it to
look realistic, and objects that large might present rendering artifacts
due to limits in the floating point calculations.

  One common mistake (even present in the povray documentation) is to
center the could sphere at the camera. This, of course, makes no sense
and doesn't even begin to simulate real clouds. Real clouds are not
located on the surface of a sphere centered at the viewer's location.

-- 
                                                          - Warp


Post a reply to this message

From: M a r c
Subject: Re: Skies and Clouds
Date: 26 Aug 2007 04:04:35
Message: <46d13413@news.povray.org>

46d12e49@news.povray.org...
> fls13 <fls### [at] netzeronet> wrote:
>
>  The problem with using a sphere is that you need to make it really
> large and put its origin very far away (below) the camera for it to
> look realistic, and objects that large might present rendering artifacts
> due to limits in the floating point calculations.
>

But if the farthest (and invisible) parts of the sphere are very far, the 
rendered parts are at reasonable distance, aren't they?

Marc


Post a reply to this message

From: Warp
Subject: Re: Skies and Clouds
Date: 26 Aug 2007 04:50:42
Message: <46d13ee2@news.povray.org>
M_a_r_c <jac### [at] wanadoofr> wrote:
> But if the farthest (and invisible) parts of the sphere are very far, the 
> rendered parts are at reasonable distance, aren't they?

  So? It doesn't matter how close to the sphere's surface the camera is.
If its center is very far away and the radius is very large, it has
potential for artifacts.

-- 
                                                          - Warp


Post a reply to this message

From: M a r c
Subject: Re: Skies and Clouds
Date: 26 Aug 2007 05:17:39
Message: <46d14533$1@news.povray.org>

46d13ee2@news.povray.org...
>  So? It doesn't matter how close to the sphere's surface the camera is.
> If its center is very far away and the radius is very large, it has
> potential for artifacts.
>
Oh well, I didn't get cloud sphere large enough to get such visible 
artifacts and I like lowered large spheres to simulate cloud layer as well 
as atmosphere media

Marc


Post a reply to this message

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