As promised, here’s my current unit tests for my Racket / cocoa glue code. It’s just tests for my conversion code.
#lang racket
(require rackunit
"cocoa-glue.rkt"
ffi/unsafe
ffi/unsafe/objc)
(test-case
"string->NSString and back"
(let [...]
For the third installment of my glue code between Cocoa and Racket, here is some data type conversion code. It’s all in Racket, using the Objective-C FFI. It includes conversions for strings to NSString and back, as well as converting between lists and NSArray and Racket dictionaries to NSDictionary and NSMutableDictionary. [...]
Part two of my enthralling posts about working with Cocoa from Racket.
Below is more of the code from the C / Objective-C library. You will notice that I use a couple of macros to deal with the NSAutoReleasePools. It’s potentially too clever for it’s own good. This code deals with opening video [...]
I’ve been working on some video apps in Racket on my Mac, but I want to use some of the OSX features like Core Image Filters and QTKit. Racket has really good foreign function interface to both C and Objective-C, but a few things fall through the cracks. For example, it does not [...]
Below is the full sourcecode to my tron bot. The final tournament is currently under way.
My bot uses a fairly basic minimax function with alpha beta cut offs. When both bots are competing for the same space, the evaluation function tries to control more space by being closer to more squares than the [...]
As I mentioned in my previous post, I entered a Tron bot into the University of Waterloo Google AI Challenge. My bot is currently hovering the top ten in the preliminary rounds.
I plan to post all the code to my bot, but not the interesting pieces until after the final tournament has taken place. [...]
I entered a tron bot into the University of Waterloo Computer Science Club Google AI Challenge. It’s currrently around 170th. It’s not really all that fancy or smart.
Click here for my bot’s page.
I recently was trying to figure out how to do user authentication on our company’s Active Directory LDAP server. Using a combination of openldap and the linux and mac side and Microsoft’s LDAP library, I was able to create a small module that can authenticate users and works cross platform.
The code uses PLT Scheme’s [...]
Back in the day, I wrote a few intros/demos. Nothing all that spectacular.
Dosbox allows them to still run on modern computers. It’s pretty fantastic. There was an issue with audio in Dosbox, so the video was muted.
Here is DDLSTARS:
When I was in high school, the TI-85 was the shit. It was a great calculator, and someone had figured out how to install a loader that would allow you to run arbitrary native programs using some fancy hacking and installing programs into the “Custom” menu. The loader was called “ZShell.”
The TI-85 had [...]
Recent Comments