Month: April 2012

  • An introduction to native backed objects with the Android NDK

    As many Android developers know the Android NDK is used to cross-compile native (C/C++) code to run in Android programs. Unfortunately, because it uses JNI we’re limited to a C-style call interface. Tools like SWIG can be used to automatically generate wrappers for existing code including C++ classes. In this post I’ll provide an introduction […]

  • Over-aggressive GCC optimization can cause SIGBUS crash when using memcpy with the Android NDK

    At work we’ve been developing new Android hardware, and as such I’ve been porting a lot of our existing C/C++ code to Android using the NDK, a collection of GNU build tools (gcc, objcopy, etc.) and associated scripts to aid the development of native C/C++ code on Android. One of our projects is nearly 1000 source […]

  • Modeling weight loss with differential equations

    Modeling weight loss with differential equations

    This comes from a talk I’m giving at Penguicon 2012. The talk in general is about weight loss and getting healthy but part of it involves doing some predictive modeling of future weights based on calorie counting. Consider the question “if I eat X number of calories a day, will I gain or lose weight?”. […]

  • Progressive drawing of simple SVGs on the HTML5 Canvas element

    The HTML5 (is there supposed to be a space? I’m not sure) Canvas element is pretty cool! A recent school project involved visualizing some different data sets from in an “interesting” manner. Most of what we did just a standard Google Maps API mash-up but I decided to spruce it up a bit with an […]