On Wed, Jan 11, 2012 at 8:09 AM, Thorsten Renk wrote: > I have now a scheme that does seem to do the trick - high stuff and stuff > towards the sun glows properly before lower stuff and stuff away from the > sun. > > http://www.flightgear.org/forums/viewtopic.php?f=47&t=14755&start=15#p147240
Very beautiful! > The idea is: > > * compute the relative vector between eye position and vertex > * get its z-component as altitude difference > * pass the eye position altitude as uniform > * add eye altitude to relative altitude - this is the uncorrected vertex > altitude > * use the known distance to correct for curvature to get the actual > altitude (it's probably off by a few percent, but who cares?) Rather than passing in the eye position as a uniform, why not pass in the cloud altitude instead? Is this simply to avoid needing to modify the C++ code? -Stuart ------------------------------------------------------------------------------ Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox _______________________________________________ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel