Crate Game Engine snapshot-20080313 Release

This is the first release of the Crate Game Engine after the rewrite.



Multithreaded C++: Part 1: Pthreads

Note that some of the details on volatile are out of date now - 2016-03-15



C++ Question of the Day: Volatile Keyword

Jon asks:



C++ Templates: Using Templates to Generate the Fibonacci Sequence

The follow code demonstrates a method for generating the Fibonacci Sequence at compile time. Since the sequence is generated at compile time runtime execution of retrieving a number is constant time.



Site Updates

I just updated the site with a new version of Drupal and am still working out some problems. Currently the image module doesn’t work correctly, so images will be missing. I’ll be tracking the updates to the modules and will get things back up as I can. In the meantime all the content is available.



Nobody Understands C++: Intro

This is going to be the first post of several, though I’m not sure how many just yet. The title of the post should be self explanatory, but I will elaborate. It is my strongly held belief that C++ is generally poorly understood and gets a bad rap because of this. It is also my belief that this is NOT the fault of C++, but rather the fault of old-school C++ developers who learned the language before the language was ratified in 1998.



Boost Preprocessor Metaprogramming and Intro to Templates Revisited

Say you come up with a clever idea for initializing standard container types (blatantly stolen from the C++0x Initializer List concept). It might looks something like the implementation below:



Boost::Spirit: A BNF Parser Generator

The boost spirit library allows for direct translation of a BNF grammar into C++ code which generates a parser at compile time. The following example, from http://spirit.sourceforge.net/distrib/spirit_1_8_3/libs/spirit/doc/introduction.html truly does this concept more justice than I could: BNF Example:



Ireland is in My Blood

It’s been now more than a year since we got back from our trip to Ireland, and sometimes I just think about going back there. I don’t know really how to describe it, but I feel like the country is a part of me now. I’ve been to most of western Europe but Ireland, and particularly the Donegal region, has affected me than any other country I have been to. You can read about our trip here, if you want to.



Copying a File in C++, The Easy Way

Just a few days ago I spent way too long looking at the boost libraries to see if there was a way of adapting a std::fstream to an iterator type. I didn’t find what I was looking for and did what I wanted a completely different way.