Domanda

I need to draw a Cartesian plane (standard OXYZ), where i would construct planes from equations ax+by+cz+d=0 and some objects.

How can i do that via OpenGL? Anybody?

È stato utile?

Soluzione

You need to create triangle or quad. Calculate points in plane using your equation and from those points construct geometry.

For rendering geometry, look for some tutorials. There are plenty of them around.

Altri suggerimenti

If I am interpreting your question correctly, you just want to draw the axes of the Cartesian planes xy, xz, yz.

You can achieve this very easily by drawing a non-solid cube (glutWireCube should do the job), such that its bottom-front-left corner is at (0,0,0) (or bottom-back-left corner, based on the direction of positive depth).

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top