Category archives: Snaking

Discussions of programming, particularly of programming Python

RSS feed of Snaking

Lots of array-handling refactoring (Mmm refactored code...)


Quite a bit more work on the array-handling code in OpenGL-ctypes. It seems to be working properly now, and the number of OpenGLContext demos that are running is growing substantially (even have the first bitmap-based demo working (though it's a pretty simple demo, no PIL involved)).

Something wonky is going on with the GLUT bitmap ...

Continue reading

Array handling moves forward in OpenGL-ctypes (The goal is flexibility...)


Doing a bit more work with OpenGL-ctypes this evening. Mostly focusing on the array datatype handling. Basically what I want to allow is that any number of array-like datatypes can be registered with the system so that they can be passed to (and potentially returned from) functions expecting POINTER( basetype ) arguments.

Also tweaked the ...

Continue reading

Why ctypes for OpenGL? (Since Brian asked...)


Brian asked me to explain what benefits I'm expecting from a ctypes version of OpenGL versus the PyOpenGLSWIG version. So, why not post it where everyone can read it (if one person asks, probably 10 want to know)...

   * Easier compilation/more robust operation
o Probably 90% of our time in PyOpenGLSWIG is spent on
compilation ...

Continue reading

Need to take some time to work on PyOpenGL-SWIG (OpenGL-ctypes has taken far longer than I expected...)


I've been focussing so much on the OpenGL-in-ctypes project that I've not been spending any "spare" time on PyOpenGL-SWIG maintenance. Tried to get a submitted patch integrated this evening, wasn't functional. There's at least one newly-wrapped extension module in CVS, and probably need to work on a few more.

Probably need 2 or 3 solid ...

Continue reading

Frameworking I go, frameworking I go (Hi-ho the derry-o, I'm about to cry)


Slogged through another day of making administrative interfaces today. I just couldn't help building something that looks a heck of a lot like a framework. When you're faced with a dozen or so virutally identical "edit a table of records" user stories you either wind up with a lot of copy-and-paste or you refactor the ...

Continue reading

Victory is mine! (Yay! I defeated a tiny 86 year old woman at pool!)


Grams was bragging all morning yesterday (again) about how she was going to win the pool tournament. She actually managed to get 2 games ahead at one point, but I rallied back and swept the last 3 games to prove once again that; while you often can offend the karmic balance enough for it to ...

Continue reading

Tessellation doesn't crash any more (But glReadPixels will crash the whole operating system pretty hard...)


Spent some time on OpenGL-ctypes this evening. First up was eliminating the crashes in the GLU tessellation code. That was mostly just passing in the wrong values for use as callbacks (I was passing in a cCallbak, it wanted a c_void_p). Unfortunately, the tessellation doesn't seem to work yet, but at least it doesn't kill ...

Continue reading

Yet another search mechanism... (How many of these things have I written over the years?)


Topped off the day's work by starting on the account-search mechanism (a.k.a. the phonebook). This is your bog-standard search page, it searches 4 or 5 tables with various inter-relations to produce a set of root records (accounts) that match a search string (or integer).

You can write one that's tailor-made for a given application (from ...

Continue reading

A day without connectivity is a sad day indeed (Musings on the need for Cinemon...)


Today was taken up in its entirety by a meeting with Bryan and Clint regarding the billing front-end for the VOIP platform. Mostly just walking them through the interface, discussing problems, features we want, that kind of thing. However, about an hour before they were scheduled to come, Roger's cable went out. I phoned Rogers, ...

Continue reading

Inter-page messaging in Django? (Django form-processing module tutorial and sessionMessage())


Just reading through the Django tutorial part four. One pattern from my own web-framework that didn't get covered is the "sessionMessage" tool. This is used when you submit a form via post, so you want to send the user to a new page, but you want to tell them what happened during the post ...

Continue reading