Commit Graph

1903 Commits

Author SHA1 Message Date
fredb
620e71e800 Update MSVC 7.1 projects 2008-02-28 21:25:44 +00:00
mfranz
db2216848d don't reset visibility modifier in the M5SM case 2008-02-20 23:36:27 +00:00
mfranz
cfffe91ed5 Syd ADAMS: remove season suffix, this is now done via <condition>s 2008-02-16 22:09:40 +00:00
mfranz
a95aed1047 remove getRootNode(), as this resets the model root 2008-02-16 17:01:01 +00:00
mfranz
2883a36c76 Csaba HALASZ: implement conditional (e.g. seasonal) texture loading at startup 2008-02-15 17:54:01 +00:00
timoore
ac4245013f Cleanup of particles contribution
Put particles classes inside simgear namespace

Refactored some redundant code

Reworked local frame math to use OSG math classes as much as possible
2008-02-15 06:44:24 +00:00
timoore
b09e484492 particles from Tiago_G 2008-02-15 06:44:05 +00:00
timoore
dc63ddb010 Small cleanup of tree shader 2008-02-07 23:01:32 +00:00
timoore
09778a8eab Minor cleanup of Stuart Buchanan's tree patch.
Separate random objects and random trees for real.
2008-02-07 23:01:16 +00:00
timoore
8cbe9f1bd0 Second trees patch from Stuart Buchanan
Adds random variation of tree texture maps
2008-02-07 23:00:23 +00:00
timoore
be61689458 Cleanup and performance tuning of the random trees code.
The QuadTreeBuilder class was completely revamped as a templated class
to support flexible creation of scene graph quad trees, and a major
bug was fixed as well. Now it actually generates quadtrees instead of
some weird striped thing.

One StateSet is shared among all the "forests." The trees are drawn
after normal terrain objects to minimize some of the transparency
related artifacts.

Lighting was implemented in the ShaderGeometry shader (for both
polygon sides). Ambient-diffuse values for trees are hard-coded in
TreeBin.cxx.

DotOsg wrappers were added for ShaderGeometry so it can be output in
the scene graph dump.
2008-02-02 23:01:27 +00:00
timoore
4b63bc051e Random trees from Stuart Buchanan
Stuart's new file SGTreeBin.hxx has been split into 4 files:
TreeBin.[ch]xx and ShaderGeometry.[ch]xx.
2008-02-02 23:01:05 +00:00
timoore
a098ba5e79 Memory leak fixes from Till Busch 2008-01-24 23:05:18 +00:00
fredb
edee4b3fe5 Update MSVC 7.1 projects 2008-01-17 21:41:48 +00:00
timoore
0c9013e60e fix memory leaks in random object code
Don't allocate mt structures (for the random number generator) on the heap.
2008-01-17 08:28:15 +00:00
fredb
701c4bcf27 Avoid spitting gazillion 'Cannot find image file "" ' message on the console while loading random objects 2008-01-12 08:50:21 +00:00
frohlich
22f2fac56b Modified Files:
simgear/scene/model/animation.cxx:
	Change factor/offset order for texture animations.
	Fixes remaining bug with texture animations.
2008-01-07 22:05:48 +00:00
timoore
605125c0e7 Random object support from Stuart Buchanan
In addition to Stuart's changes, there's an independent quad tree
builder class for constructing loose quad trees from scene graph nodes.

Stuart also implemented changes to the random number generator suggested by
Andy Ross.
2008-01-06 15:04:43 +00:00
fredb
65d0ee126a Update MSVC 7.1 projects 2008-01-04 21:45:41 +00:00
fredb
4db6435090 Remove warnings 2008-01-04 21:45:14 +00:00
timoore
4383fd3c45 Give the sky a BACKGROUND_BIT nodemask
Add a MODEL_BIT and tag clouds with that.

Remove vestigial post_root from sky code.
2008-01-04 07:33:42 +00:00
timoore
b6be76b0ab background node mask 2008-01-04 07:33:23 +00:00
frohlich
92d8fa1193 Modified Files:
simgear/scene/model/SGClipGroup.cxx
	simgear/scene/model/SGClipGroup.hxx Update the clip group.
2007-12-31 15:49:01 +00:00
frohlich
9c51bf3edf Modified Files:
simgear/scene/model/animation.cxx: Create animation inputs if not
	already there. Fixes broken texture animations from past checkin.
2007-12-31 15:48:02 +00:00
frohlich
cf0e4e6f8c Modified Files:
Makefile.am SGPickCallback.hxx: add proirities for pick callbacks.
2007-12-26 19:19:51 +00:00
frohlich
c3719f35e3 Modified Files:
animation.cxx animation.hxx: Make use of the expression stuff.
	Factors out common code with other animations stuff in flightgear.
2007-12-26 19:12:04 +00:00
frohlich
0b1f074bcf Modified Files:
Makefile.am
Added Files:
	SGExpression.cxx SGExpression.hxx: Add not yet complete but already
	usable expression tree. Will be used with the panel code.
2007-12-26 19:10:40 +00:00
frohlich
7fe8514434 Modified Files:
scene/model/SGClipGroup.cxx: Oops, add missing simgear_config.h
2007-12-26 19:08:45 +00:00
frohlich
37c4dcf8ba Modified Files:
Makefile.am
Added Files:
	SGClipGroup.cxx SGClipGroup.hxx: Add helper group node for reuse
	of clipping planes. Will be used for the panel code.
2007-12-26 19:05:06 +00:00
frohlich
e33dd3c499 Modified Files:
simgear/props/props.hxx: Add a bunch of convinience functions.
2007-12-26 19:03:21 +00:00
timoore
94be52886e Pass ReaderWriter options to SGMaterialAnimation
It needs to grab the path list from options in order to support the texture
change animation.
2007-12-23 23:33:04 +00:00
timoore
6646aa5644 Fix tiny bugs in sun constructor and repaint code 2007-12-22 23:01:36 +00:00
timoore
d556eba296 Add StateAttributeFactory files to VS project file 2007-12-21 06:29:36 +00:00
timoore
a5b573b2d3 optimize groups from .AC file optimizer run 2007-12-21 06:25:40 +00:00
timoore
18d30ea8fa Repaint 2D cloud layers using texture combiner
Don't change the color in the cloud layer geometry
2007-12-21 06:25:13 +00:00
timoore
4324ffccf4 Fix cloud layer - point lights visibility issue
Move point lights to render bin 8, clouds to render bin 9. Turn on
AlphaFunc for cloud layers.

Create a StateAttributeFactory object to create and share common state
objects.
2007-12-21 06:24:53 +00:00
fredb
182ee9d7e4 Update MSVC 7.1 projects 2007-12-18 22:25:24 +00:00
timoore
68c1cfed46 Use node masks and shared state sets to manage ground lights
Do away with the switch in each terrain tile for the ground lights. They are
turned on by node masks now.

Share state sets among all the light nodes and manage the fog values through a
"GroundLightManager" instead of having separate state sets and callback
functions for each group in each tile.
2007-12-13 23:30:24 +00:00
timoore
1159784538 minor fix to ModelRegistry and syntax changes for Windows
Create the local path in the right order in OptionsPusher. When
OptionsPusher is used, put it inside a new code block so the order of
destruction with respect to the mutex on reader functions id clear.

Add #include <algorithm> to top of ModelRegistry.cxx.

Change include syntax in PathOptions.cxx
2007-12-11 11:07:21 +00:00
timoore
e683b5fdec Check for null options before changing path in registry 2007-12-10 08:30:43 +00:00
timoore
3c409c5070 Work around osg Registry path list problems
The OSG reader plugins overwrite the path list passed in options with the local
directory of the file being read, forcing you to set the path list in
the Registry. I think this a bug, but in the meantime here's a workaround.
2007-12-09 22:38:10 +00:00
timoore
4b7361dfe7 Add operator!= to SGBucket 2007-12-07 23:35:04 +00:00
timoore
037d5c11a5 Add option to SGLoadTexture2D to load dynamic textures 2007-12-07 09:13:34 +00:00
mfranz
95d857e091 - comparison: don't crash if second element is missing
- better messages ("panel"?!)
2007-12-06 17:57:41 +00:00
timoore
4efa087cd1 Don't modify OSG Registry with file path
To set a path when loading model files, use an osg ReaderWriter::Options object.

Put locks in ModelRegistry::readNode and ModelRegistry::readImage to avoid
conflicts when files are loaded from both the pager and the main thread.
2007-12-04 22:38:40 +00:00
fredb
60f0003436 Update MSVC 7.1 projects 2007-12-02 12:28:30 +00:00
timoore
fdb265cd6e Change the main ModelRegistry callback function to stash the substituted file in the cache. 2007-11-29 23:56:49 +00:00
timoore
34704a17f2 Avoid copying drawables and dirtying display lists.
For the alpha-test animation, use an OVERRIDE attribute on the state
set of the top level node instead of copying drawables and state sets
throughout the model.

As a temporary hack in the blend animation, don't use display lists in
the cloned drawables.

These changes are aimed at cutting down the number of display lists
that the pager needs to compile.
2007-11-29 23:56:31 +00:00
timoore
4a959ec2fd rewrite ModelRegistry callbacks as a template with pluggable policy classes
In a big effort to improve use of the object cache, provide a
ModelRegistryCallback template class with different policies for
substitution,  caching, optimization, etc.

Change SGTexDataVarianceVistor to make StateSets static too.
2007-11-29 23:56:09 +00:00
timoore
f182886fce Start of cleanup of scene graph node masks 2007-11-29 23:55:35 +00:00