PDA

View Full Version : How to Create Terrain With DEM Heigth Data



senpaihurricane
12-14-2015, 07:27 AM
Hello to OpenGL community.

First of all i am beginner at OpenGL.

I have a DEM data which is look like;

14 25 45 55 68 70 84 91 97 101 105 105 105 105 120 120 120 120 120 120 120
5 18 43 62 73 82 88 94 99 102 105 105 105 105 120 120 120 120 120 120 120
5 18 38 56 69 77 86 94 99 103 106 105 105 105 120 120 120 120 120 120 120
5 9 31 48 60 71 81 87 95 101 106 105 105 105 120 120 120 120 120 120 120
5 5 18 37 49 56 62 81 91 94 101 105 105 105 120 120 120 120 120 120 120
5 5 12 23 34 40 53 66 77 82 97 103 105 105 109 120 120 120 120 125 125
4 5 8 15 20 24 35 39 40 77 92 101 104 104 105 120 120 120 125 125 125
5 7 22 36 46 48 48 44 50 58 80 96 96 97 106 120 120 125 125 125 125
4 15 31 46 61 68 69 63 53 50 67 82 84 103 108 120 120 125 125 125 125
4 12 31 46 64 78 82 80 69 54 73 71 92 105 108 120 120 125 125 125 125
6 26 35 45 63 75 84 87 84 74 77 80 96 103 108 120 120 120 125 125 125
21 30 46 57 64 76 85 92 92 87 79 80 86 102 106 120 105 120 125 125 125
27 40 48 62 75 84 92 96 97 94 88 80 80 91 104 105 105 105 120 125 125
33 43 55 65 75 87 96 101 101 101 97 92 80 80 98 105 105 105 105 120 125
45 50 58 68 80 91 99 102 105 105 105 99 90 80 80 97 105 105 105 120 100
50 60 65 71 84 95 101 105 105 107 107 106 102 101 92 80 98 104 105 100 100
60 70 76 83 88 96 103 106 107 108 120 109 108 108 106 101 90 100 100 100 100


I want to create a terrain with use glVertex3f function. How can i do that?

Thank for your interest.