December 2004 Entries

The wonders of DDS textures

I was fiddling with some of my 3D code trying to speed up the loading and I've hit one of those classic "change the overal way you do something instead of optimise your code" situations. The code was simple enough before, it loaded 25 1024x1024 textures and displayed them. The original data was in GIF format so I loaded that into a .NET Bitmap and then created a Direct3D Texture object from that for each one. It used about 64Mb of video memory and took about 1600ms per texture to load so I was pretty sure that I could cut down...

No more work until the end of the year, so what should I code?

There are days and days of not being at work ahead of me so I need to think of something to code over that time. I've got a small bit of coding planned on a map, but that's nearly finished so I have a choice of either coding something for myself or starting something cool that I want to work on next year in the spirit of this, which is (ignoring the whole getting fired bit first) the best way of getting a new project I find :) I think it'll be more 3D graphics as my last work was more...

It took us ages to spot this bug

We spent some time the other week tracking down a bug in a colleagues code that was a real pain to find. The code was triggered from a button click and was a long running operation so it kicked off a worker thread to do the processing and Invoked back to the UI when it needed to update the display (a graph in this case, but that’s only partially important). So far all well and good but there should only be one of these worker threads in existence at any one time and every click to the button had to...

Virtual PC and Embedded XP

On the face of it Virtual PC seems like a great idea for testing embedded XP images so you don't have to go replacing flash cards from deep inside a unit that needs a team of twelve with special cutting gear just to get the lid off. Of course in the real world I'm developing on a rack PC that has the same hardware for most of my time with a project so it's just a case of slipping out the processor and popping in a new compact flash card but it's still more effort than I really want to...

What's new in the .NET profiling API for version 2

There's an interesting article in msdn magazine about what's changed with the profiling API for version 2.0 of .NET. The quick summary for anybody maintaining code that uses the old version is that in process debugging has gone and been replaced with lots of ways of doing what you were doing before. Time to play with the changes.

When upgrades go bad

My current online game of choice is Everquest 2, which has had a few little problems over the weekend. I tried to log on Friday night at 7pm GMT and the server with my character finally resurfaced Sunday afternoon. A buggy upgrade combined with some hardware failures resulted in a 40 hour day for team and lots of very bored addicts who sat staring at their screens all weekend hitting reconnect just in case it was back. I moved my house round instead. Much more entertaining and my PC is now in a room with a totally different view. Now I can...

DirectX December 2004 Update

Well I promised a technical post so... Microsoft have released a new update to the DirextX SDK here. As far as I can tell it's a few more technical articles, PIX was updated and D3DX got a few new features. Oh, and the samples and tools all use strsafe.h now which has to be a good thing for anybody learning from the code. Most interestingly this is the last version that will be fully tested for Windows 2000. From now on only development on XP and later is fully supported.

What time is it?

As I sit here my PC tells me that it's coming up on midnight and iTunes seems to be picking more ambient songs than rock so it must be nearly time for bed (OK, that's just a coincidence, and to prove that the track that came up while I wrote that was by Black Grape, which is neither relaxing nor ambient). Now I don't wear a watch for two reasons. The first is that I always seemed to catch them on things and break them so I just haven't gotten around to replacing the last watch that I broke about 15...