POV-Ray : Newsgroups : povray.general : Fog and Media sphere : Fog and Media sphere Server Time
1 Aug 2024 00:24:34 EDT (-0400)
  Fog and Media sphere  
From: Francis
Date: 7 Jun 2006 15:45:01
Message: <web.44872c3c307411394e7319190@news.povray.org>
Hi,

This is my first message here, so I will introduce myself briefly :
I live in the south of France, I'm 36 and in real life, I'm ground
instructor in a flight school. I've used Povray 10 years ago, when my PC
needed to compute all night long to display the famous yellow ball ;-)
I started again raytracing a few days ago, and here is my first problem (I
didn't find any solution searching the web and the news) :

I want a fire in my fog :-)
The problem is that my sphere containing the media is visible in the fog :
http://www.chezgligli.net/img/light_fog_01.jpg

I had the same problem with the water reflection and no fog, but with
max_trace_level 10 it disappeared :
http://www.chezgligli.net/img/light_fog_02.jpg

Hope someone can help ;-)

Here is the scene, the sphere and the fog are at the end :

global_settings
{
  max_trace_level 10
}

#include "colors.inc"
#include "textures.inc"

camera
{
    location  <0, 2, -26>
    look_at <0,0,10>
}

//=====================================

//=====================================
light_source
{
    <0, 0, 0>, rgb <1, .2, 0>
    translate <0, 5, 150>
}

//=====================================

//=====================================

plane
{
    y, -1

    pigment
    {
        bozo
        pigment_map
        {
            [0.1 color <0, .5, .7>]
            [0.3 color <.3, .8, .7>]
            [0.6 color <.2, .6, .5>]
            [0.9 color <0.2, .2, .9>]
        }

        turbulence .5
    }
}

//=====================================
// L'eau / Water
//=====================================

box
{
    <-150, -.9, -100>, <150, -.8, 1000>

    texture
    {
        pigment
        {
            rgbf 1
        }

        normal
        {
            ripples 0.75
            frequency 2
            scale y*.1
            turbulence .1
        }

        finish
        {
            reflection {0.1, 1 fresnel}
            conserve_energy
        }

    }

    interior
    {
        ior 1.33
    }

}

//=====================================
// Le Soleil / the Sun
//=====================================

sphere // transparent sphere containing media
{
    0, 1 pigment { rgbt 1 } hollow

    interior
    {
        media
        {
            emission 1
            density
            {
                spherical density_map
                {
                    [0 rgb <0, 0, 0>]
                    [0.5 rgb <1, .3, 0>]
                    [0.5 rgb <1, .3, 0>]
                    [1 rgb <1, 0, 0>]
                }
            }
        }
    }
    scale 30
    translate <0, 5, 200>
}

//=====================================

//=====================================

  sky_sphere {
    pigment {
      gradient y
      color_map {
        [0.000 0.002 color rgb <1.0, 0.2, 0.0>
                     color rgb <1.0, 0.2, 0.0>]
        [0.002 0.200 color rgb <1.0, 0.2, 0.0>
                     color rgb <0.2, 0.2, 0.3>]
      }
      scale 2
      translate -1
    }
    rotate -95*x
  }
//=====================================
// Flammes / Flames
//=====================================

sphere
{
    <0,0,0>, 1
    hollow
   no_shadow
    pigment {rgbf 1}
    scale <.6, 1, .3>
    interior
    {
        media
        {
            intervals 5
            samples 5
            emission 6
            absorption 1
            density
            {
                spherical
                scale <5, 25, 4>
                warp
                {
                    turbulence 10 lambda 2 octaves 4
                }
                density_map
                {
                    [0 rgb 0]
                    [.5 rgb 0]
                    [.7 color Orange]
                    [.8 color Orange]
                    [.9 color Red]
                    [1 color Red ]
                }
            }
        }
    }


    translate <2, 2, -20>
}

//=====================================
// Brouillard / Fog
//=====================================

#declare Brouillard=1;
#if(Brouillard)
    fog
    {
        distance 8
        color rgbf<.8, .9, .8, 1>
        fog_type 2
        fog_offset 2
        fog_alt 1
        turbulence <1, 1, 1>
        turb_depth .8
        octaves .2
        lambda .5
        omega 1
    }
#end


Post a reply to this message

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