Main contents
Archive for the 'c++' Category
July 6th, 2008
Spent some time exploring Lua. This language has caught my interest, not least because Lightroom is largely implemented in it. I’ve played around with it briefly before on Linux, and I have to admit that the experience of getting it up and running is much less painful on Ubuntu than on Windows. $ apt-get install lua is much faster than downloading tarballs, creating visual studio solutions from scratch, mucking around with paths and dependencies and resolving any number of LNK2005 errors. But I got there in the end. Specifically, I
- Downloaded the Lua source from Lua.org.
- Created a Visual Studio DLL project containing all the source files apart from lua.c and luac.c
- Built this DLL to create lua.dll
- Created another project with just lua.c, and linked to the above DLL
- Built this project to create lua.exe. Now I’ve got a lua environment.
- Downloaded the luabind source from Rasterbar Software. This seems to be based on the powerful Boost.Python library, which I’ve had a lot of success with in the past.
- Created another Visual Studio project for luabind, add the luabind source files and link with lua.dll. Luabind does come with a bjam make file, but I usually find bjam a complete headache to use.
- Created yet another project with the sample code from the luabind tutorial, built and linked against the luabind library and lua.dll
After all this, (and several hours of tweaking linker settings) I’ve now got the tutorials working to the extent that I can now do two things. I can expose C++ functions into a Lua program, which is very handy, and something I’ve found very useful in Python. But of course, the big draw to Lua is that it can be embedded in an existing C or C++ program! So now I’ve also got to the point where I can contain a Lua interpreter within a C++ application, pass a string of Lua code to that interpreter to be executed, and even let provide the interpeter with the ability to call out to C++ functions elsewhere in the program.
So despite the the hoops I had to jump through, I think this could be a very powerful environment. Now I just need to learn the Lua language itself, but as they say, if you can’t learn a new language in a weekend you shouldn’t call yourself a programmer.
Posted in Programming, c++, lua | No Comments »
May 30th, 2007
Languages I code in:
Continuously for the last 8 years
Regularly for several years:
- Java
- Haskell
- Javascript
- Visual Basic
- FoxPro (yuck!)
Operating Systems I use regularly
- Windows (Since NT3.1/ Windows 95)
- Linux (including Mandrake, Ubuntu, Red Hat)
- FreeBSD (isn’t ports nice?)
- Solaris
- Mac OSX (can’t run a studio without it!)
- Other interesting combinations like Cygwin on Windows, Parallels on Mac, VirtualPC etc.
- I typically work in heterogeneous environments with multiple different systems having to work together.
Database systems I’ve used
- MS SQL Server
- MySQL
- Postgresql
- Oracle
- Access
- FoxPro
- sqlite
Source Control Systems I know
- Bitkeeper
- Perforce
- Subversion
- Microsoft Visual Source Safe (hardly counts, I know)
- darcs
Types of development I do
- Web based AJAX applications, using TurboGears or ModPython
- Win32 applications, using MFC, WTL, or the Win32 api.
- Low-level C++ libraries: eg. TCP/IP communications and medical imaging.
- Cross platform GUIs using toolkits like GTK.
- Anything to do with databases, especially fun legacy environments with multiple disparate data sources that all need glued together!
- Medical Imaging – I’ve developed a powerful C++ and Python implementation of the DICOM standard that’s being used at a number of institutions, and I maintain the associated support website : http://dicomlib.swri.ca
- Creating systems and workflow to efficiently deliver new services.
- Analysing, simplifying and improving legacy systems.
People I work for
- Major Banks
- Oil companies
- Non-profits
- Research hospitals
- Consulting firms
- Friends
- Software development companies
- Event managers
- Photographers
- Anyone else…
What is my philosophy of systems development?
“Il semble que la perfection soit atteinte non quand il n’y a plus rien à ajouter, mais quand il n’y a plus rien à retrancher.”
(Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away.)
Antoine de Saint-Exupéry
Posted in Programming, c++, python, work | No Comments »
May 16th, 2007
If, by a bizarre coincidence, you are looking for a top-quality, open source DICOM implementation in C++, along with bindings for Python, then you could do far worse than peruse the most excellent dicomlib website. I created this site last month, to support the library of the same name that I wrote during my time at Sunnybrook Health Sciences Centre. I’ve been learning that developing good software is more than just a technological challenge; it’s a social one as well. Pulling together contributors and users, figuring out what people actually want, managing timelines, synchronizing competing needs and simply getting the word out that the software exists are all important tasks. While I like nothing better than getting stuck into the nitty-gritty of debugging a complex multi-threading problem, it’s been a new experience for me to tackle the community-building side of software development.
Posted in DICOM, Programming, c++, python | 1 Comment »