On the pleasures of memory management

Error:  Allocation from MMO_GroundClutter.cpp line 42 was allocated using new [] but was freed using delete;  should have been delete []! I can’t say how proud I was to have had my memory management system be smart enough to print out such a cogent and useful error message.  I’m less certain about how bright an idea…

A long-expected fix

So this was a long time in coming.  For quite a long time, my procedural geometry generation system has been generating texture coordinates for the objects it makes.  This is so that (if/when desired) textures can easily be applied to the generated objects. Texture coordinates basically work by assigning coordinates to each corner of an…

Code simplification

Old: float hw = width * 0.5f; float hh = height * 0.5f; // draw dark background vsDisplayList *list = new vsDisplayList(512); vsVector3D va[4] = { vsVector2D(-hw,-hh), vsVector2D(hw,-hh), vsVector2D(-hw,hh), vsVector2D(hw,hh) }; int ts[4] = { 0,1,2,3 }; int ls[5] = { 0,1,3,2,0 }; list->SetColor(vsColor(0.0f,0.0f,0.0f,0.9f)); list->VertexArray(va,4); list->TriangleStrip(ts,4); list->SetColor( vsColor::White ); list->LineStrip(ls,5); list->ClearVertexArray(); vsFragment *fragment = new…

Bleah, sick

I’ve come to learn that being ill is an entirely different affair when you’re un/self-employed.  Far more stressful to be unable to work, when you don’t have paid “sick days” supporting you. Yesterday I was basically unable to think straight, so ended up spending most of the day resting (and playing through the second half…

On the week

So it’s been a bit of a roller coaster week (and technically, it’s not over yet!)  Lots of ups and downs, thrills and excitement while it lasted, but in the end, I’ve basically wound up right back where I started.  No change to the work situation;  it’s tough to find a paying position this close…