76
Support / Re: Single Object3D (addTriangle) or Vectors of Object3D Primitives?
« on: April 17, 2007, 03:48:33 pm »
Just a note on what you are looking at:
The lightning bolt is using 2 Object3D's each with two triangles. One is on the X/Z plane and the other is on the Y/Z plane (a long "plus"). Obviously they are rendering textures with transparency. The textures are toggled with every paint cycle so it looks very dynamic. I also allocate a number of Light objects along its length which gives it a strobe effect you can't see in the screenshot.
Because you can set the tiling properties for the texture placement you can easily add more "bolts". Here there are only 2 - ie. no tiling and one on the vertical plane and one on the horizontal. I tested 4 and 5 on each plane.
Anyway - it looks great animated and doesnt hit the framerate at all really. The "node" system uses the same math for vector origin and target but only works on the X/Z plane. Its surprisingly smooth when you draw the lines realtime - they "chase" the mouse very smoothly elongating and pivoting.
The lightning bolt is using 2 Object3D's each with two triangles. One is on the X/Z plane and the other is on the Y/Z plane (a long "plus"). Obviously they are rendering textures with transparency. The textures are toggled with every paint cycle so it looks very dynamic. I also allocate a number of Light objects along its length which gives it a strobe effect you can't see in the screenshot.
Because you can set the tiling properties for the texture placement you can easily add more "bolts". Here there are only 2 - ie. no tiling and one on the vertical plane and one on the horizontal. I tested 4 and 5 on each plane.
Anyway - it looks great animated and doesnt hit the framerate at all really. The "node" system uses the same math for vector origin and target but only works on the X/Z plane. Its surprisingly smooth when you draw the lines realtime - they "chase" the mouse very smoothly elongating and pivoting.