POV-Ray : Newsgroups : povray.programming : customized dispersion Server Time
18 Apr 2024 12:43:52 EDT (-0400)
  customized dispersion (Message 1 to 1 of 1)  
From: AaronD
Subject: customized dispersion
Date: 18 Feb 2008 23:20:00
Message: <web.47ba58b7d8fcdd0c256ade900@news.povray.org>
Hello,

This question about dispersion was in the advanced users group, but may be more
applicable to the programming group.  How hard would it be to implement the
following?  And should we look at photons.cpp to access dispersion?

Thanks so much for your help in advance.
-Aaron

ORIGINAL QUESTION
>I want to specify the index of refraction for each color, in the number of steps that
I specify (just as with dispersi
on) only in a customized way, for example:

n=2 for red part of spectrum
n=1 for middle part of spectrum
n=3 for violet part of spectrum

Since I cannot do this with the dispersion property, how can I do this? This
looks like it should be very easy to implement, given that POV-Ray can already
handle normal dispersion.  I just need to access the array where the indices
are held, if that is how dispersion works.

PRELIMINARY SUGGESTION -- NEED HELP
>The 3.7 beta source code is available now so I gave it a look and found it's
done (at least in part) in source\ backend\ lighting\ photons.cpp so thought
I'd mention that. And I'm guessing that might be an easier read than
previous source code, not that I know that for sure either but that's what I
hear.

Didn't look trivial to use more than a single ior, but I don't know the
coding at all. That's what the povray.programming group would be for, or
someone else might have more to say here.
--
/*bob hughes*/


Post a reply to this message

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