It's been a while I haven't do anything with Augmented Reality (AR). But, recently I was tempted by a thread in openframeworks forum for dealing again with code - related to the AR.
It is fun seeing the work done by Georg Klein - a project named PTAM - Parallel Tracking and Mapping for Small AR Workspaces that has been presented in ISMAR 2007. Really cool! Awesome!
Moreover, you can download the C++ source code in here. But if you familiar with VC++ 2005, you can download the ready-to-compiled solution in here. It uses the 1394 camera; but if you don't have it, don't worry! you can use webcam and please enjoy the source code in here.