Quad Particles

BlitzMax Forums/OpenGL Module/Quad Particles

Clyde(Posted 2005) [#1]
This I adapted from SimonH example with BMAX.
And want to have the particle effect work with OpenGL. So I firstly wrote it into B3D (which works great), and attempted to implement it with BMAX.

However it behaves very oddly, and I feel im doing allsorts of mistakes. Please could you help me fix it;? thanks.



Huge Thanks,
Thumbz.


Clyde(Posted 2005) [#2]
Any luck please?


Clyde(Posted 2005) [#3]
Ive had another bash and no luck, does anyone know what is wrong with it?

Mega Thanks,
THUMBZ


col(Posted 2005) [#4]
First thing is the camera is directly on top the fireworks, ie the fireworks and camera are at the world origin 0,0,0 !!

Is this a program you wrote yourself or are you porting to BMAX?

Regards


Clyde(Posted 2005) [#5]
It's a mix of porting a way I'd do it in B3D (which works), and inspired by SimonH's firework example.

How would the camera position effect it?


col(Posted 2005) [#6]
Do you have the original source to hand??

'How would the camera position effect it?'

The same way it effects everything in 3d. Try setting the quads at a z of -200 and set the far clip at about 1000.0 :

gluPerspective (45.0,Float(XRES)/Float(YRES),0.1,1000.0)

you can see something happening, but im not sure what your supposed to be getting.

Oh and you don't appear to be setting up any matrix's to tranform your geometry. It's like you only have half of the 3d code thats needed. If you post the original source I can help you get it working properly.

Regards


N(Posted 2005) [#7]
Uh.. sortof works.

Not exactly interested in fixing everything.




xlsior(Posted 2005) [#8]
Doesn't seem to work at all in debug mode:
Unhandled Exception: Attempt to access field or method of Null object


N(Posted 2005) [#9]
Found the problem with that bit.




Clyde(Posted 2005) [#10]
Thanks mate, what was it that you added? The GLPopMatrix?, and what else was wrong with it?

I'll work out the rest, thank you so much