Various ways to backup

Over the years I have been using several kinds of solutions to backup stuff. Here’s a description of the ones I can remember. Many of them focus on being low-cost, simple and straightforward, but are far from a perfect solution in many other ways.

Read the rest of this entry »


Unwrapping Values – nearest next angle from a previous angle

So, assuming you have angles previousAngle and nextAngle, and you want to transition from the first to the second smoothly. If it’s like from 358 to 2, a simple linear interpolation will awfully go through almost a full circle down from 358 to 2, when a simple four degree transition forward would have been enough, i.e. you should have been going to 362 degrees instead. So, how to figure out what’s the shortest transition?

I remember hitting against this problem numerous times, always remembering that I have solved it previously but always seem unable to find the previous solution. And I still can’t just write it out by heart.

Once again I had to solve this, so this time I tried to Google for it (“angle wrap delta”), and found out that somebody named Jason S had posted a nice generalization to a related question in Stackoverflow.com.

For your convenience, I’m posting a modified C version of the code here.
Read the rest of this entry »


Buggy software is cheap enough

If software would be made bug-free, that would force prices to be so high that nobody could buy them. How so?

Well, let’s think about what it means to build bug-free software. There actually exists some software, which is built with goal of “zero-defects”. By that, I’m not referring to the constant hype from latest agile method cult who may have some extravagant claims. I mean software where it’s of utmost importance to really have no bugs, no matter the costs. A case where a single bug may mean loss of lives or failure of the whole project. This kind of software is built for space missions, nuclear facilities, and so on. And such a policy on quality is inherently very very expensive.

Imagine if Windows, for example, would have been built with such policy. It’s a really complex and huge piece of software compared to ones normally built with zero-defect policy. But, given the option, would you pay $19,900 of your operating system, if it would never crash? It’s quite a no-brainer that “everybody” would rather pick the same software for $199 and just put up with the few problems they encounter. (The price difference was picked by Stetson-Harrison method. It’s a guess to illustrate the point. The difference could be actually lot worse for niche market software which isn’t aimed for mass market.)


Back from Japan

Fire station

I was away for about 2.5 weeks to visit Japan, more exactly Kyoto and Tokyo. The trip was excellent, and in retrospect it was clearly a good idea to visit both cities. While Kyoto is a modern city, it still has a bit more traditional feel to things. For example, the local laws forbid building tall skyscrapers, so there aren’t much taller buildings than we have in Helsinki.

Tokyo in other hand is very modern city with lots of skyscrapers. When going to see the city view from top of Mori building in Roppongi hills, you can see the city expands in every direction to the horizon as far as you can see. There is also extremely well developed public transportation, just check the Tokyo subway map (PDF). The public transportation in Helsinki is also quite good, but Helsinki is so tiny compared to a big metropolitan city so that our subway is tiny as well – just compare the above one to the current Helsinki metro map. ^_^

Small garbagetruck

Interestingly when going to USA it feels that everything is bigger. When going to Japan, it feels the opposite. Maybe that’s partly because there is a whole different class of small cars which are narrower than we’re used to. I think the average width of streets is a bit less as well. There are also typical big western cars, so there’s just more variety of different sized cars. There’s even mini garbage trucks as you can see. However, not everything is small; I think in Japan they just tend to make things small by default, but aren’t afraid of making things big when there’s a reason to do so.

Also some things seemed to be done in an opposite way of what we’ve used to. Not just the left-hand driving and walking, but cars are also almost always parked backing to parking spot so that it’s slower to park car but easy to leave. And at least in Kyoto the buses worked so that you go in from a single back door and pay when you exit through the front door. Curiously in Japanese language the verb is also put last in sentences (think of Yoda-speak).


Smiling parenthesis in parentheses

Time for some trifling thoughts.

When writing you sometimes want to put a sidenote in parentheses, and then end it with a smiley.

This raises a question: Should you write one or two ending parentheses?

This seems to be an awkward problem for many. XKCD even made a comic about it (link at end of this post).

My solution is to use just a single parenthesis, so the ending parenthesis becomes part of the smiley. It just looks better that way! However, this way really sucks if you are writing in e.g. some chat system which automatically replaces smileys with small graphic icons. In that case the ending parenthesis just disappears and it feels like the sidenote keeps going on and on and the whole paragraph starts feeling unbalanced. So, if I know that the system will replace my smileys with icons, I will use double parenthesis.

At this point you’re probably wondering why I don’t show an example? I often overuse such sidenotes for some remarks, which is of course the reason I have even realized this earth-shattering problem. However, I have also realized that the best way to fix it is actually just to not use such sidenotes. Often the sidenote may actually be just a natural thing to say in the next sentence. Or perhaps you can consider using a footnote. I feel footnotes don’t work that well in web pages but I prefer them in print publications.

Anyway, I should save you the trouble (of constructing examples yourselves :).
Or maybe you already tried yourself (I know you did! :-) ).

XKCD comic


Zen Bound 2 Announced

So it’s no longer a secret … at Secret Exit we’re working on Zen Bound 2 for the iPad.

Various sites have embraced the news eagerly such as IGN Wireless, CNET and Kotaku, to name just a few.

Be sure to also check Mikko’s blog post about a cardboard prototype.

Update Apr 3, 2010: iPad is now available in the US, and so is Zen Bound 2. Go get it!


Stair Dismount nominated in IGF mobile

2010 IGF Mobile has nominated Stair Dismount (iPhone version) for Technical Achievement. Nice! :)

Turns out that Stair Dismount also won the award for Technical Achievement. ^_^
Read the announcement in igfmobile.com.


Stair Dismount 2 development preview build

We just released Stair Dismount 2 PC development preview build for Windows. It is basically a limited version of the iPhone version, which is clearly notable from the window size and UI design. Final version of SD2 will naturally have revised UI and window size. Also level creation instructions are included, which is the main reason why this early build is now available. This thread has the relevant links and instructions.

Update Jan 2011: The relevant Secret Exit forums have been closed and the PC preview build isn’t available anymore. There’s no official word about state of the possible PC version.


No entry for LD48, SD update out

The Stair Dismount 1.2.0 (iPhone/iPod touch) update should be out now!

In other “news”, I didn’t end up making an entry for the last weekend’s Ludum Dare 48h game dev compo. The theme was “Exploration” – I wasn’t really fond of the theme, but I still had a solid idea very quickly I went forward with. However, I ended up honing gameplay nuances for too long in my head and without actually doing much of implementation. I ended up writing some level generator thing and the supporting draw code etc. Might come back to those later if I want to work more on the idea; or perhaps even integrate with my summer efforts for making a little game for Assembly which also turned out not to be.

On the other hand, at least there was nice chance to have sort of “role reversal” for the weekend, since I was the one who went to buy groceries and made some food, and my wife made a nice little game to entry in the same LD48 compo.


San Angeles Observation demonstrating WebGL


I was just reading Chromium Blog and it just announced: WebGL Spec Initial Public Draft Released. Well, I was quite surprised at half way to the post when I noticed they mentioned that one of the show cases a port of my San Angeles Observation 4 KB intro. I downloaded a fresh Chromium build (a development version of the Google Chrome web browser) to try it out, and have to say that I was quite impressed – the thing runs really smoothly. Let’s hope this tech becomes available as soon as possible to all major browsers. :)