PDA

View Full Version : delete some vertex points from image



Vincent Monet
11-01-2010, 01:11 PM
I plotted a function using OpenGL, the problem now is with discountinous functions.

A function in 3D such as 1/x is discountinous at 0, but the graph joins the points across the discontinuity.

I can identify these points and if I was using immediate mode just not render those vertices, but I used vertex arrays, so how would I about deleting a set of points this way?

I thought just to colour them same as the background so they donīt show up, but I used a 1D texture for the colours, any suggestions on how this could be done?

Thanks.
http://b.imagehost.org/0179/snapshot2.png

carsten neumann
11-01-2010, 03:18 PM
If you could skip the values in immediate mode, can you skip them when filling the vertex array?
Or you could use an index array to select a subset of the vertices in your vertex array.