Okay, so there was this T-Rex 450 on eBay…..

Work once again was all about CPU optimisation. Lots of prefetching data. Basically analysing where data cache misses are, then putting in prefetches in good places. Managed to get a few fps increase. I was watching this T-Rex 450 on eBay, it was going for about fifty quid with a few hours to go. These are big heli’s, well almost half a metre as in the name. But they are very stable to fly. They are also over three hundred quid new and this one had a case and a load of spares with it as well. All it was lacking was lipo’s and a receiver, and I don’t have a shortage of them. Won it at just over the ton mark, plus I managed to get a nice stand as well. Plus it was in Bristol.

Washing machine arrived in the correct time slot. Unpacked it. Did more work. Jamie came home, so removed the rest of the packaging and then I installed it. It fitted with about 2mm to spare. It’s stainless steel. Well, it’s stainless steel coloured plastic. It looks nice. I put it on a rinse and spin to clean t out. Walked Sasha. Went for about eight mile run. Had a shower, then drove to the other side of town to pick up this heli. Met the chap there, he was nice, went through it all. Very pleased. I think I’ll do a rebuild on this one first as it’s a bit easier to work on. It has a blown servo, apart from that it all looks complete. Not the sort of thing you can fly in the house though, if it hit you it would take your head off, no problem at all. Just need to pick up a few extra tools.

After staring at it for quite a while, I noticed the tail rotor is on backwards

Got Up at 6:30, took Sasha to daycare. Cleaners arrived just after 10. Working on CPU side optimisations today. The compiler we use is supposed to be very good, yet it sometimes manages to produce some pretty awful code. So spent the bulk of the day rearranging bits and prefetching data. Quickly walked Dillon who pulled so hard that he threw up. Picked up Sasha. Went to Pump, worked on my arms, they are looking mighty fine. Came back and did more work. I’ve built up a bit of extra time now, so will do the next lot of video editing at some point tomorrow. New washing machine also arriving tomorrow.

My new helicopter looks like it’s done a tour of Vietnam

Rudely awoken by the postman. Special delivery of my new helicopter. Work was dull, debugging some skinning issue.

So the new helicopter to the fleet is an Align T-REX 250. It was second hand off ebay, okay I got it dead cheap. This poor baby needs a hell of a lot of TLC. Oddly most of the parts are there, they just aren’t in the correct places. It certainly looks like it’s had a bit of a hard life and flown by a chimp. I think I’m just going to completely strip this one down and rebuild it. None of the servo’s are correctly aligned or anything. It’s going to be a bit of a labour of love this one. But it should be a lovely aircraft when it’s finished. It has a fully driven tail rotor geared from the main rotor, it’s also capable of autorotation.

Went for a run. That was kind of fun. Oddly got back and my legs didn’t hurt. Finished the rough edit on the new video.

I’m getting highly pissed off with a guy at work who takes three and a half hour lunch breaks, I shouldn’t let it get to me, but it’s beginning to get really on my tits.

Celebrity, really?

After tracing a mystery white four pixels that have apparently been there four years, I pretty much wasted the rest of the day trying to trace an animation/skinning problem which still isn’t solved.

Walked Sasha, I’ve given up on Dillon, he’ll just get old and fat like Jamie. New washing machine being delivered Thursday. Went to gym, did Combat. Came back, did more unsuccessful work. Thought I’d see who was in the new ‘Celebrity Big Brother’, well no celebrities that was for certain. Maybe one old boxer who I’d vaguely heard of, it’s a bit of a joke really.

Hopefully tomorrow will be more productive.

Red Bull air race

So this morning started in a bit of a hurry. Fed everyone, including me. Then jumped in the car and drove up to Ian’s place in Windsor. Met up with everyone. I was surprised, I was expecting some catering company, but Ian cooked it all himself. After drinks and eats we boarded the coach for the very short journey to Ascot. We were there for the Red Bull air race. This is a bit of a strange thing. Aerobatic planes fly very close to the ground around inflatable columns. Anyway, I fought myself to the front, right by the course barrier and shot some 1,800 photographs. It was all pretty good and two British guys ended up winning it. We then ventured back to Ian’s. More drinks (Coke, I was driving) then drove home. A fun day all in all.

The death of model engineering

So started off with breakfast for three. Phoned mother and discussed washing machines. Then walked Sasha. Went to Tesco’s and ordered a washing machine. It’s stainless steel and has a dryer. Had a light lunch.

Drove to Thornbury, went to the ‘Model engineering and hobbies’ exhibition. The first thing I noticed on entering was strange, I was probably one of the youngest people there. I walked round the first couple of halls. There were just some fantastic models, all sorts, from Meccano to jet engines. The thing that fascinated me was that these men, in sandals and socks, in their eighties were producing fully working model engines in their little workshops at home, out of solid blocks of metal. These things were fantastic. I chatted to a couple of these chaps and they were absolutely passionate about there models, they’d answer any question and would chat all day to you if they could. The sad thing they both confirmed though, there were no younger people there, they would dearly love to share there knowledge and skills, yet no one was interested. The bulk of their clientele were other retired gentlemen. Give it another ten years and their models will be consigned to a museum and there skills would have vanished forever.

In the last hall I managed to meet up with the ‘Beaufort flying club’, which is the local club in Bristol. They actually fly very local to me. And just to prove that the world is a small place, standing by the small arena was Stan, this was the man I met a couple of weeks ago one evening to find a couple of geocaches with. I chatted to him, after I reminded him who I was I then asked him if he was a member, he said yes, and that he flew the model helicopters. So we had two hobbies in common. We then chatted for about an hour on anything and everything. He’s in his seventies, he thought I was about twenty-eight, I like Stan. Chatted to the helicopter guy there and he gave me lots of tips about setup. I may join the club at the end of the year when they renew their memberships. I learned quite a lot anyway, so hopefully I can put some of that into practice.

Round and round and round….well actually square and square and square

Got up and did some vague work for a couple of hours. Packed away the shopping. Then drove to Staverton. Straight into circuits, I lost count of how many I did. A few I came in a bit too quick and one was a bit closer to a vertex ring than I’d like. But overall not bad really. We then finished off with a load of auto rotations on final. Again, all pretty good, flared too early. But when you are approaching the ground at 12MPH you don’t really want to hit it. So more practise required there. Next couple of flights will be pretty much the same, just get all the safety procedures down to instant reactions. Weather wasn’t particularly good either. Traffic on the M5 on the way back. Had lunch. Did more work.

Then it was off to the gym. Did Pump. Followed by a very heavy session with Laverne. Not heavy in we discussed Proust, but heavy in the weights used. I now have massive muscles above my shoulders. Shame that’s the only place. Still it’s given me a bit of encouragement.

Lots to do tomorrow. Including going to a model engineering exhibition, that’ll all be a bit geeky.

Centroid, centroid everywhere, but not an edge to find

Had coffee. Rebooted. Today’s problem was all about detecting edges of ploy’s. Not going into the reason why, but needed to detect these in multi-sampling mode. So here’s the fun way to do it. Use the screen position passed into the pixel shader, this is the exact position, so in MSAA mode it can be on a partial pixel. Okay, so how do you get the edge? Well you need a value thats always inside the poly. So you pass in the position again, but this time you pass it in with the ‘centroid’ modifier. This means it will always be in the centre of a pixel. What do you do then? Well it’s quite simple, you subtract one from the other, if the difference isn’t zero then you have an edge pixel. Can it be optimised more? Well yes, but you have to be a bit clever. You need to pass in the position, but set it to no-interpolation, then do the interpolation manually, but once with normal and once with centroid.

Walked Sasha, Dillon wasn’t interested again. After much thunder and rain I managed a fairly dry run this evening, another eight odd miles. Started the rough cut on the new video, about half way through. This one will take a while.

Flying tomorrow.

Why does time go so slowly? Because you are calling the real time clock

So woke up at 6:20, which was fine, got Dillon to daycare. I got a text a little bit later to say there was blood in his poo. Considering what he eats I’m surprised there wasn’t a television in his poo. Now work was quite interesting. We have timers, lots of timers, and boy do they show up high in profiles, so I decided to take a look at them. For every timer we are basically calling a linux style real time clock (RTC). This does indeed store very accurate time, from the linux epoc. But every call goes via the kernel and then reads the clock, which is a hardware chip outside the cpu, so there’s loads of bus activity and loads of hanging about. So instead I changed it to the CPU tick clock. Now this is a handy hardware register that store the current cycle number. It’s a 64 bit unsigned int. Also there is a handy call that returns the clocks per second or hertz as it were. So simple you just divide the ticks by the clock rate and the gives you the time in seconds. But what if you want the time in micro seconds? Well then you have to multiply the current tick by one million and then do the divide. Ah, but then you run into a bit of a problem. If you start shifting the ticks up you then begin to run out of room in you unsigned int. So what you need to do is sacrifice a little bit of accuracy. You only multiply the tick by a thousand, but divide the clock rate also by a thousand. This still gives you a pretty accurate microsecond clock, but it then won’t wrap round for almost four years.

Took Jamie to the bank. Picked up Dillon. Went to the gym and did Pump. Finally got all the latest video footage imported and synced up. So now I just have to edit the whole lot.

So Robin Williams could face life either

While not being able to sleep again, Jamie broke the news to me that Robin Williams had just died. He had committed suicide. He once said, “I checked my self into rehab in wine country, so I could keep my options open”. There was a man who had everything, but suffered his own personal demons. He’s found a way out for himself, but left a lot of other people suffering. I finally got to sleep about 4AM.

So woke up still in a mood. Still, I did have a load of work to get on with, so got on with it. It kept me going for a solid eight hours, with a minor sandwich interruption. Stopped at about 7PM. Went out in the rain and ran about eight miles. My legs now hurt. Again. Couldn’t get James on Saturday, so booked on Friday instead, about time I had a stupidly long lunch break. Had a shower, ate salad. Think I may enter a half marathon somewhere, I seem to be running one daily anyway.