I am writing a program, that as input, I have a huge (10^6 elements) 3d mesh (with hexagonal shaped elements), and I want to realtime render it, but not as real-time as a game. It just can show the scene and rotate, zoom and pan. The most important point is, I don't need any special lighting nor any shadows. Also, the objects to render are static, and they do not move. My object hasn't any textures.

I've read about ray tracing methods, but I don't know if there is any good libraries for this purpose, or I have to implement everything by myself.

Thanks a lot.

  • 4
    \$\begingroup\$ Need a lot of parameters clarified before any meaningful answer can be arrived at. What is "huge?" By "mostly structured" do you mean it's triangulated, and by "cubic" do you mean cubic surfaces or just a bunch of rectangles? Pick a speed this has to run at, "not a game" doesn't help much but "interactive" or "strictly canned playback" would. What screen resolution do you need, 2048 or HD, NTSC etc? Is this textured, you don't have lights so color must come from somewhere. Finally, do you need realistic rendering or just something that looks like the model? \$\endgroup\$ Apr 7, 2012 at 20:36
  • \$\begingroup\$ Does 'cubic shaped elements' mean that your mesh is actually made up of voxels? Are you trying to render something like a minecraft voxel world? \$\endgroup\$
    – Samaursa
    Apr 8, 2012 at 1:45
  • \$\begingroup\$ @PatrickHughes: thanks for answer, I updated the question. \$\endgroup\$ Apr 8, 2012 at 5:58
  • \$\begingroup\$ @Samaursa: No, they are not in size of a voxel. I think each of them should be divided into voxels \$\endgroup\$ Apr 8, 2012 at 5:59
  • \$\begingroup\$ 10^6*10^6*10^6 elements = 1,000,000,000,000,000,000 elements. Is this the number of vertices? Definitely going to need an expected render time on that... \$\endgroup\$ Apr 8, 2012 at 9:57

1 Answer 1


How large is the mesh?

Modern graphics cards can render huge amounts of triangles very quickly. So one thing you could do is use an existing 3D engine and just plug your model into it. Another idea would be to take your model, convert it into a format that some renderer can use (e.g. a raytracer like POVray) and render it with that. But it all depends on the visuals you'd like to achieve. If reflections are important, raytracing surely is the way to go. If you just need a simple 3D visualization, go ahead with a 3D engine.

  • \$\begingroup\$ Thanks for answer, I updated the question about size of the mesh. \$\endgroup\$ Apr 8, 2012 at 6:01
  • \$\begingroup\$ Is there any libs or anything else like POVray written in java? \$\endgroup\$ Apr 8, 2012 at 11:12
  • \$\begingroup\$ A triangulated, hexagonal column with top and bottom caps has 24 faces. 24 million triangles isn't horrible for hardware acceleration, I'm unsure about raytracing so I'll leave that up to LTR who has the accepted answer already. \$\endgroup\$ Apr 8, 2012 at 15:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .