Hi,
Sorry to have dropped this on the floor; I missed your response below. I took
a look at your examples, especially the one that is now broken. I see that what
you were doing is quite similar to what the September patch does: construct
a frame of reference for the ModularEmitter that is relative to ParticleSystem
frame, even though it is rooted to the global frame in the scene graph. You end
up doing the particle creation calculations in a frame that doesn't blow out
float precision. The September code makes the assumption that the ModularEmitter
and ParticleSystem are both in "real" coordinate frames, which seems reasonable
to me.

Both our methods require that the ParticleSystem be placed and moved to avoid
precision errors. In FlightGear I manually change the coordinates of the 
particles
when the ParticleSystem is moved. I suppose you might be able to get around this
in some situations by playing with the velocity vector of the emitted particles,
but I like my approach better because the ModularEmitter
does not need to be managed; it can simply be attached to the object from which 
the
particles are emitted. I recommend that you attach the ModularEmitter to your 
model.

Jolley, Thomas P wrote:
> So, where does that leave us?  What breaks by reverting the September
> changes on ModularEmitter.cpp?  Do you have an example of your usage?
> 
> Traversing the hierarchy to get double precision world matrices and
> applying it to single precision particle systems causes precision
> problems for my usage.  Reverting the change helps me.
One of the changes I made was to do the emitter particle placement calculations
in double precision. In any case, someone has to manage the particle system
so that the results will fit in single precision variables.

Tim
> 
> ----
> Tom Jolley
> 
> 
>> -----Original Message-----
>> From: Tim Moore
>> FYI, my change wasn't intended to solve particle precision 
>> problems by itself, merely support an approach where the 
>> particle system is not rooted in the world frame of 
>> reference. Application management of the particle system 
>> transform is still needed. Before my submission that seemed 
>> to be broken.
>>
>> Tim
>>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> 

_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to