Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


How to fill my terrain!

This topic is 5977 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Ì´ve made a simple terrain engine. The problem is that I use Trianglestrips and by that not every piece of ground is presented. I have a pic. here so you can see for yourselves. http://www26.brinkster.com/shakazed/index.html I sure hope there´s some easier way to handle this than defining every vertex manually. Any help appreciated!

Share this post

Link to post
Share on other sites
Use a vertex buffer and an index buffer so that when your second strip calls on the first vertex (that is actually a vertex used in the second line of the first strip) then it will use the exact same vertex. It looks like when a new strip starts you use totally new random vertices when they should be connected to the last strip''s close vertices.

Share this post

Link to post
Share on other sites
Guest Anonymous Poster
I once had a similar problem, turned out that i was using the wrong height values for one side of each strip.

I should have been using height values at
(x,z) (x,z+1) (for the two sides of the strip)


(0,0) (0,1)
(1,0) (1,1)
(2,0) (2,1)
(3,0) (3,1)
(4,0) (4,1)

BUT I was using: (x,z) (x+1,z)

and getting

(0,0) (1,0)
(1,0) (2,0)
(2,0) (3,0)
(3,0) (4,0)
(4,0) (5,0)

But that''s coz I''m a bit stupid, you might not be

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!