In addition to the rotation ability for particles, this adds the ability to stretch particles based on their velocity in screen space and orient them along the velocity.
Forgot the serialization again, fixed.
Also forgot to put in view vector alignment attenuation.
This is the full patch which includes a very large set of changes and a modified per pixel lighting example as a testbed example.
Sorry, I've changed the particlescenenode implementation now somewhat without applying your patch first. That does not mean that I don't like the patch - it looks very good and useful! The reasons I didn't get to it were:
- It needs a test first for the new vector rotation (won't need long to write, I just have not enough time for now)
- I think we should implement stuff like point-particles first before thinking about other rotations as this things affect each other.
- Your implementation of CParticleEmitter is really good and probably the way I would write it in a new engine. But Irrlicht-style in similar situations (videodriver, irrlicht-device) is to use multiple-inheritance. So to keep the engine-code easy readable we should continue to use the same style instead of templates in such classes.
No need to update the patch - I think when one of use continues working on particles it's still easy to adapt your patch the way it is now.