<?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>Bubble Foundry &#187; HTML5</title>
	<atom:link href="http://www.bubblefoundry.com/blog/tag/html5/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.bubblefoundry.com</link>
	<description></description>
	<lastBuildDate>Fri, 03 Feb 2012 14:10:33 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<atom:link rel='hub' href='http://www.bubblefoundry.com/?pushpress=hub'/>
		<item>
		<title>WebViews in Android Versions </title>
		<link>http://www.bubblefoundry.com/blog/2010/11/webviews-in-android-versions/</link>
		<comments>http://www.bubblefoundry.com/blog/2010/11/webviews-in-android-versions/#comments</comments>
		<pubDate>Tue, 09 Nov 2010 14:07:20 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[WebView]]></category>

		<guid isPermaLink="false">http://www.bubblefoundry.com/?p=530</guid>
		<description><![CDATA[From what I understand: Native JSON methods don&#8217;t exist. Web SQL Database and Web Storage (things like localStorage, etc) aren&#8217;t supported. More as I find them. What do this all mean? In short, good luck making an advanced HTML5 web app for Android versions below 2.0, which unfortunately is still many devices.]]></description>
			<content:encoded><![CDATA[<p>From what I understand:</p>
<ul>
<li><a href="https://developer.mozilla.org/En/Using_JSON_in_Firefox">Native JSON methods</a> don&#8217;t exist.</li>
<li><a href="http://dev.w3.org/html5/webdatabase/">Web SQL Database</a> and <a href="http://dev.w3.org/html5/webstorage/">Web Storage</a> (things like localStorage, etc) aren&#8217;t supported.</li>
</ul>
<p>More as I find them.</p>
<p>What do this all mean? In short, good luck making an advanced HTML5 web app for Android versions below 2.0, which unfortunately is still many devices.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bubblefoundry.com/blog/2010/11/webviews-in-android-versions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>HTML5 TV</title>
		<link>http://www.bubblefoundry.com/blog/2010/06/html5-tv/</link>
		<comments>http://www.bubblefoundry.com/blog/2010/06/html5-tv/#comments</comments>
		<pubDate>Tue, 15 Jun 2010 17:19:13 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Apple]]></category>
		<category><![CDATA[canvas]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[HTTP live streaming]]></category>
		<category><![CDATA[Mobile Safari]]></category>
		<category><![CDATA[Safari]]></category>
		<category><![CDATA[SVG]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://www.bubblefoundry.com/?p=346</guid>
		<description><![CDATA[At the Dutch GTUG HTML5 Hackathon I decided to make an HTML5 TV. My HTML5 TV uses a whole grab bag of hot web features:  CSS 3, SVG, the canvas element, the video element, and HTTP live streaming video. In theory the TV works in all of the most recent versions of the Safari browser variants. [...]]]></description>
			<content:encoded><![CDATA[<p>At the <a href="http://sites.google.com/site/dutchgtug/events/event-hackathon-2">Dutch GTUG HTML5 Hackathon</a> I decided to make an <a href="http://www.bubblefoundry.com/html5tv/">HTML5 TV</a>.</p>
<p>My <a href="http://www.bubblefoundry.com/html5tv/">HTML5 TV</a> uses a whole grab bag of hot web features:  <a href="http://www.css3.info/">CSS 3</a>, <a href="http://en.wikipedia.org/wiki/Scalable_Vector_Graphics">SVG</a>, the <a href="http://en.wikipedia.org/wiki/HTML_canvas">canvas element</a>, the <a href="http://en.wikipedia.org/wiki/HTML5_video">video element</a>, and <a href="http://en.wikipedia.org/wiki/HTTP_Live_Streaming">HTTP live streaming video</a>. In theory the TV works in all of the most recent versions of the Safari browser variants. However, in Mobile Safari Apple puts a custom overlay over the video element, hiding the static, and prevents videos from playing automatically. I leave it up to you whether this is desirable. Given this, I recommend you use Safari 5 on OS X to view the page.</p>
<p>I can confirm that the latest version of Chrome on OS X does not play HTTP live streaming videos. If you can&#8217;t see HTTP live streaming video in your browser and are comfortable with its Javascript console, you can change the channels used like so:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">TV.<span style="color: #660066;">channels</span> <span style="color: #339933;">=</span> <span style="color: #009900;">&#91;</span>
  <span style="color: #009900;">&#123;</span>
    <span style="color: #3366CC;">'name'</span><span style="color: #339933;">:</span> <span style="color: #3366CC;">'BBB'</span><span style="color: #339933;">,</span>
    <span style="color: #3366CC;">'url'</span><span style="color: #339933;">:</span> <span style="color: #3366CC;">'http://cdn.kaltura.org/apis/html5lib/kplayer-examples/media/bbb_trailer_iphone.m4v'</span>
  <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#93;</span></pre></div></div>

<p>As you can see, <code>channels</code> is an array of anonymous objects with <code>name</code> and <code>url</code> properties and you can have as many as you want. I recommend doing this before you turn on the TV.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bubblefoundry.com/blog/2010/06/html5-tv/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://cdn.kaltura.org/apis/html5lib/kplayer-examples/media/bbb_trailer_iphone.m4v" length="3889885" type="video/mp4" />
		</item>
		<item>
		<title>HTML5 Video Transformation</title>
		<link>http://www.bubblefoundry.com/blog/2010/06/html5-video-transformation/</link>
		<comments>http://www.bubblefoundry.com/blog/2010/06/html5-video-transformation/#comments</comments>
		<pubDate>Fri, 04 Jun 2010 10:42:44 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://www.bubblefoundry.com/?p=342</guid>
		<description><![CDATA[This week I&#8217;ve been messing around with the HTML5 video element and have discovered you can do some pretty cool stuff. For instance, Mozilla shows how to do greenscreen image replacement while a video is played. This is very cool but there&#8217;s an annoying intermediate step required: since you cannot directly fetch raw frame image [...]]]></description>
			<content:encoded><![CDATA[<p>This week I&#8217;ve been messing around with the <a href="http://www.w3.org/TR/html5/video.html">HTML5 video element</a> and have discovered you can do some pretty cool stuff. For instance, Mozilla shows how to do <a href="https://developer.mozilla.org/En/Manipulating_video_using_canvas">greenscreen image replacement</a> while a video is played. This is very cool but there&#8217;s an annoying intermediate step required: since you cannot directly fetch raw frame image data from a video element, you must write each frame to an intermediate canvas element and then use its getImageData method to get raw image data you then transform and write to the final canvas element.</p>
<p>I brought this up in an email to the <a href="http://www.html5doctor.com/">HTML5 Doctors</a> last night. Remy suggested that I write up a blog post with some benchmarks, so here are some quick findings. You can find my code <a href="http://gist.github.com/425227">on GitHub</a>. In the example I take a video and invert all its colors, frame-by-frame.</p>
<p>Here&#8217;s my html:<br />
<script src="http://gist.github.com/425227.js?file=benchmark.html"></script></p>
<p>And my Javascript:<br />
<script src="http://gist.github.com/425227.js?file=benchmark.js"></script></p>
<p>Using Chrome 5.0.375.55 on OS X and its developer tools, I took a heap snapshot after loading <code>benchmark.html</code>. There were 2171 code (what, I don&#8217;t know) and 12463 objects, taking up 464.70 kb and 866.97 kb respectively. I then started the profiler and executed the following Javascript: <code>var video = document.getElementById("video); video.play();</code>. Once the video appeared to have stopped (confirmed by <code>video.ended</code>) I stopped the profiler and took another heap snapshot. This time there were 2202 code and 13037 objects taking up 471.58 kb and 922.11 kb. Not surprisingly the profile shows that <code>processFrame()</code> takes up the vast majority of execution time (77.63% self, 83.65% total).</p>
<p>This all leads me to believe that, at least for smaller videos like the <a href="http://homepage.mac.com/qt4web/myMovie.m4v">480 x 280 px video</a> I used from <a href="http://developer.apple.com/safari/library/documentation/AudioVideo/Conceptual/Using_HTML5_Audio_Video/ControllingMediaWithJavaScript/ControllingMediaWithJavaScript.html#//apple_ref/doc/uid/TP40009523-CH3-SW4">Apple&#8217;s documentation</a>, there are not significant performance issues when transforming videos frame-by-frame in Javascript.</p>
<p>That being said, I still find the process ineffiecent and would like to be able to get a sort of FrameData object directly from video elements, just like you can get an <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#imagedata">ImageData</a> object from canvas elements. This would mean I would only need to use one canvas element (<code>canvas2</code> in my example), instead of two.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bubblefoundry.com/blog/2010/06/html5-video-transformation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://homepage.mac.com/qt4web/myMovie.m4v" length="13485394" type="video/x-m4v" />
		</item>
		<item>
		<title>HTML5</title>
		<link>http://www.bubblefoundry.com/blog/2009/04/html5/</link>
		<comments>http://www.bubblefoundry.com/blog/2009/04/html5/#comments</comments>
		<pubDate>Wed, 08 Apr 2009 09:05:02 +0000</pubDate>
		<dc:creator>Peter</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[2D]]></category>
		<category><![CDATA[3D]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[apps]]></category>
		<category><![CDATA[canvas tag]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[GCal]]></category>
		<category><![CDATA[Gmail]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[graphics]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[iphone]]></category>
		<category><![CDATA[mobile apps]]></category>
		<category><![CDATA[RaphaëlJS]]></category>
		<category><![CDATA[web apps]]></category>
		<category><![CDATA[WebKit]]></category>

		<guid isPermaLink="false">http://www.bubblefoundry.com/?p=187</guid>
		<description><![CDATA[Google says it very succinctly: &#8220;HTML5 and WebKit pave the way for mobile web applications.&#8221; HTML5 is coming and it has a lot of interesting features, from audio and video support to local storage. Combine this with the fact that web apps are a particularly attractive way to reach many mobile platforms and the WebKit [...]]]></description>
			<content:encoded><![CDATA[<p>Google says it very succinctly: <a href="http://google-code-updates.blogspot.com/2009/04/html5-and-webkit-pave-way-for-mobile.html">&#8220;HTML5 and WebKit pave the way for mobile web applications.&#8221;</a> <a href="http://www.whatwg.org/specs/web-apps/current-work/">HTML5</a> is coming and it has a lot of interesting features, from audio and video support to local storage. Combine this with the fact that web apps are a particularly attractive way to reach many mobile platforms and the <a href="http://webkit.org">WebKit</a> browser found on the iPhone and Android platforms already implements many of the HTML5 standard, and you can see why HTML5 is so attractive for mobile apps.</p>
<p>With the ability of HTML5 web apps to store data locally and have the browser pass along the device&#8217;s hardware states, I believe that HTML5 wbe apps can do almost anything you could want an internet-using application to do. The only exception I can think of is high performance 3D graphics, as even great 2D graphics are possible with <a href="http://www.w3.org/Style/CSS/current-work#CSS3">CSS3</a> and HTML5&#8242;s canvas tag. Already there are nice libraries like <a href="http://raphaeljs.com/">RaphaëlJS</a> that work in the iPhone&#8217;s Mobile Safari.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bubblefoundry.com/blog/2009/04/html5/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

