POV-Ray : Newsgroups : povray.general : How to make object be transparent with alpha channel in the final image? : Re: How to make object be transparent with alpha channel in the final image? Server Time
31 Jul 2024 12:19:16 EDT (-0400)
  Re: How to make object be transparent with alpha channel in the final image?  
From: Zeger Knaepen
Date: 11 Sep 2007 16:41:52
Message: <46e6fd90@news.povray.org>
something like this: (there's still a problem: for some reason the scene is 
upside down or mirrored, I'm not sure)

#version unofficial MegaPOV 1.2;
light_source {
 <500,500,-500>
 rgb <1.5,1.4,1.3>
}
light_source {
 <-500,-500,-500>
 rgb <.4,.5,.9>
 shadowless
}
union {
 torus {
  1.5,.25 rotate -x*45 translate -x
  pigment {rgb <1,.2,.1>}
 }
 torus {
  1.5,.25 rotate x*45 translate x
  pigment {rgb <.1,.2,1>}
 }
 translate z*10
}

union {
 torus {
  1.5,.25 rotate -x*45 translate -x
  pigment {rgb 0} finish {ambient 1 diffuse 0}
 }
 torus {
  1.5,.25 rotate x*45 translate x
  pigment {rgb 1} finish {ambient 1 diffuse 0}
 }
 translate z*10
 rotate y*180
 no_shadow
}
#macro Quad(P1,P2,P3,P4)
 triangle {P1,P2,P3} triangle {P1,P3,P4}
#end
mesh {
 Quad(<0,0,0>,<0,1,0>,<0,1,1>,<0,0,1>)
 pigment{
  pigment_pattern {camera_view{location 0 look_at -z}}
  pigment_map {
   [0 rgbt 1]
   [1 camera_view{location 0 look_at z}]
  }
  rotate -y*90
 }
 finish {ambient 1 diffuse 0}
 translate x*500
 translate <0,-.5,-.5>
}
camera {
 orthographic
 location 0
 right x
 up y
 look_at x
}


Post a reply to this message

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