<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Cuppadev</title>
	<atom:link href="http://www.cuppadev.co.uk/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.cuppadev.co.uk</link>
	<description>Cuppalicious coding!</description>
	<lastBuildDate>Thu, 04 Mar 2010 00:28:48 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Don&#8217;t write that framework</title>
		<link>http://www.cuppadev.co.uk/hacks/dont-write-that-framework/</link>
		<comments>http://www.cuppadev.co.uk/hacks/dont-write-that-framework/#comments</comments>
		<pubDate>Thu, 04 Mar 2010 00:28:48 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[Hacks]]></category>
		<category><![CDATA[disaster]]></category>
		<category><![CDATA[software development]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=728</guid>
		<description><![CDATA[Writing frameworks is a waste of time. 
That is the conclusion after spending most of my time on my last project writing a framework, in order to make the project &#8220;easier&#8221; to write.
The trouble is every minute you divert to the framework, half of your project dies. And since there is an inherent division between [...]]]></description>
			<content:encoded><![CDATA[<p>Writing frameworks is a waste of time. </p>
<p>That is the conclusion after spending most of my time on my last project <strong>writing a framework</strong>, in order to make the project &#8220;easier&#8221; to write.</p>
<p>The trouble is every minute you divert to the framework, half of your project dies. And since there is an inherent division between project and framework, by the time you have everything working you have lost your original train of thought.</p>
<p>Then you realize: the project is way <strong>behind schedule</strong>; there goes a cool feature that could gave landed you a multitude of sales. Or even worse, everyone has lost interest.</p>
<p>Instead, I suggest the following mode of thought:</p>
<ul>
<li>Find an existing framework that does most of what you require.</li>
<li>If the framework falls short, rethink your approach.</li>
<li>If you find your code has become a mess, re-factor it into a <strong>small</strong> library.</li>
</ul>
<p>Don&#8217;t be tempted to spend time writing a <strong>monolith</strong> of a framework. And beware the trap of thinking you can turn it into a product in itself; after all, there is a reason why a large proportion of frameworks are free.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/hacks/dont-write-that-framework/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Twackr: Twitter-style time tracking</title>
		<link>http://www.cuppadev.co.uk/projects/twackr-twitter-style-time-tracking/</link>
		<comments>http://www.cuppadev.co.uk/projects/twackr-twitter-style-time-tracking/#comments</comments>
		<pubDate>Sun, 21 Feb 2010 15:02:09 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[web development]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=718</guid>
		<description><![CDATA[It&#8217;s been a while since my last rails post, so i decided to try out something different. 
Specifically, i&#8217;ve always wanted to track my time, but i never seem to find a solution that works. The solution is either too simple and doesn&#8217;t give me any feedback, or it&#8217;s extremely complicated and hard to use.
So [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a while since my last rails post, so i decided to try out something different. </p>
<p>Specifically, i&#8217;ve always wanted to track my time, but i never seem to find a solution that works. The solution is either too simple and doesn&#8217;t give me any feedback, or it&#8217;s extremely complicated and hard to use.</p>
<p>So i set about to make a time tracking solution that was both ridiculously simple to use, and could give me some useful reports back. Thus, <a href="http://github.com/jamesu/twackr">Twackr</a> was born!</p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/02/twackr-2-300x158.png" alt="" title="Twackr" width="300" height="158" class="alignnone size-thumbnail wp-image-720" /></p>
<p>I modelled the entry system after Twitter: at its simplest, all you need to do is type in what you are doing, and Twackr will start tracking your time instantly. When you are done, simply click on &#8220;Finish&#8221; and it will be done!</p>
<p>Already spent some time doing something but couldn&#8217;t get to Twackr? Then you can backdate entries by adding &#8220;<strong>-1H</strong>&#8220;. Still working on something? Then try &#8220;<strong>-1H+</strong>&#8220;. Blocking out some time? Then use &#8220;<strong>+1H</strong>&#8220;. Want to see if you&#8217;ll make the deadline? try typing &#8220;<strong>1H</strong>&#8220;.</p>
<p>Time can also be categorised into &#8220;Services&#8221; (<strong>#service</strong>) and &#8220;Projects&#8221; (<strong>@project</strong>). </p>
<p>You can check out a <a href="http://twackr.heroku.com/">live demo of twackr on heroku</a>. Just sign up, and check it out &#8211; it couldn&#8217;t be any simpler!</p>
<p>Like most of my other rails projects, Twackr is Open Source. So feel free to <a href="http://github.com/jamesu/twackr">fork it on github</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/projects/twackr-twitter-style-time-tracking/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>More CSS Animations</title>
		<link>http://www.cuppadev.co.uk/hacks/more-css-animations/</link>
		<comments>http://www.cuppadev.co.uk/hacks/more-css-animations/#comments</comments>
		<pubDate>Sat, 06 Feb 2010 20:31:28 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[Hacks]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[webkit]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=711</guid>
		<description><![CDATA[A few days ago i popped across Anthony Calzadillas &#8220;Pure CSS3 AT-AT Walker&#8220;, which is a great application of using CSS3 Transforms and Animations to create a scene of an AT-AT Walker walking along in a simulated iPad.
Anthony explains in great detail how he built the AT-AT, but i couldn&#8217;t help but think &#8220;I&#8217;ve got [...]]]></description>
			<content:encoded><![CDATA[<p>A few days ago i popped across Anthony Calzadillas &#8220;<a href="http://anthonycalzadilla.com/css3-ATAT/index.html">Pure CSS3 AT-AT Walker</a>&#8220;, which is a great application of using CSS3 Transforms and Animations to create a scene of an AT-AT Walker walking along in a simulated iPad.</p>
<p>Anthony explains in great detail how he built the AT-AT, but i couldn&#8217;t help but think &#8220;I&#8217;ve got a better way of doing this!&#8221;. </p>
<p>Last year i made a <a href="http://www.cuppadev.co.uk/projects/css-transform-exporter-for-blender/">CSS Transform Exporter</a> for Blender, which can take any scene and generate a corresponding version in a nice and simple HTML page.</p>
<p>So it can take this:</p>
<p><a href="http://www.cuppadev.co.uk/wp-content/uploads/2010/02/atatblend.jpg"><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/02/atatblend-300x165.jpg" alt="atat in blender" title="atat in blender" width="300" height="165" class="alignnone size-thumbnail wp-image-712" /></a></p>
<p>And turn it into this:</p>
<p><a href="http://www.cuppadev.co.uk/wp-content/uploads/atat/atat.html"><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/02/atatwkit-251x200.jpg" alt="atat webkit" title="atat webkit" width="251" height="200" class="alignnone size-thumbnail wp-image-713" /></a></p>
<p>Admittedly simple, but it does show off the potential power in adopting CSS3 and HTML5. After all, who needs to use Flash when you can make everything work in actual web browser instead?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/hacks/more-css-animations/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Ovi Store</title>
		<link>http://www.cuppadev.co.uk/platforms/the-ovi-store/</link>
		<comments>http://www.cuppadev.co.uk/platforms/the-ovi-store/#comments</comments>
		<pubDate>Sat, 16 Jan 2010 01:08:49 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[Platforms]]></category>
		<category><![CDATA[deployment]]></category>
		<category><![CDATA[nokia]]></category>
		<category><![CDATA[software development]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=693</guid>
		<description><![CDATA[As any mobile app developer knows, there comes a time when you need to release your creations out to the general public. On the iPhone, one has the App Store. On Android, the Android Market. On Nokia devices, the Ovi Store.
Whenever i hear someone talk about the Ovi Store, they never have anything good to [...]]]></description>
			<content:encoded><![CDATA[<p>As any mobile app developer knows, there comes a time when you need to release your creations out to the general public. On the iPhone, one has the App Store. On Android, the Android Market. On Nokia devices, the Ovi Store.</p>
<p>Whenever i hear someone talk about the Ovi Store, they never have <a href="http://www.techcrunch.com/2009/05/26/nokia-ovi-store-launch-is-a-complete-disaster/">anything good</a> <a href="http://shkspr.mobi/blog/index.php/2009/05/nokia-ovi-store-oh-dear/">to say</a> <a href="http://www.youtube.com/watch?v=UC8OC8XUZGg">about it</a>. Having not experienced the store myself, i remained skeptical.</p>
<p>Recently the Ovi Store on the <a href="http://maemo.nokia.com/n900/">Nokia N900</a> opened, so naturally i decided to check it out and see if it really was as bad as people suggested. What follows are my experiences, illustrated with accompanying screenshots.</p>
<h3>To Start</h3>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi1-300x180.png" alt="Start Page" title="Start Page" width="300" height="180" class="alignnone size-thumbnail wp-image-694" /></p>
<p>First i tap on the &#8220;Ovi Store&#8221; icon on my device. After a short while, a <strong>web browser</strong> opens in fullscreen mode. So far, not bad.</p>
<p>Not sure what i want to do, i tap around the tabs (each <strong>loading a new page</strong>). Now i realise: i just saw something interesting on the last page, and want to see it again. But how do i go back? Well first i need to exit fullscreen mode. Next, i need to tap the back button. Then from the history list which appears:<br />
<img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi2-300x180.png" alt="Browser History" title="Browser History" width="300" height="180" class="alignnone size-thumbnail wp-image-695" /></p>
<p>I must then select the previous slide. <strong>*THEN*</strong> if i am really unlucky, i get to see the page <strong>load again</strong>.</p>
<p>Now i decide i want to download a game, so i tap on the &#8220;Games&#8221; tab. The &#8220;Games&#8221; page <strong>loads</strong>, showing:</p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi3-300x180.png" alt="App List" title="App List" width="300" height="180" class="alignnone size-thumbnail wp-image-696" /></p>
<p>So now i think &#8220;I&#8217;ll try and download Angry Birds.&#8221; Herein lies a puzzling problem. <strong>Nothing happens</strong>. A few more taps, and the browser <strong>zooms in</strong>. Finally after a bit more tapping, i manage to get it to recognise i selected the app. The &#8220;Angry Birds&#8221; page loads.</p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi4-300x180.png" alt="Angry Birds Page" title="Angry Birds Page" width="300" height="180" class="alignnone size-thumbnail wp-image-697" /></p>
<p>Ok, so &#8220;Download&#8221;. But first i need to <strong>sign up</strong> for an Ovi Account!</p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi5-300x180.png" alt="OVI Signup" title="OVI Signup" width="300" height="180" class="alignnone size-thumbnail wp-image-698" /></p>
<p>After filling out all the forms, i get a &#8220;Thanks for signing up&#8221; page. By this time, i&#8217;ve <strong>all but forgotten</strong> what app i was going to purchase. </p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi2-300x180.png" alt="Browser History" title="Browser History" width="300" height="180" class="alignnone size-thumbnail wp-image-695" /></p>
<p>What would come in handy here would be&#8230; i don&#8217;t know, some sort of &#8220;Click here to continue your purchase&#8221; button perhaps? Instead, i have to use&#8230; the <strong>back button</strong>.</p>
<p>Finally, i tap the download button again. This time it loads the &#8220;Application Manager&#8221;, which after a while asks me if i want to continue installing &#8220;Angry Birds.&#8221;</p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi6-300x180.png" alt="App Download" title="App Download" width="300" height="180" class="alignnone size-thumbnail wp-image-699" /></p>
<p>At last, the app is installed. Eager to run it, i looked in my applications list, but couldn&#8217;t find it. Until i looked closer&#8230;</p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi6.7-300x180.jpg" alt="Find The App" title="Find The App" width="300" height="180" class="alignnone size-thumbnail wp-image-701" /></p>
<p>Yes, Angry Birds is represented by&#8230; a <strong>blue box</strong>.</p>
<p>Thankfully though, the app ran fine.</p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2010/01/ovi7-300x180.png" alt="Running" title="Running" width="300" height="180" class="alignnone size-thumbnail wp-image-700" /></p>
<p>All in all, i found the experience of downloading my free app to be unnecessarily frustrating. I can&#8217;t help but feel that nobody was really thinking when they designed the Ovi Store. From the constant page reloading, to the confusing appearance of the app on the device itself. I&#8217;d dread to think what would happen if i tried to buy an app.</p>
<p>I can safely say that currently the criticisms i have heard of the Ovi Store are well founded.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/platforms/the-ovi-store/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CSS Transform Exporter for Blender</title>
		<link>http://www.cuppadev.co.uk/projects/css-transform-exporter-for-blender/</link>
		<comments>http://www.cuppadev.co.uk/projects/css-transform-exporter-for-blender/#comments</comments>
		<pubDate>Wed, 16 Dec 2009 18:39:38 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[webkit]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=684</guid>
		<description><![CDATA[Following on from Creating CSS Animations, i have decided to release the exporter script used to create the animated orange test guy.
As the title implies, the exporter script runs in Blender. Simply construct a 2D scene using planes, add in an animation track, run the script and click Export. It&#8217;s as simple as that!
Each plane [...]]]></description>
			<content:encoded><![CDATA[<p>Following on from <a href="http://www.cuppadev.co.uk/projects/creating-css-animations/">Creating CSS Animations</a>, i have decided to release the exporter script used to create the animated orange test guy.</p>
<p>As the title implies, the exporter script runs in Blender. Simply construct a 2D scene using planes, add in an animation track, run the script and click Export. It&#8217;s as simple as that!</p>
<p>Each plane is exported as a HTML DIV. If present, any Ipos will be exported as CSS keyframes.  </p>
<p>The exporter even supports parenting, so you can build up complex hierarchies of elements which can easily be transformed in an animation, or even javascript.</p>
<p>Note that currently the exporter only supports Webkit-based browsers (i.e. Chrome, Safari, MobileSafari). It also has limited support for Firefox (sans animations).</p>
<p>For the curious, there are 3 examples:</p>
<ul>
<li><a href="http://www.cuppadev.co.uk/wp-content/uploads/2009/12/walk.html">Walking Orange Guy</a></li>
<li><a href="http://www.cuppadev.co.uk/wp-content/uploads/2009/12/transformTest.html">Transform Test (not animated)</a></li>
<li><a href="http://www.cuppadev.co.uk/wp-content/uploads/2009/12/testImage.html">Animated Image</a></li>
</ul>
<p>As for the actual exporter script, it&#8217;s <a href="http://github.com/jamesu/csstransformexport">available on github</a>.</p>
<p>Happy animating!</p>
<p><strong>EDIT</strong>: For those of you who for whatever reason want a video demonstration, there&#8217;s a video of it in action <a href="http://www.youtube.com/watch?v=rie9glkrFKo">on youtube</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/projects/css-transform-exporter-for-blender/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Thumbnails and Palettes in glgif</title>
		<link>http://www.cuppadev.co.uk/iphone/thumbnails-and-palettes-in-glgif/</link>
		<comments>http://www.cuppadev.co.uk/iphone/thumbnails-and-palettes-in-glgif/#comments</comments>
		<pubDate>Mon, 14 Dec 2009 23:52:32 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[iPhone]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[software development]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=664</guid>
		<description><![CDATA[Recently i incorporated support for creating thumbnails in glgif, the backend gif animation library used in Anim8gif.
Rather than taking the easy route out and attempting to load the gif using UIImage, i decided to take advantage of glgif&#8217;s decode routines to create an accurate representation of the current state of the gif playback. 
Put simply, [...]]]></description>
			<content:encoded><![CDATA[<p>Recently i incorporated support for creating thumbnails in <a href="http://github.com/jamesu/glgif">glgif</a>, the backend gif animation library used in <a href="http://itunes.com/apps/anim8gif">Anim8gif</a>.</p>
<p>Rather than taking the easy route out and attempting to load the gif using UIImage, i decided to take advantage of glgif&#8217;s decode routines to create an accurate representation of the current state of the gif playback. </p>
<p>Put simply, i took the palette texture which is generated for display, and decoded it into a new UIImage.</p>
<p>The actual process is triggered by assigning a delegate (thumbDelegate), which will be invoked when the next frame in the gif is decoded. The delegate is then cleared.</p>
<p>Simple, right?</p>
<h3>More Technical Details</h3>
<p>The format of a palette texture in GLES is as follows:</p>
<table style="border: 2px solid grey;">
<tr>
<td style="border: 2px solid black;padding: 3px;">Palette (16 or 256 entries)</td>
<td style="border: 2px solid black;padding: 3px;">Indexed Pixels (4bit or 8bit)</td>
</tr>
</table>
<p>The palette can either be 16 or 256 entries long, depending on the format you use. Likewise the pixel data will either use 4 bits or 8 bits. To keep things simple, glgif uses an 8bit palette with 3 8bit entries for the color (<strong>GL_PALETTE8_RGB8_OES</strong>).</p>
<p>(Note that an 8bit palette can be insufficient as a gif can actually display more than 256 colours across multiple frames, but this is a necessary trade-off for speed)</p>
<p>So in order to decode it:</p>
<ol>
<li>Read and decode the palette</li>
<li>Decode each pixel as an index into the palette</li>
<li>Using the decoded pixel data, create a new CoreGraphics bitmap context (using <strong>CGBitmapContextCreate</strong>)</li>
<li>Convert the bitmap context into a UIImage (using <strong>CGBitmapContextCreateImage</strong> and <strong>[UIImage imageWithCGImage:]</strong>)</li>
</ol>
<p>The resultant UIImage can then easily be used as a base to generate a sized down thumbnail of the gif, as illustrated below.</p>
<p><img src="http://www.cuppadev.co.uk/wp-content/uploads/2009/12/ex-thumbnails.png" alt="Example gif thumbnail" title="Example gif thumbnail" width="320" height="480" class="alignnone size-full wp-image-665" /></p>
<p>As always, the code for glgif is <a href="http://github.com/jamesu/glgif">hosted on github</a>, so feel free to check it out!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/iphone/thumbnails-and-palettes-in-glgif/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Creating CoreAnimation Animations</title>
		<link>http://www.cuppadev.co.uk/projects/creating-coreanimation-animations/</link>
		<comments>http://www.cuppadev.co.uk/projects/creating-coreanimation-animations/#comments</comments>
		<pubDate>Wed, 25 Nov 2009 16:58:22 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[problem solving]]></category>
		<category><![CDATA[software development]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=659</guid>
		<description><![CDATA[Moving on from Creating CSS Animations, i thought &#8220;How can i make this exporter more useful?&#8221;.
The answer is of course to completely remove Webkit from the equation, which leaves us with CoreAnimation. The end result being that the animation can be directly compiled into an iPhone or Mac OS X application.
Not going into much detail, [...]]]></description>
			<content:encoded><![CDATA[<p>Moving on from <a href="http://www.cuppadev.co.uk/projects/creating-css-animations/">Creating CSS Animations</a>, i thought <em>&#8220;How can i make this exporter more useful?&#8221;</em>.</p>
<p>The answer is of course to completely remove Webkit from the equation, which leaves us with CoreAnimation. The end result being that the animation can be directly compiled into an iPhone or Mac OS X application.</p>
<p>Not going <a href="http://www.opensource.apple.com/source/WebCore/WebCore-514/platform/graphics/mac/GraphicsLayerCA.mm">into much detail</a>, <a href="http://developer.apple.com/mac/library/documentation/cocoa/Conceptual/CoreAnimation_guide/Articles/WhatisCoreAnimation.html">CoreAnimation</a> is essentially the library used by Webkit to display and animate any elements which have been transformed by a CSS Transform.</p>
<p>The actual scene is simply constructed using transformed <strong>CALayers</strong>. As for the animation, a <strong>CAKeyframeAnimation</strong> is created and attached to each <strong>CALayer</strong>. In the case of multiple properties being animated at the same time, a <strong>CAAnimationGroup</strong> is used to group these animations together.</p>
<p>The end result is a handy animation class which creates both the scene and the related animation tracks. i.e.:</p>
<pre><code>
    CALayer *root = [self.view layer];

    // Make anim
    MyAnim *anim = [[MyAnim alloc] init];
    CALayer *animRoot = anim.root;
    [root addSublayer:animRoot];

    [anim play]; // easy!
</code></pre>
<p>As an example, the MyAnim class for the previously featured walking orange figure is as follows.</p>
<p><script src="http://gist.github.com/242862.js?file=Walking+CoreAnimation+Guy.m"></script></p>
<p>Which leads onto a repeat of the question, is there a real-world demand for such a tool yet?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/projects/creating-coreanimation-animations/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Creating CSS Animations</title>
		<link>http://www.cuppadev.co.uk/projects/creating-css-animations/</link>
		<comments>http://www.cuppadev.co.uk/projects/creating-css-animations/#comments</comments>
		<pubDate>Sun, 22 Nov 2009 22:50:18 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[webkit]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=645</guid>
		<description><![CDATA[CSS Transforms combined with animations are undoubtedly useful. Unfortunately though, the only way to create them is to manually input values and pretty much guess the result.
This methodology pretty much kills any creative aspirations anyone might have in making these animations. So while there are quite a few cool looking examples out there they lack [...]]]></description>
			<content:encoded><![CDATA[<p>CSS <a href="http://webkit.org/blog/130/css-transforms/">Transforms</a> combined with <a href="http://webkit.org/blog/138/css-animation/">animations</a> are undoubtedly useful. Unfortunately though, the only way to create them is to manually input values and pretty much guess the result.</p>
<p>This methodology pretty much kills any creative aspirations anyone might have in making these animations. So while there are quite a few <a href="http://girliemac.com/blog/2009/09/03/webkit-css-3d-local-db-demo/">cool</a> <a href="http://www.satine.org/research/webkit/snowleopard/snowstack.html">looking</a> examples out there they lack the glamour of say, <a href="http://www.weebls-stuff.com/">flash animations</a>.</p>
<p>It seems to me there is a need for a tool which allows anyone to create these css animations in a visual way. As far as i know, no such tool currently exists. So naturally, i set about making something myself.</p>
<p>Rather than make an entire tool from scratch though, i decided to simply write an exporter script for another tool &#8211; in this case, <a href="http://www.blender.org">Blender</a>.</p>
<p>Why Blender? Well, it exposes pretty much all of the information i require to construct both a scene and animation tracks. Also, since Blender handles 3D scenes, there is a potential to work with <a href="http://webkit.org/blog/386/3d-transforms/">3D CSS Transforms</a> in the future.</p>
<p>As an example, here&#8217;s a simple animation of an orange stick man walking across the screen. The stick man was both constructed and animated entirely within Blender, and exported using my export script.</p>
<p><a href="http://stuff.cuppadev.co.uk/walk.html"><img src="http://www.cuppadev.co.uk/wp-content/uploads/2009/11/example-walk-268x200.png" alt="example-walk" title="example-walk" width="268" height="200" class="alignnone size-thumbnail wp-image-649" /></a></p>
<p>And the scene as seen in blender:</p>
<p><a href="http://www.cuppadev.co.uk/wp-content/uploads/2009/11/Screen-shot-2009-11-22-at-22.19.24.png""><img src="http://www.cuppadev.co.uk/wp-content/uploads/2009/11/Screen-shot-2009-11-22-at-22.19.24-300x192.png" alt="Example animation in Blender" title="Example animation in Blender" width="300" height="192" class="alignnone size-thumbnail wp-image-648" /></a></p>
<p>Which is simply a set of planes linked together and animated. Really, it couldn&#8217;t be any simpler.</p>
<p>Currently the only browsers which seem to support both CSS transforms and animations are based off <a href="http://www.webkit.org">Webkit</a>. i.e. Safari and Chrome (including the iPhone and Android browsers).</p>
<p>Which leads onto the question, is there a real-world demand for such a tool yet?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/projects/creating-css-animations/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Making Money in the App Store: I Give Up</title>
		<link>http://www.cuppadev.co.uk/iphone/making-money-in-the-app-store-i-give-up/</link>
		<comments>http://www.cuppadev.co.uk/iphone/making-money-in-the-app-store-i-give-up/#comments</comments>
		<pubDate>Sat, 14 Nov 2009 23:04:47 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[iPhone]]></category>
		<category><![CDATA[software development]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=628</guid>
		<description><![CDATA[After almost a year of developing a and releasing a handful of iPhone apps to the App Store, i should be rolling in money, right?
Wrong.
In fact, i can officially reveal that with the exception of development contracts, my iPhone apps have netted me a grand total of:
£0
Yes, £0. It takes a lot of face up [...]]]></description>
			<content:encoded><![CDATA[<p>After almost a year of developing a and releasing a handful of iPhone apps to the <a href="http://itunes.apple.com/">App Store</a>, i should be <a href="http://appadvice.com/appnn/2009/02/ishoot-developer-makes-600000-in-one-month/">rolling</a> <a href="http://www.edibleapple.com/ifart-developer-makes-40000-in-2-days/">in</a> <a href="http://www.businessinsider.com/2008/9/iphone-developer-i-ll-do-anything-apple-tells-me-to-do-i-just-made-250k-on-the-app-store-in-two-months-aapl-">money</a>, right?</p>
<p>Wrong.</p>
<p>In fact, i can officially reveal that with the exception of development contracts, my iPhone apps have netted me a grand total of:</p>
<p style="font-size: 32px; font-weight: bold;">£0</p>
<p>Yes, <strong>£0</strong>. It takes a lot of face up to facts, but it can&#8217;t be much more blunt than that. Granted i did sell a few units, but these were nowhere near the amount required to release any real payment into my bank account.</p>
<h3>So what went wrong?</h3>
<p>Well to be quite honest, i didn&#8217;t really market my apps at all well. I was hoping that simply being in the App Store combined with a word-of-mouth viral networking effect combined with some online ads would be sufficient. From there i could perhaps get some feedback, and introduce improvements in line with demand. </p>
<p>Did it work? <strong>Far from it</strong>.</p>
<p>Sadly since the iPhone market is pretty much <strong>saturated</strong> with thousands of apps, this is pretty much impossible to accomplish. You&#8217;d probably have more chance winning the lottery than going with that approach.</p>
<p>I even tried making one of my apps free and promoting one of my paid apps in the description. The actual response in sales was negligible.</p>
<p>It seems to me the only viable ways of attracting people to a new app are:</p>
<ol>
<li>Getting it <strong>featured</strong> on the App Store</li>
<li>Pushing it out to as many <strong>review sites</strong> as you can ahead of time</li>
<li>Making it <strong>free</strong></li>
</ol>
<p>With regards to #3, not getting into in-depth analysis i will say this: if you have an app with a remotely useful purpose, people will consistently download it. </p>
<p>For example one of my apps, <a href="http://itunes.apple.com/apps/anim8gif">Anim8gif</a>, gets at least 20 downloads a week &#8211; mind you, that figure isn&#8217;t really useful since none of those 20 people bother to write a review or send any useful feedback.</p>
<p>Right now though, i&#8217;m a bit tired of spending my budget coming up with the next big idea with elaborate marketing that&#8217;s likely to bring in tons of revenue. So here&#8217;s what i&#8217;m going to do.</p>
<p>I&#8217;m just giving up on making money off my own iPhone apps altogether. All my current apps: <a href="http://itunes.com/apps/anim8gif">Anim8gif</a>, <a href="http://itunes.com/apps/vidsplit">VidSplit</a>, and <a href="http://itunes.com/apps/overthecam">Overthecam</a> are now free.</p>
<p>As for making future free apps, i am still undecided. Am i really getting anything out of the experience? Current signs point to no.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/iphone/making-money-in-the-app-store-i-give-up/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>The Trouble with CSS Transitions</title>
		<link>http://www.cuppadev.co.uk/quirks/the-trouble-with-css-transitions/</link>
		<comments>http://www.cuppadev.co.uk/quirks/the-trouble-with-css-transitions/#comments</comments>
		<pubDate>Fri, 23 Oct 2009 23:26:00 +0000</pubDate>
		<dc:creator>James Urquhart</dc:creator>
				<category><![CDATA[Quirks]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[webkit]]></category>

		<guid isPermaLink="false">http://www.cuppadev.co.uk/?p=587</guid>
		<description><![CDATA[Recently in a little experiment, i made a rather cool demo which makes use of CSS Transforms, combined with CSS Transitions.
Note: Examples only work in Safari 4+, or other recent webkit-based browsers.

&#8220;Cool?&#8221; you say. Well admittedly i could have gone for something a bit more elaborate, however as it stands it pretty much serves its [...]]]></description>
			<content:encoded><![CDATA[<p>Recently in a little experiment, i made a rather cool demo which makes use of CSS Transforms, combined with CSS Transitions.</p>
<p><strong>Note:</strong> Examples only work in Safari 4+, or other recent webkit-based browsers.</p>
<p><a href="/assets/iphone/css-transitions/feet.html" target="_blank"><img src="http://www.cuppadev.co.uk/wp-content/uploads/2009/10/Screen-shot-2009-10-23-at-19.52.17-266x200.png" alt="Footprint Demo" title="Footprint Demo" width="266" height="200" class="alignnone size-thumbnail wp-image-612" /></a></p>
<p>&#8220;<em>Cool</em>?&#8221; you say. Well admittedly i could have gone for something <a href="http://harrypotter.wikia.com/wiki/Marauder's_Map">a bit more elaborate</a>, however as it stands it pretty much serves its purpose &#8211; that is to demonstrate that using the magic of CSS Transitions you can create fast, useful web effects which run at acceptable framerates on an iPhone, and even on the desktop (since the tweening of properties is done by the browser).</p>
<p>However to get this admittedly simple demo working, i had to battle through a few odd issues with how these transitions operate.</p>
<h3>The problems</h3>
<p>To start off, resetting transitions is a bit tricky. Since properties are not processed immediately, you need to wait for the browser to detect you have reset transition values before you transition to any new values.</p>
<p>Thankfully a nice event called <strong>webkitTransitionEnd</strong> is provided which is fired as soon as a transition is complete, so you could conceivably use it to handle resetting the transition.</p>
<p>The only problem? <strong>webkitTransitionEnd</strong> seems to only fire when it feels like it. </p>
<p><a href="/assets/iphone/css-transitions/circles.html" target="_blank"><img src="http://www.cuppadev.co.uk/wp-content/uploads/2009/10/Screen-shot-2009-10-23-at-19.47.11-172x200.png" alt="Circles Demo" title="Circles Demo" width="172" height="200" class="alignnone size-thumbnail wp-image-611" /></a></p>
<p>The above example demonstrates the peculiarity of <strong>webkitTransitionEnd</strong>. The green/pink circle is meant to change colour every time the event is fired. Since there is an interval running every 100ms which changes the rotation of the circles, what typically happens 99.9% of the time is the transition never really ends, thus no event.</p>
<p>In general, the transition event seems to behave as follows:</p>
<table>
<tr>
<th>Setting&#8230;</th>
<th>Result</th>
</tr>
<tr>
<td>Initial transition (element just created)</td>
<td><strong style="color:red">FAIL</strong></td>
</tr>
<tr>
<td>Transition continuously (during transition)</td>
<td><strong style="color:yellow">MOSTLY FAIL</strong></td>
</tr>
<tr>
<td>Transition after a sufficient undefined delay</td>
<td><strong style="color:green">PASS</strong></td>
</tr>
</table>
<p>So safe to say, unless you&#8217;ve got a transition you aren&#8217;t going to mess about with then don&#8217;t rely on <strong>webkitTransitionEnd</strong>.</p>
<h3>Onto quirky platforms&#8230;</h3>
<p>Finally, with regard to the iPhone platform there are even more quirks. Compared to desktop Safari, the tweening acts quite differently.</p>
<p>One notable quirk is if you make a new element with a transition on Desktop safari, it performs that transition. If however you do the <strong>same</strong> thing on Mobile Safari, the transition starts at the <strong>end</strong>. Whether or not this is some bizarre timing issue, i have no idea.</p>
<p>So safe to say, while CSS Transitions are a powerful tool to use, beware of the quirks.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.cuppadev.co.uk/quirks/the-trouble-with-css-transitions/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
