PDA

View Full Version : Help me about 3D polyline in OpenGL



04-18-2002, 12:40 AM
Hi all,

I am OpenGL beginner and my English is not good. I have exported a DEM file to my own xyz file format that contains huge number of xyz polylines. I would like to use OpenGL to display them. I am OpenGL beginner so that I do not know where I should begin.

If you can help me, Please mail me thanhnt@zapo.net.

Thank you in advance.

mphanke
04-18-2002, 05:42 AM
Hi,

okay, if I get it right you have a number of points (x, y, z). What I would try first is to load the data into a list. From there I would setup a second list from where you index the order of vertices to draw.

so if you draw it would be like that:

1. Horizontal lines



.---.---.---.
.---.---.---.
.---.---.---.
.---.---.---.


2. Vertical lines



I---I---I---I
I---I---I---I
I---I---I---I
I---I---I---I


3. Display


But first of all you might want to try with a smaller grid. If it works for one grid and a second bigger grid, it will work for all grids!

Greets,

Martin

thanhnt
04-18-2002, 07:06 PM
Thank you for your helps
Thanh