Re: [Celestia-developers] Planetshine patch
Real-time 3D visualization of space
Status: Beta
Brought to you by:
cjlaurel
From: Steve P. <car...@ya...> - 2008-04-01 23:23:08
|
I just noticed that solarsys.cpp had a windows/dos end of line and I changed that to unix. That one worked but the frametree files were already unix end of lines and they still don't work. cartrite Steve Popovich <car...@ya...> wrote: Yes, R4232 The patch did have an End of line = dos/windows and I changed it to unix but that didn't help. cartrite Chris Laurel <cl...@gm...> wrote: That's very strange. You have the latest code from SVN, right? I wonder if there's a line ending incompatibility? --Chris On Tue, Apr 1, 2008 at 4:05 PM, Steve Popovich wrote: > I was unable to apply the patch because frametree.cpp, frametree.h, and > solarsys.cpp were rejected. > cartrite > > > Chris Laurel wrote: > One other quite important item: > > The planetshine effect is toggled by Ctrl+X (antialias lines). The > toggle is just there for testing and will be removed when the code is > committed to SVN. > > --Chris > > > On Tue, Apr 1, 2008 at 12:28 PM, Chris Laurel wrote: > > Here's a rather large patch that implements secondary illumination in > Celestia: > > > > > http://www.shatters.net/~claurel/celestia/files/patches/planetshine/planetshine.patch > > > > The patch includes a significant cleanup and streamlining of > > Celestia's lighting code; it simply wasn't practical to implement > > secondary illumination /without/ this cleanup. The performance > > benefits from this cleanup should more than compensate for the extra > > computation required for secondary lighting. > > > > I've worked hard to make Celestia's implementation of secondary > > illumination both fast and general. Secondary illumination can come > > from objects that aren't in the same 'system'. Thus the Cassini > > spacecraft can be lit by light reflected from Earth, Venus, Jupiter, > > Saturn, or any of Saturn's moons even though its orbit is defined > > relative to the Sun. This is different how eclipse shadows work: > > they're currently only computed for objects in the same system, and so > > Cassini will never be eclipsed by Saturn (at least, not until a > > subsequent patch addresses the limitation.) > > > > Both reflector phase and reflector-to-receiver distance are accounted > > for in the calculation of secondary illumination. There are two ways > > in which distance affects the amount of light reaching the receiver: > > obviously, the received energy falls off with 1/distance^2. But, the > > distance also affects what part of the reflecting object is visible to > > the receiver. An object in low Earth orbit like ISS sees only a small > > fraction of the Earth's surface at one time, thus using something like > > a simple (1+cos(phase))/2 correction to the amount of reflected light > > will produce noticeably wrong lighting. The code in the patch uses a > > more sophisticated approach that is still an approximation but gives > > correct looking results in all cases. > > > > Some limitations: > > - All reflecting objects are treated as spheres > > - Spacecraft, components, and surface features don't reflect light; > > this was done in order to avoid terrible slowdowns with add-ons like > > Selden's Hale telescope that have complex assemblies of small models. > > And with a mass of irregular objects, the lighting wouldn't be correct > > anyway. > > - Only the brightest secondary illuminator is considered. This is easy > > to fix, but at the expense of performance. It's probably not > > worthwhile until HDR support lets us see the effects of very faint > > light sources. > > - You'll note that Earthshine isn't visible on the Moon; there's an > > adjustable 'gamma' setting that would make it visible. Right now, it's > > set so that secondary illumination will be visible when it is at least > > 10^-4 times as bright as the primary illumination. Earthshine on the > > Moon is just barely under the cutoff. This gamma value can be > > modified, but at the expense of underemphasizing light intensity > > differences between more similar light sources. My feeling is that we > > should wait for HDR rendering to be more developed before playing with > > this value too much. > > > > The best places to see planetshine are spacecraft in low orbits or > > doing low-altitude fly-bys. The Martian satellites and inner moons of > > the giant planets also show off the effect nicely. > > > > One other thing that this patch addresses is orbit visibility for > > barycenters. People often complain that the orbit of Pluto is no > > longer visible now that it's defined as relative to the Pluto-Charon > > barycenter rather than the Sun. In the process of implementing > > secondary lighting, I had to introduce an 'object type' mask for frame > > tree nodes. The mask contains the types of all objects that are > > children of the node. With a small change to the orbit code, the mask > > is used to render the orbit of a barycenter when planets or moons > > orbit it. > > > > --Chris > > > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > _______________________________________________ > Celestia-developers mailing list > Cel...@li... > https://lists.sourceforge.net/lists/listinfo/celestia-developers > > > > ________________________________ > You rock. That's why Blockbuster's offering you one month of Blockbuster > Total Access, No Cost. --------------------------------- You rock. That's why Blockbuster's offering you one month of Blockbuster Total Access, No Cost.------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace_______________________________________________ Celestia-developers mailing list Cel...@li... https://lists.sourceforge.net/lists/listinfo/celestia-developers --------------------------------- You rock. That's why Blockbuster's offering you one month of Blockbuster Total Access, No Cost. |