POV-Ray : Newsgroups : povray.binaries.images : Mdia interaction : Re: Mdia interaction Server Time
13 Nov 2024 20:25:15 EST (-0500)
  Re: Mdia interaction  
From: Alain
Date: 11 May 2004 18:46:14
Message: <40a157b6$1@news.povray.org>
Skip Talbot nous apporta ses lumieres ainsi en ce 2004/05/11 16:59... :

>The setup:  A cylinder intersects a sphere, both filled with scattering
>media.  However, when I use an empty density for the cylinder (removing all
>media) it still casts some sort of ghost in the sphere.  This effect is
>present no matter what density is used, and is problematic when you don't
>want the cylinder's seem present.  Is there anyway to remedy this problem?
>
>Skip Talbot
>
>//begin code
>#version 3.5;
>
>#include "colors.inc"
>
>global_settings {
>  assumed_gamma 1.0
>  max_trace_level 15
>}
>
>
>
>camera {
>  location  <0.0, 0.5, -4.0>
>  direction 1.5*z
>  right     x*image_width/image_height
>  look_at   <0.0, 1.0,  0.0>
>}
>
>sky_sphere {
>  pigment {
>    gradient y
>    color_map {
>      [0.0 rgb <0.6,0.7,1.0>]
>      [0.7 rgb <0.0,0.1,0.8>]
>    }
>  }
>}
>
>light_source {
>  <0, 0, 0>
>  color rgb <1, 1, 1>
>  translate <-30, 30, -30>
>}
>
>plane {
>  y, -1
>  texture
>  {
>    pigment {
>      checker
>      color rgb 1
>      color blue 1
>      scale 0.5
>    }
>  }
>}
>
>sphere {
>  0.0, 0.5
>  pigment { rgbt 1 }
>  interior { media { scattering {2,4} } }
>  hollow
>  translate 0.5*y
>}
>
>
>cylinder {
>  0*y,  3*y,  0.25
>  pigment { rgbt 1 }
>  interior { media { scattering {2,4}
>   density { } } }
>  hollow
>
>}
>//end code
>
>
>
>  
>
Diagnostic: You see the "surface" of your cylinder.
Cure: Bind the two shapes in a merge.
merge{
    sphere{...}
    cylinder{...}
    }
That way, you remove the surface of the cylinder where it's inside the 
sphere.
You may now want to use only one texture and density statement for the 
complete object.

Alain


Post a reply to this message

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