Use a spotlight

From JReality Wiki
Revision as of 14:10, 10 June 2009 by Gunn (Talk | contribs)

(diff) ←Older revision | view current revision (diff) | Newer revision→ (diff)
Jump to: navigation, search

Source file: SpotLightDemo

JavaDoc: SpotLight


Run as Java webstart


This example show how to add a spotlight to your scene.


How to use the demo: When the cursor is over the red cylinder representing the spotlight, dragging with left mouse button depressed will rotate the spotlight. If the cursor isn't over the red cylinder, such dragging will rotate the whole scene.


Look in the code to see how the default lights are first removed from the scene graph so that only the spotlight effects the shading.


Spotlight-01.png


Previous: Write a texture dragging tool Developer Tutorial: Contents Next: Use the mouse-over input slot