Hi Nick,
just one idea: Can you replace the particle system with something else.
So maybe it is strictly particle system related. (I'm assuming, that you
use osgParticle here)
Hi Sebastian,
You are right, that is the structure and the first thing I tried was
to attach it directly to the body but then I saw this artifact like
the particles following the model with delay. So I tried the update
callback. Now I am thinking to have the particles attached to the main
camera so they move with the view but here is again update callbacks
and such.
Thanks anyway !
Nick
On Thu, Dec 19, 2013 at 9:35 PM, Sebastian Messerschmidt
<[email protected]
<mailto:[email protected]>> wrote:
Am 19.12.2013 12:09, schrieb Trajce Nikolov NICK:
Sebastian, it was too early to be happy. Changing it to traverse
first then update didn't helped actually. On the windshield model
I have attached ParticleSystem that is actually delayed with the
windshield. Any other ideas?
I also tried to attach this directly to parts of the model but
same results.
It is about rain effect. This particle system is firing rain
drops on the windshield geometry and it suppose to move with the
car model, however it is delayed as it moves.
Sorry, I'm out of ideas here too. If I got you correctly you have
some group which represents a "body" and another one representing
the windshield with the particlesystem attached.
And you are updating the later with the update-callback.
I don't understand why the two groups must be disjoint. Can you
explain the reason for this? Are those two different render passes?
If you explain your structure a bit more in depth I maybe can
point to an alternative solution.
cheers
Sebastian
Thanks
Nick
On Thu, Dec 19, 2013 at 12:02 PM, Sebastian Messerschmidt
<[email protected]
<mailto:[email protected]>> wrote:
You're welcome
Thanks Sebastian. That was it. It did helped!
Nick
On Thu, Dec 19, 2013 at 11:53 AM, Trajce Nikolov NICK
<[email protected]
<mailto:[email protected]>> wrote:
Hi Sebastian,
that is actually a good idea to do the traversal first.
Let me try it first. Thanks !
Nick
On Thu, Dec 19, 2013 at 11:51 AM, Sebastian
Messerschmidt <[email protected]
<mailto:[email protected]>> wrote:
Am 19.12.2013 09:26, schrieb Trajce Nikolov NICK:
Hi Nick,
My first question would be: Why don't you simply
attach the windshield to the model ;-)
No seriously, I had those effects too, when
retrieving e.g. the ModelView matrix in callbacks.
The problem usually was gone whe doing the traverse
first and the get the matrices.
Maybe you can give it a try, or paste some of your
update-callback code here, so we can help.
So basically this:
void CameraUpdateCallback::operator()( osg::Node*
node, osg::NodeVisitor* nv )
{
osgUtil::CullVisitor* cv =
dynamic_cast<osgUtil::CullVisitor*>(nv);
if (!cv)
{
return;
}
traverse(node,nv);
osg::Camera& camera =
*cv->getRenderInfo().getView()->getCamera();
camera.getViewMatrix() ....
}
will yield different results than this:
void CameraUpdateCallback::operator()( osg::Node*
node, osg::NodeVisitor* nv )
{
osgUtil::CullVisitor* cv =
dynamic_cast<osgUtil::CullVisitor*>(nv);
if (!cv)
{
return;
}
osg::Camera& camera =
*cv->getRenderInfo().getView()->getCamera();
camera.getViewMatrix() ....
traverse(node,nv);
}
This at least solved problems in
multipass-rendering, where multiple cameras had to
be synced relative to each other.
Hope this helps.
cheers
Sebastian
Hi Community,
I have a simple scene of a car model with a
windshield (two separate models combined in
runtime). There is osg::MatrixTransform node on top
of the car that moves it around, and the windshield
is attached to the scene that also has
osg::MatrixTransform on top of it with an
UpdateCallback that copies the car's matrix.
( the real scene is a bit different but this is the
concept)
I am seeing the windshild has some delay in
following the car model while moving and at lower
framerates. I think I just tried everything but
always this is the same case
Any clue and hints?
Thanks a bunch!
Nick
--
trajce nikolov nick
_______________________________________________
osg-users mailing list
[email protected]
<mailto:[email protected]>
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
[email protected]
<mailto:[email protected]>
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
--
trajce nikolov nick
--
trajce nikolov nick
_______________________________________________
osg-users mailing list
[email protected]
<mailto:[email protected]>
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
[email protected]
<mailto:[email protected]>
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
--
trajce nikolov nick
_______________________________________________
osg-users mailing list
[email protected]
<mailto:[email protected]>
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
[email protected]
<mailto:[email protected]>
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
--
trajce nikolov nick
_______________________________________________
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