Currently I am focusing almost exclusively on web programming languages but I do still enjoy C++, as it was the language in which I built most of my early programming skills. This index page provides a gateway to all my C++ themed articles and projects.
Markov Chain for Language Approximations
One of my more interesting C++ projects was a language analyzer that built a statistics database about word usage by "reading" supplied pieces of text. The program could then use the database to try to "write" its own passages of text. I thought this fascinating piece of code was something new and interesting, but then I found out that it had already been thought of in 1913, and had been first implemented in code in 1984.
Read more about the Markov Chain....
Mac OS X SDL Game Engine
I have programmed a number of game engines over the years, first using "screen mode 13", that ancient 320x200 pixel screen mode favored by early DOS games. Later I moved on to Direct X. My most recent game engine runs on Mac OS X using SDL. It uses Danc's Miraculously Flexible Game Prototyping Tiles, and includes soft shadows.
I started out using the PTK graphics engine, but I was very unhappy with the lack of flexibility that it offered. The graphics engine was too "dumbed down."
So I switched to SDL, which gave me lower level hardware access and allowed me to mess around with the video textures at a closer level. This allowed me to fine tune some aspects of the engine and gave me a major speed boost.
After a bit more development I made a small proof of concept demo which has a small character who can not only walk around but also completely modify his world by picking up tiles and moving them around.
This might make a cute game someday, if I ever have time to get back to it.
Experiments With the Linked List
In addition to reinventing the Markov Chain, I also reinvented some improvements on the base linked list concept taught in your traditional C or C++ primer. In short I reinvented the double linked, unrolled, iterator linked list.
First I posted an article detailing my theoretical improvements on the linked list. Basically my goal was to increase access speed by storing more data in each link and providing a built in pointer to the last accessed link. Usually linked lists are iterated via a for or while loop structure and therefore it is not efficient to handle each data request by starting at the beginning of the list and jumping from link to link trying to find the destination link. Basically I added extra logic and an extra "last used" pointer so that I could reduce the number of time consuming "link jumps" that were required.
While that is all very good in theory how does it work in practice? I did some tests to find out and released a performance analysis of 38 linked list variations compared with STL linked list classes. At the risk of ruining the suspense I will say ahead of time that my customized class was faster in all respects when compared to STL.
Miscellaneous Coding Articles
The Facts Behind the Code Indentation Style War
Optimizing Traversal of Multi-Dimensional Arrays
Setting Up a Mac OS X SDL Development Environment
How to Load an Resource from a Mac OS X Application Bundle
Translating a Mouse Position Over an Isometric Tile Grid into Tile Coordinates
Bedtime Reading About C and it's Derivative Languages:
Taste great books and share them with your friends: Bookflavor
You should try Duck Duck Go, the better search engine that protects your privacy.
Be the first to reply!