PDA

View Full Version : I want to plot 2*10^6 dots how to organise?



arm2arm
02-20-2004, 07:53 AM
I have a such a structure
class CStone{
float x, y, z;
int color;
float mass;
}
I have a data file with 2000000 particles.
I want to plot this particles and rotate, zoom in 3D space. How to do that via OpenGL?Is there some fast way to do?
Please help me.
Thank You.
Arman.

madmortigan
02-20-2004, 09:23 AM
It sounds like you need to do some serious stuff for space partitioning. However, ever before you get there, you need to be extra careful with the data structures you're using, because for this size of model, even minor problems can cause horrible slow downs.

Assuming you have done everything, and you're ready to consider drawing, how do you thing 2 million particles will look like on screen?

Possibly, something like this: http://astronomy.swin.edu.au/~pbourke/opengl/openglgallery/universe.html

You can probably get ideas for visualizing your data by looking at simulations in astrophysics/astronomy, like the one above.

The answer to your question depends on the requirements. As mentioned above, some sort of major space partitioning is in order.

mad