POV-Ray : Newsgroups : povray.newusers : Transparent containers : Transparent containers Server Time
4 Jul 2024 14:04:13 EDT (-0400)
  Transparent containers  
From: kf42
Date: 30 Nov 2010 12:55:01
Message: <web.4cf53751bf9e49d6eaa7546c0@news.povray.org>
Hi all,

I'm trying to use a transparent object to hold some media. Problem is, the
bounding object doesn't stay invisible if it's embedded in media itself. I'd
think this is a common problem, but I only found one relevant thread ("realistic
smoke with high degree of transparency"), and I'm already following all the
guidelines therein.

I attach a minimal example below. In this case the bounding object is empty; the
goal is just to get it to blend into its surroundings. I've tried to fill the
sphere with uniform media to "match up" with the outside, but there is no
density (set by clock, ranging from 0 to 10x the outside density) that works.

Has anybody seen this before?

--------------------------------------------------

#include "colors.inc"

global_settings {
    assumed_gamma 1
}

////////////////////////////////////////
// World

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

light_source {<-10,20,-15>, White}

// Backstop to prevent infinite ray errors
sphere {
    0, 40
    inverse
    pigment {rgb <0.70, 0.70, 0.90>}
    finish {
        diffuse 0.0
        ambient 1.0
    }
}

////////////////////////////////////////
// Haze Test

// The container, which at present contains nothing
sphere {
    <-1, 0, 0>, 5
    no_shadow
    hollow
    pigment {rgbt <1.0, 1.0, 1.0, 1.0>}
    interior {
        // Add a copy of the world haze to the container to compensate?
        media {
            scattering {2, White}
            density {White*clock}
        }
    }
}

// World-filling haze
// Kept separate from the inverse-sphere for improved portability
box {
    <-50, -50, -50>, <50, 50, 50>
    pigment {rgbt <1.0, 1.0, 1.0, 1.0>}
    no_shadow
    hollow
    interior {
        media {
            scattering {2, White}
            density {White*0.1}
        }
    }
}


Post a reply to this message

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