Effects and Multitexturing

From World Wind Wiki

(Difference between revisions)
Jump to: navigation, search

Stepman (Talk | contribs)
(created initial page)
Next diff →

Revision as of 10:09, 24 August 2006

[edit] Effects in World Wind

Effects can be added at runtime to any QTS layer by opening its properties window and setting its EffectPath property (try shaders\grayscale.fx). They can also be specified directly in the XML file:

 <QuadTileSet ShowAtStartup="true">
   <Name>Effects Test</Name>
   <Effect>shaders/testshader.fx</Effect>
   <DistanceAboveSurface>0</DistanceAboveSurface>
   ...

The way in which parameters are passed to the effect is not yet defined in detail.

[edit] Multitexturing

Multiple textures can be assigned to a single QTS simply by using multiple ImageAccessor statements in the XML file:

 <QuadTileSet ShowAtStartup="true">
   <Name>Multitexturing Test</Name>
   ...
   <ImageAccessor>
     ...
   </ImageAccessor>
   <ImageAccessor>
     ...
   </ImageAccessor>
   ...

The number of levels and level zero tile size must be the same for all instances. It is possible to use multiple WMSAccessors or ImageTileServices as well, although this hasn't been really tested yet.

Note that without shaders this is fairly useless as the default setup only uses the first texture for rendering.

Personal tools