Quote:Original post by karx11erxIt looks like you're using 1-bit transparency. Just use 8-bit transparency like with your explosion sprite on that same image, and the smoke will look 10 times better already.. And make them more transparent.
http://www.descent2.de/temp/smoke1.jpg
How to create good looking smoke fx?
Quote:
Added sorting (quicksort with minimal data movement required) - completely kills framerate. :(
I don't think quicksort is a good choice. Sure, its expected performance is good (n*ln), but it's really the worst performance you should consider (n^2) (because that's the one that will ruin the player's experience).
I personnaly prefer mergesort, its performance is always n*ln.
Quote:
I had to re-enable depth testing because otherwise smoke would appear in front of objects even if it was behind them
I think what was meant was that you should disable writing into the Z-buffer. But the depth test itself should not be disabled.
Edit:
I have a naive question: Where does this back-to-front rendering requirement for transparent layers come from? It does not matter in what order I stack yellow and blue transparent plastic sheets, they'll look green anyway, won't they?
If you render the transparent front texture first, the rearward texture will not be rendered at all if z-testing is enabled. That means you wont see anything behind your transparent texture ...
How do I disable z writes? (Yes, I am an OpenGL noob.)
How do I disable z writes? (Yes, I am an OpenGL noob.)
Quote:Original post by karx11erx
How do I disable z writes? (Yes, I am an OpenGL noob.)
glDepthMask(GL_FALSE);
Thx. Fast. :)
Re QuickSort: I have made sure QS is not applied for (almost) sorted particles. Still slow as hell. Actually I wonder why, sorting 4000 8 byte elements on an Athlon 3500+ 64 and good RAM shouldn't be an issue.
Re QuickSort: I have made sure QS is not applied for (almost) sorted particles. Still slow as hell. Actually I wonder why, sorting 4000 8 byte elements on an Athlon 3500+ 64 and good RAM shouldn't be an issue.
sorting 4000 elements is quite a bit, certainly not something u wanna do 60x a second.
why do u need so many, perhaps use fewer particles but make them bigger
i think the max num of particles i sort is something like 250 in a particle group
why do u need so many, perhaps use fewer particles but make them bigger
i think the max num of particles i sort is something like 250 in a particle group
i can't see your images, but to make a simple smoke particle engine should not require many particles. now if you are making a nice system for a next gen game, then THIS IS NOT THE SMOKE YOU WANT, but this is a decent smoke system for you to use.
What i did is just made like 5-10 billboards of a rounder smoke texture that was black on all sides, kinda like this: (Note, your alpha channel should also look like this)
With those billboards, just make them start at around your particle emitter, and move in a general upward direction, slowly getting bigger, and maybe with some spin on them. then slowly have them fade away. Thats all there is to it. Animated textures, although somewhat nice, dont always look as nice as how much you waste with them like memory and processing.
What i did is just made like 5-10 billboards of a rounder smoke texture that was black on all sides, kinda like this: (Note, your alpha channel should also look like this)
With those billboards, just make them start at around your particle emitter, and move in a general upward direction, slowly getting bigger, and maybe with some spin on them. then slowly have them fade away. Thats all there is to it. Animated textures, although somewhat nice, dont always look as nice as how much you waste with them like memory and processing.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement