POV-Ray : Newsgroups : povray.general : Colour from single trace : Re: Colour from single trace Server Time
25 Apr 2024 14:57:40 EDT (-0400)
  Re: Colour from single trace  
From: clipka
Date: 28 Oct 2018 07:25:14
Message: <5bd59c9a$1@news.povray.org>
Am 27.10.2018 um 13:16 schrieb Paul Bourke:
> I am aware of the trace macro that returns the intersection point and normal at
> that point on a object given a ray (point and direction). But is there a way to
> get the colour?

If by "colour" you mean apparent colour (as it would appear in the 
output image), the answer is a clear "nay".

If by "colour" you mean pigment, the answer is "well, sort of"; you can 
use the `eval_pigment` function Bald Eagle mentioned already, but you'll 
have to separately keep track of transformations and stuff, POV-Ray 
doesn't do that for you. Also, `eval_pigment` doesn't work with pigments 
that depend on properties of the object surface, the ray, or interaction 
betweent the two, such as pigments using the `slope` or `aoi` patterns.


Post a reply to this message

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