Monday, 12 April 2010

»It's all about the framework…«

Louis Gerbarg, a former Apple engineer, makes some good points about why Apple introduced its ban on foreign interpreters. Still, I'd love have an iPhone/iPad and be able to create something wrapping Mercurial and Python for it.

(Found via John Gruber's Daring Fireball.)

Monday, 25 January 2010

On levels of suck…

Just now, the venerable John Gruber wrote a post mentioning the perception of it is at Apple, and in his post, he includes a link to a screenshot of a video playing simultaneously in Flash and VLC; whereas Flash uses 33% CPU to decode the video, VLC uses just 12%. At a superficial glance, this would appear to support a verdict of plentiful levels of suck. However, the impression given by the screenshot is misleading, and for one simple reason: Even for something which sucks, Flash sucks. The comparison is biased towards Flash by two factors:
  • The video appears relatively small; neither Flash nor VLC require significant effort to decompress it.
  • VLC uses a heavily optimised software decoder, and has different characteristics from the decoders built-in to the operating system.
Below is a screenshot of 1920×1080 YouTube video simultaneously playing in QuickTime Player and Flash on my summer 2009 13-inch MacBook Pro:

Whereas QuickTime Player uses about 15% CPU, Flash uses about 105%. Oh, and unlike QuickTime, it can't play the movie smoothly. Extra icing on the cake is the fact that Flash uses 5–10% CPU at idle, just displaying a still frame of the video. For reference, VLC and Google Chrome use software decoders and manage to play the video quite smoothly, using about 60-110% CPU. (Chrome decodes the video in one process and renders it in another; the rendering process uses about 25% extra CPU.)
And for video playback specifically, Flash’s performance pales compared to H.264 played through QuickTime. This is not subjective.
In my opinion, Gruber isn't quite fair in this statement; I agree that there's nothing subjective about the comparison, but I don't see the need to restrict it to QuickTime specifically. Given any half-way decent player, the performance of Flash will pale compared to it:
  • Flash rolls its own decoder rather than using the one provided by the OS.
  • Flash uses significantly more CPU when decoding small videos.
  • Flash cannot use more than one CPU core to decode video.
  • Flash cannot use any hardware acceleration available.
I doubt software this bad doesn't happen by accident — someone has to really not care about quality — and I seriously doubt it will change anytime soon. I can personally recommend enabling the HTML5 beta on YouTube and/or using ClickToFlash; the video experience suddenly becomes much less painful. Alas, the only thing missing is support for full screen video playback in the browser…

Sunday, 18 October 2009

Another quote

»I only ask because I am banned from certain places around the country. I am banned from Trinity College, Cambridge, for instance — I am, this is a true story — I'm banned from making contact with any of the staff or students there. I'm banned from the premises, because — well, it's a long story; it goes back a while — but I applied to do my PhD at Trinity and, erm, they said ‘Send in your thesis.’ and I misheard them. Well, three months go by and I hear nothing; a year goes by and I hear no… I rang up again; I said »Look, do I just keep sending them in, or what happens now?’«
Jack Dee, English comedian

Sunday, 4 October 2009

A quote

“Do you find that this approach usually works? Or let me guess, you've never tried it before. In fact, you don't normally approach girls — am I right? The truth is that you're a quiet sensitive type but, if I'm prepared to take a chance, I might just get to know the inner you. (Taxi!) A little bit crazy, a little bit bad. But hey — don't us girls just love that?”


“Well, what's wrong boy — cat got your tongue?”

Tuesday, 24 February 2009

Et mantra, en tanke

Husk: selvrealisering, mening, formål, logik, rationalitet og argumenter er overordnet set overvurderede koncepter, eftersom ingen sandhedsværdi kan eksistere i ordets egentlige forstand. Hig efter det meningsløse, plebejere, og I vil opnå den sande erkendelse: hvad lyder godt, er godt. LIX-værdien er det eneste der vil tælle; alt andet er noget hø.

Søg illusionen, hig efter den, stræb efter at fremstå og fremtræde som du ønsker! Ethvert menneske er begrænset i hvad det kan opfatte, såvel som grundlaget for dets kognitive modeller ikke kan være andet end hvad det kan analysere sig frem til på basis af dets observeringer. Vi kan tænke os til mangt og meget, men grundlaget for disse tanker er og bliver de simple, måske endda subtile, indtryk vi danner os gennem de ringe sanser for syn, hørelse, følelse og lugt vi som eksemplarer af homo sapiens sapiens kan præstere.

Klæder skaber ikke folk; klæder er folk! Sælg skinnet før bjørnen er skudt! Smid flere strå på den kamelryg! Kryds Amazonen efter sand og Gobi efter vand!

De siger jo at lediggang er roden til alt ondt, ikke sandt? I så fald ville jeg være en fremragende kandidat til evig fordømmelse, skulle noget sådant vise sig relevant på et senere tidspunkt.