Fork me on GitHub
Not signed in (Sign In)

Welcome, Guest

Want to take part in these discussions? Sign in if you have an account, or apply for one below

    • CommentAuthordigijin
    • CommentTimeDec 17th 2009
     
    I'm trying to add particle effects to a 3d papervision game im making and I am trying to figure out how to use particles in a scene with objects. I have seen a lot of examples about flint in pv3d but I cant find any that involve 3d objects as well. the flint renderer seems to act like the PV3d viewport, in that you attach the renderer to the scene which confuses me, if you're using flint and objects in pv3d do you attach the viewport and renderer to the stage?

    is there any examples of people using flint to make particles in a scene with papervision objects in it? like a box on fire or something, just so I can see how to use the renderer with the scene, because from the examples i've seen i cant figure out how.

    thanks for your time!
    • CommentAuthorRichard
    • CommentTimeJan 5th 2010
     
    Hi

    Flint's Papervision renderers don't actually draw any objects - the name is a bit of a misnomer. However, they are responsible for ensuring that the particles are drawn correctly. The flint renderer takes a DisplayObjectContainer3D as a parameter in its constructor. Then, whenever flint creates a particle, the renderer adds an object (an instance of the particle's image) to this DisplayObjectContainer3D. And every frame thereafter, the renderer updates the position, rotation etc. of this image to reflect the position, rotation etc. of the particle. So the image object becomes a representation of the particle in the 3D scene. It's still up to papervision to draw the scene, using a viewport etc.

    So all Flint is doing is creating some 3D objects, adding them to the scene, and managing their state. Everything else is up to the Papervision3D engine.

    Richard