Learning SFML for C++

So, as I’m taking a C++ course this semester I’ve decided it’s as good a time as any to learn a media API for C++. Therefore, I’ve started learning SFML. I found SDL to be a bit much (since loading sprites is quite painful.) I’m currently working on an artillery-style game. I have some basic map generation working now. It generates a random 1D heightmap  and then uses a mixture of linear and cosine interpolation on those points to create a smooth surface. After, the entire terrain image is drawn to a texture and rendered to screen for fast drawing.

Created pixel-by-pixel from an interpolated height map

A video showing a few more seeds:

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s