mine nous apporta ses lumieres en ce 24/07/2006 23:38:
> Hi, here is what I want to do: I have a cube (it could be a rectangle later
> on) and I have made it hollow and filled it with absorbing media and made
> the cube clear. the light source is above it. I want to progressively
> change the amount I am absorbing as I go away from the light. I want to
> absorb more light the further away I get from the light source. I figure I
> have to use a density_map but I'm not sure how to that for a cube (or
> similar) shape. I have done a density_map for a sphere with emitting media
> before. Thanks for any help. :)
>
>
>
You can use a simple gradient pattern. As your light is above the box, a
gradient y dencity_map{[0 rgb 1][1 rgb 0]} would be apropriate. Scale it
verticaly to slightly over match the hight of the box. If the box is 2 units
high, scale the gradient by 2.001 in the y direction to prevent the pattern from
starting to repeat at the top of the box. Translate it verticaly so that it
matches the base of the box.
--
Alain
-------------------------------------------------
BACHELOR: A man who never makes the same mistake once.
Post a reply to this message
|