<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>BlackBerry Developer Blog &#187; WebGL</title>
	<atom:link href="http://devblog.blackberry.com/tag/webgl/feed/" rel="self" type="application/rss+xml" />
	<link>http://devblog.blackberry.com</link>
	<description></description>
	<lastBuildDate>Fri, 24 May 2013 15:08:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='devblog.blackberry.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://1.gravatar.com/blavatar/9ef0a66c09615fa946c4179662398878?s=96&#038;d=http%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>BlackBerry Developer Blog &#187; WebGL</title>
		<link>http://devblog.blackberry.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://devblog.blackberry.com/osd.xml" title="BlackBerry Developer Blog" />
	<atom:link rel='hub' href='http://devblog.blackberry.com/?pushpress=hub'/>
		<item>
		<title>WebGL: 3D Gaming on the Web Arrives</title>
		<link>http://devblog.blackberry.com/2013/04/webgl-3d-gaming/</link>
		<comments>http://devblog.blackberry.com/2013/04/webgl-3d-gaming/#comments</comments>
		<pubDate>Tue, 09 Apr 2013 14:27:02 +0000</pubDate>
		<dc:creator>lmcdunna</dc:creator>
				<category><![CDATA[Adobe AIR Development]]></category>
		<category><![CDATA[Android Development]]></category>
		<category><![CDATA[BlackBerry World]]></category>
		<category><![CDATA[Events]]></category>
		<category><![CDATA[Game Development]]></category>
		<category><![CDATA[Interviews/Thought Leadership]]></category>
		<category><![CDATA[Java Development]]></category>
		<category><![CDATA[Native SDK Development]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Platform Services]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[3D Gaming]]></category>
		<category><![CDATA[games]]></category>
		<category><![CDATA[WebGL]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=14572</guid>
		<description><![CDATA[The Web and 3D have been to the dance many times together before, but they just never really hit it off. Sure, there were some successes which resulted in VRML in the mid 1990’s and Second Life in the early 2000’s. But numerous other attempts by countless startups didn’t make it. The reasons were many, [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=14572&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>The Web and 3D have been to the dance many times together before, but they just never really hit it off. Sure, there were some successes which resulted in <a href="http://en.wikipedia.org/wiki/VRML" target="_new">VRML</a> in the mid 1990’s and <a href="http://en.wikipedia.org/wiki/Second_Life" target="_new">Second Life</a> in the early 2000’s. But numerous other attempts by countless startups didn’t make it. The reasons were many, but mostly there just wasn’t a real solid business case for 3D in the browser. It was complicated to program, expensive to develop models, performance was spotty, and ensuring that all browsers would render the content the same way was certainly not guaranteed.</p>
<p>There was one place, however, where 3D made business sense: gaming (well, native gaming). 3D enjoyed, and still enjoys, a happy existence on PC and Console platforms. The question I always wondered was when will 3D in the browser be of high enough performance and quality across all platforms and browsers to support a solid business case for 3D on the Web? I believe the time has finally come. The confluence of mobile gaming, mobile Web app development, and a solid javascript API called <a href="http://en.wikipedia.org/wiki/WebGL" target="_new">WebGL</a> (a biding to the powerful and ubiquitous <a href="http://en.wikipedia.org/wiki/OpenGL" target="_new">OpenGL</a>), is fueling its arrival. I’m proud to say that BlackBerry has been very active in providing one of the first complete mobile WebGL implementations on the BlackBerry PlayBook, and has also brought this capability to BlackBerry 10.</p>
<p><span id="more-14572"></span></p>
<p>WebGL provides developers with the ability to write immersive, high-performance, console-quality, 2D and 3D games accessible directly on your BlackBerry 10 smartphone. This could be done directly though the browser, or even better, directly by a BlackBerry <a href="http://developer.blackberry.com/html5/" target="_new">HTML5/WebWorks</a> application. By building and packaging your HTML5 application into a bar file (a BlackBerry app file container), it enjoys the same rights and privileges as a native application. These apps look, feel, and behave as native apps, as they don’t run inside a browser context. They don’t need to be online to work, and they can leverage great BlackBerry services like the <a href="http://developer.blackberry.com/html5/documentation/webworks-payment_service.html" target="_new">Payment Services SDK</a> and the <a href="http://developer.blackberry.com/html5/apis/blackberry.bbm.platform.html" target="_new">BBM APIs</a>. BlackBerry WebWorks apps can also be certified as <a href="http://developer.blackberry.com/builtforblackberry/" target="_new">Built for BlackBerry</a> affording them additional advantages.</p>
<p>The game shown below is called “Pearl Boy” and is a great example of what a WebGL application can do. It was developed by <a href="http://www.gootechnologies.com/" target="_new">Goo Technologies</a>, makers of the Goo Engine for GDC this year. It’s a 100% Web application, written using HTML5, Javascript, and of course, WebGL. The graphics and performance on the BlackBerry Z10 look great. Reflections, environment maps, pixel shaders, they’re all there. WebGL is the real deal.</p>
<p style="text-align:center;"><img alt="" src="http://rimdevblog.files.wordpress.com/2013/04/gdc-2013.jpg?w=450" /></p>
<p>If you want to learn more about programming with WebGL on BlackBerry, check out these additional <a href="http://devblog.blackberry.com/?s=webgl&amp;search=" target="_new">WebGL resources on the BlackBerry DevBlog</a>. I also recommend you check out the O’Reilly book, “<a href="http://www.amazon.com/WebGL-Up-Running-Tony-Parisi/dp/144932357X" target="_new">WebGL: Up and Running</a>” by Toni Parisi.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/14572/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/14572/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=14572&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2013/04/webgl-3d-gaming/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/649c096f0b8996184db6d0509771ecfb?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">lmcdunna</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2013/04/gdc-2013.jpg?w=450" medium="image" />
	</item>
		<item>
		<title>PeaksAndValleys: Limitless Landscape</title>
		<link>http://devblog.blackberry.com/2012/11/peaksandvalleys-landscape/</link>
		<comments>http://devblog.blackberry.com/2012/11/peaksandvalleys-landscape/#comments</comments>
		<pubDate>Tue, 13 Nov 2012 21:35:46 +0000</pubDate>
		<dc:creator>Erik O.</dc:creator>
				<category><![CDATA[Game Development]]></category>
		<category><![CDATA[How-to]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[web apps]]></category>
		<category><![CDATA[WebGL]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=12024</guid>
		<description><![CDATA[PeaksAndValleys is a sample WebGL application developed for the BlackBerry® platform. It is primarily a learning resource for developers implementing pure WebGL along with additional HTML5 gaming concepts. It has also been open-sourced on Github because, well, we love open source. To learn more about WebGL and HTML5 gaming, be sure to join our webinar [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=12024&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>PeaksAndValleys is a sample WebGL application developed for the BlackBerry® platform. It is primarily a learning resource for developers implementing pure WebGL along with additional HTML5 gaming concepts. It has also been <a href="https://github.com/blackberry/WebGL-Samples/tree/master/PeaksAndValleys" target="_new">open-sourced on Github</a> because, well, we love open source. To learn more about WebGL and HTML5 gaming, be sure to join our <a href="http://devblog.blackberry.com/2012/11/webcast-html5-gaming/" target="_new">webinar on November 15th</a>. If you’ve already developed an HTML5 game, join us on November 16th for the <a href="http://devblog.blackberry.com/2012/11/got-game-port-a-thon/" target="_new">BlackBerry Got Game Port-a-Thon</a> with some pretty awesome prizes – including trips to the Game Developer Conference 2013 in San Francisco, CA.</p>
<p><img class="aligncenter size-full wp-image-12025" title="TITLE_IMAGE" alt="TITLE_IMAGE" src="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-1.jpg?w=550&#038;h=284" width="550" height="284" /></p>
<p style="text-align:center;"><i>Now with 4500% more unique peaks and valleys.</i></p>
<p>On November 2nd, PeaksAndValleys 2.0 was uploaded to Github with a number of improvements. In the first release, we relied on a static map that was 150 by 150 vertices (22,500 total vertices.) When we’re talking about a map, we’re just referring to a grid of vertices where each vertex has a specific height.</p>
<p><span id="more-12024"></span></p>
<p><img class="aligncenter size-full wp-image-12026" title="" alt="" src="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-2.jpg?w=300&#038;h=300" width="300" height="300" /></p>
<p style="text-align:center;"><i>Bird’s eye view of a 33 by 33 vertex grid (map); each vertex has a specific height associated with it.</i></p>
<p>These 22,500 vertices were all generated during startup with randomized heights. It was a good initial implementation, but subject to a number of limitations:</p>
<ul>
<li>Maybe we want a fixed / persistent world to traverse.</li>
<li>We can’t expand the map much more due to performance reasons.</li>
<li>If the player runs in any direction for long enough, they will hit the edge of the map.</li>
</ul>
<p>Let’s take a look at each of these individually.</p>
<h3><strong>Fixed / Persistent World</strong></h3>
<p>One of the more common approaches to this problem is the use of a static source of data; in our case, a height map. This is the approach opted for in PeaksAndValleys 2.0. The following is an example of what a height map might look like:</p>
<p><img class="aligncenter size-full wp-image-12027" title="" alt="" src="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-3.jpg?w=300&#038;h=300" width="300" height="300" /></p>
<p style="text-align:center;"><i>Sample height map (originally 1024 by 1024 pixels).</i></p>
<p>Each pixel represents one vertex (or point) of the map, and the RGB colour of that pixel is used to determine the height of each vertex. In the case of PeaksAndValleys, the lowest height occurs at pure black (RGB = 0&#215;000000) and the highest height at pure white (0xFFFFFF).</p>
<p>Though the height map is only 1024 by 1024 pixels, we can apply a scaling factor to extend the map across larger distances in our WebGL world.</p>
<p>Depending on how smooth the source image is, we may get areas where there is a very low region next to a very high region. To prevent drastic changes in terrain, a smoothing algorithm was implemented that averages the height of each pixel with that of its neighbours.</p>
<p>And with this, we address the fixed / persistent world by using a static data source. We can quickly see how multiple height maps and randomized starting locations can expand the versatility of this approach.</p>
<h3><strong>Performance</strong></h3>
<p>As noted, the first release of PeaksAndValleys contained a static 150 by 150 vertex area and expanding to a larger number of vertices would have an impact on performance; so then what good is a 1024 by 1024 height map?</p>
<p>In our case, we’re actually only loading a 121 by 121 region at any given time. As the player traverses the terrain, we are continuously reloading the surrounding region data (with the player at the center.) This means that as the player moves around, terrain in their vicinity is continually loaded from the height map.</p>
<p>There is a lot of processing that needs to go on in order to keep loading terrain &#8212; so much that if we do this processing on the main application thread, we’ll see a drop to roughly 30 frames per second. This is where Web Workers come in, for which the implementation can be seen in <a href="https://github.com/blackberry/WebGL-Samples/blob/master/PeaksAndValleys/js/GLTerrainWorker.js" target="_new">GLTerrainWorker.js</a>.</p>
<p>A Web Worker allows a separate thread to perform actions without interfering with our main application thread. Our main application thread is where all of our interactions and rendering are performed, so if we can minimize the work being done there, we can improve our frames per second and responsiveness.</p>
<p>Web Workers aren’t without their limitations. Specifically affecting us, we cannot:</p>
<ul>
<li>Access the DOM. This eliminates WebGL rendering directly on the Web Worker.</li>
<li>Pass objects with functions between the main application thread and Web Worker.</li>
</ul>
<p>These two limitations mean that while we can perform our processing on a Web Worker, we actually need to pass the processed data back to our main application thread in order to update our rendering objects. We do this via the <strong>onMessage</strong> listener and <strong>postMessage</strong> initiator to initialize our Web Worker with the data it will need, and then pass subsets of that data at various intervals. You can see this initialization and rendering update performed in <a href="https://github.com/blackberry/WebGL-Samples/blob/master/PeaksAndValleys/js/GLTerrain.js#L59" target="_new">GLTerrain.js</a>.</p>
<p>By offloading this processing to a Web Worker, we can continuously load more data off the main application thread, and only pass back the final data results to be assigned to our renderers. The end result is increasing our frames per second from roughly 30 to 50-60 frames per second; a huge win. To learn more about Web Workers, the following <a href="http://www.html5rocks.com/en/tutorials/workers/basics/" target="_new">HTML5 Rocks tutorial</a> is a great starting point.</p>
<h3><strong>Seamless Terrain</strong></h3>
<p>The final issue we had with our 150 by 150 static area was that when you run to the edge of the map, you hit the border. Loading data from a larger 1024 by 1024 area certainly extends the time before the player hits the border, but inevitably they will if they keep moving in one direction.</p>
<p>To counter this, the application continuously loads an area of pixels surrounding the player. As you reach any of the edges, data from the opposite side of the map will we used to populate that area. This produces a continuous terrain, even when travelling near the edges of the map.</p>
<p><img title="" alt="" src="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-4.jpg?w=300" width="300" />   <img title="" alt="" src="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-5.jpg?w=300" width="300" /></p>
<p style="text-align:center;"><i>Red cross represents the location of the player, white area represents the data we’ve loaded.</i></p>
<p>By wrapping the data that we load as we get close to the edges, we can in essence allow the player to run forever. You may notice that this image isn’t intended to be seamless (i.e. when wrapping around, the colours at the borders do not match up or flow together). This can be overcome by using a height map that is already seamless (i.e. it has already been processed to ensure that the pixels on the north side match those on the south, and those on the east match those on the west). In the case of PeaksAndValleys, our smoothing algorithm was implemented to wrap around the image when necessary (i.e. at the edges), thus turning non-seamless images into height map data that is seamless.</p>
<h3><strong>Preprocessing Data</strong></h3>
<p>To obtain usable height map data, we must:</p>
<ul>
<li>Read a source image; in our case 1024 by 1024 pixels.</li>
<li>Perform height calculations.</li>
<li>Calculate the normal (perpendicular vector) of each point.</li>
<li>Calculate texture coordinates.</li>
</ul>
<p>This involved quite a bit of math and processing power. Mathematical calculations are an area where JavaScript performance has historically suffered. Attempting to perform these actions while the application loads leads to a PC load time around 5 seconds and a mobile device load time around 20-25 seconds.</p>
<p>This also means that we are re-calculating data on every load just to get the same result as our previous run &#8212; a very inefficient approach.</p>
<p>To address this, a Node.js <a href="https://github.com/blackberry/WebGL-Samples/tree/master/PeaksAndValleys/tools/preprocessor" target="_new">preprocessor tool</a> was created that reads in an image, along with some parameters, and generates a <strong>json</strong> file with the resulting vertex, normal, and texture data required by our WebGL application. On a 1024 x 1024 image, the resulting file is roughly 50mb in size. Originally, this file was closer to 120mb, however by truncating decimal points to 5 significant digits the overall size was reduced.</p>
<p>As a result our application doesn’t actually process any data on load. Instead of feeding in an image, we are now feeding in the output <strong>json</strong> file with all calculations already in place. That being said, we are still loading a 50mb file which does take some time, but now we’ve managed to cut the loading time closer to 5 seconds on a mobile device.</p>
<p>Using preprocessed data also minimizes the amount of work the Web Worker has to do, as it will simply retrieve the appropriate data based on the user’s location and pass that data back to the main application thread.</p>
<h3><strong>Summary</strong></h3>
<p>Ultimately, PeaksAndValleys has seen a large number of improvements in the terrain implementation. From preprocessing / generating seamless height maps to leveraging Web Workers and minimizing strain on the main application thread, we now have a much more versatile world.</p>
<p>There are still some issues such as terrain popping into view as you move about. There is also room for optimization by only loading a cone of data in the player’s field of view (as opposed to a square in all directions around the player). These are topics that will be addressed in the next release.</p>
<p>For more information on this project, be sure to check out the Github release. Feel free to leave questions there, or reach out to me directly on Twitter® via <a href="https://twitter.com/WaterlooErik" target="_new">@WaterlooErik</a>.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/12024/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/12024/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=12024&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2012/11/peaksandvalleys-landscape/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/0788073ae3c85a2b7e415fa106832a51?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">eoros</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-1.jpg" medium="image">
			<media:title type="html">TITLE_IMAGE</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-2.jpg" medium="image" />

		<media:content url="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-3.jpg" medium="image" />

		<media:content url="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-4.jpg" medium="image" />

		<media:content url="http://rimdevblog.files.wordpress.com/2012/11/peaksandvalleys-5.jpg" medium="image" />
	</item>
		<item>
		<title>[Webcast] HTML5 Gaming with BlackBerry 10</title>
		<link>http://devblog.blackberry.com/2012/11/webcast-html5-gaming/</link>
		<comments>http://devblog.blackberry.com/2012/11/webcast-html5-gaming/#comments</comments>
		<pubDate>Fri, 09 Nov 2012 19:01:40 +0000</pubDate>
		<dc:creator>Erik O.</dc:creator>
				<category><![CDATA[Announcements]]></category>
		<category><![CDATA[Events]]></category>
		<category><![CDATA[Game Development]]></category>
		<category><![CDATA[How-to]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Canvas2D]]></category>
		<category><![CDATA[games]]></category>
		<category><![CDATA[gaming]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[Web Games]]></category>
		<category><![CDATA[WebGL]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=11976</guid>
		<description><![CDATA[The gap between the desktop and mobile web is rapidly shrinking as performance and functionality are on a path towards convergence. An area that has been (and will continue to be) heavily impacted by these advancements is the gaming space. I am pleased to be presenting an upcoming webcast on the current state of HTML5 [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=11976&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><img class="aligncenter size-full wp-image-11977" title="peaks" alt="TITLE_IMAGE" src="http://rimdevblog.files.wordpress.com/2012/11/peaks.jpg?w=501&#038;h=310" height="310" width="501" /></p>
<p>The gap between the desktop and mobile web is rapidly shrinking as performance and functionality are on a path towards convergence. An area that has been (and will continue to be) heavily impacted by these advancements is the gaming space. I am pleased to be presenting an upcoming webcast on the current state of HTML5 Gaming on BlackBerry® 10 and what the future holds for mobile web game developers.</p>
<p>During the webcast, the primary focus will be on Canvas2D and WebGL, with a deeper look at <a href="https://github.com/blackberry/WebGL-Samples/tree/master/PeaksAndValleys">PeaksAndValleys</a>; an open source WebGL sample created to demonstrate common HTML5 game components. We will also discuss topics such as audio, social integration, and monetization to name a few.</p>
<p>Unlike previous webcasts we will be presenting from the <a href="https://www.communitech.ca/communitech-hub/">Communitech Hub</a> located in Kitchener, Ontario while live streaming the content to the internet. This means that if you’re in the area, you’re more than welcome to drop in and ask what questions you have face to face!</p>
<p>To join as an online attendee, you can register at the following URL:</p>
<p><a href="http://www.blackberrydeveloperevents.com/events/webcast/attend/1074214004">http://www.blackberrydeveloperevents.com/events/webcast/attend/1074214004</a></p>
<p>If you will be attending in person at the Communitech Hub, we ask that you please register here instead:</p>
<p><a href="http://www.eventbrite.ca/event/4782690155">http://www.eventbrite.ca/event/4782690155</a></p>
<p>The presentation itself will be held on <b>November 15, 2012 </b>starting at <b>11:00AM EST</b> and will run for approximately <b>45 minutes</b> with additional time allocated for question and answer. During that time, we will be taking questions from attendees both in the room and online.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/11976/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/11976/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=11976&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2012/11/webcast-html5-gaming/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/0788073ae3c85a2b7e415fa106832a51?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">eoros</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/11/peaks.jpg" medium="image">
			<media:title type="html">peaks</media:title>
		</media:content>
	</item>
		<item>
		<title>The Missing (WebGL) Link</title>
		<link>http://devblog.blackberry.com/2012/10/missing-webgl-link/</link>
		<comments>http://devblog.blackberry.com/2012/10/missing-webgl-link/#comments</comments>
		<pubDate>Thu, 04 Oct 2012 14:12:40 +0000</pubDate>
		<dc:creator>Erik O.</dc:creator>
				<category><![CDATA[Game Development]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[BlackBerry 10]]></category>
		<category><![CDATA[PlayBook 2.1]]></category>
		<category><![CDATA[WebGL]]></category>
		<category><![CDATA[WebGLRenderingContext]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=11416</guid>
		<description><![CDATA[The BlackBerry® PlayBook™ tablet was one of the first mobile devices to introduce full WebGL™ support with the BlackBerry PlayBook OS 2.0 release. However some users on the BlackBerry PlayBook OS 2.1 beta release may have noticed something similar to the following when visiting a website that required WebGL. Even though the content does actually [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=11416&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><img class="aligncenter size-full wp-image-11421" title="" src="http://rimdevblog.files.wordpress.com/2012/10/webgl-render.jpg?w=550&#038;h=268" alt="TITLE_IMAGE" width="550" height="268" /></p>
<p>The BlackBerry® PlayBook™ tablet was one of the first mobile devices to introduce full WebGL™ support with the BlackBerry PlayBook OS 2.0 release. However some users on the BlackBerry PlayBook OS 2.1 beta release may have noticed something similar to the following when visiting a website that required WebGL.</p>
<p>Even though the content <strong>does</strong> actually render, not all WebGL samples present the same behavior. The underlying issues stems from the implementation of the <strong>WebGLRenderingContext</strong> object. In BlackBerry PlayBook OS 2.0, this object was implemented and exposed, allowing developers and users alike to enjoy the benefits of a platform that supports 3D graphics.</p>
<p>In the subsequent updates to the beta BlackBerry PlayBook OS 2.1, an update to the underlying WebKit engine left the WebGLRenderingContext object implemented, but not publicly exposed. For samples and applications that look to this object as an indicator of whether WebGL is supported on a platform, it appeared as if we did not support WebGL.</p>
<p>I’m happy to announce that in the BlackBerry PlayBook OS 2.1 release, the WebGLRenderingContext object will be exposed once again! Big thanks to the browser teams for making sure that this fix was included in both the coming BlackBerry PlayBook OS update and current BlackBerry® 10 releases.</p>
<p>If you’re working on any WebGL applications, drop us a line and tell us about it!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/11416/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/11416/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=11416&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2012/10/missing-webgl-link/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/0788073ae3c85a2b7e415fa106832a51?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">eoros</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/10/webgl-render.jpg" medium="image">
			<media:title type="html">TITLE_IMAGE</media:title>
		</media:content>
	</item>
		<item>
		<title>PeaksAndValleys Added to WebGL-Samples Repository</title>
		<link>http://devblog.blackberry.com/2012/07/peaksandvalleys-webgl-sample/</link>
		<comments>http://devblog.blackberry.com/2012/07/peaksandvalleys-webgl-sample/#comments</comments>
		<pubDate>Fri, 06 Jul 2012 14:11:12 +0000</pubDate>
		<dc:creator>Erik O.</dc:creator>
				<category><![CDATA[Announcements]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[github]]></category>
		<category><![CDATA[repository]]></category>
		<category><![CDATA[samples]]></category>
		<category><![CDATA[WebGL]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=10083</guid>
		<description><![CDATA[The PeaksAndValleys WebGL sample is now available at the WebGL-Samples Github repository.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=10083&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p style="text-align:center;"><img class="aligncenter size-full wp-image-10084" src="http://rimdevblog.files.wordpress.com/2012/07/webgl-sample.jpg?w=550&#038;h=273" alt="TITLE_IMAGE" width="550" height="273" /></p>
<p>At <a href="http://www.fitc.ca/events/about/?event=124" target="_new">FITC Toronto</a> this year, <a href="http://twitter.com/dustinmalik" target="_new">Dustin Malik</a> and I presented a session for developers interested in WebGL &#8212; where it is today and where WebGL is headed. I made a promise to open source my WebGL sample (previously known as Webscape) and I’m happy to say that it’s available today!</p>
<p>Two months prior to FITC, I had very little personal experience with WebGL development. I spent two weeks researching WebGL technologies and frameworks with the ultimate goal being to pack as many topics that a typical WebGL game dev might come across into one sample.</p>
<p>Over the next week, I tried various WebGL frameworks. I managed to make quite a bit of progress using <a href="https://github.com/mrdoob/three.js/" target="_new">Three.js</a> before I hit my first issue and realized that without knowing how WebGL works under the hood, I’d have a difficult time resolving my own issues. Imagine trying to debug a public framework like jQuery without having knowledge of JavaScript®.</p>
<p>So I started over, this time using pure WebGL as my approach and <a href="http://www.learningwebgl.com" target="_new">www.learningwebgl.com</a> as my primary resource of information. The next three weeks saw the majority of my coding. I wanted to take the project as far as I could before the FITC conference.</p>
<p>In that time, I managed to implement forms of terrain generation and pathing, ambient and directional lighting, a skybox, virtual controls, and texture blending. It was an adventure, to say the least. I left a week for debugging and touch-ups, and then it was conference time.</p>
<p>Primarily, this sample is intended to be a learning resource. As such, it has been open sourced at our <a href="https://github.com/blackberry/WebGL-Samples" target="_new">WebGL-Samples Github repository</a>. Feel free to take it, rip it apart, and build up something grander. This sample is not perfect, but it does take a lot of concepts and brings them into one place. Feedback, questions, and contributions are all welcome. If you have your own projects you’re working on, I’d be ecstatic to see them!</p>
<p>Finally, I wanted to say thank you to the following people whose contributions to the online community helped me greatly along my way: <a href="http://www.learningwebgl.com/" target="_new">Learning WebGL</a>, <a href="https://github.com/toji/gl-matrix" target="_new">Brandon Jones</a>, <a href="https://github.com/jeromeetienne/virtualjoystick.js" target="_new">Jerome Etienne</a>, <a href="http://chandler.prallfamily.com/2011/06/blending-webgl-textures" target="_new">Chandler Prall</a>, <a href="http://webreflection.blogspot.ca/2010/09/fragment-and-vertex-shaders-my-way-to.html" target="_new">Andrea Giammarch</a>, <a href="http://paulirish.com/2011/requestanimationframe-for-smart-animating" target="_new">Paul Irish and Erik Möller</a>, <a href="https://github.com/mrdoob/three.js/" target="_new">Ricardo Cabello</a>, and the <a href="https://developer.valvesoftware.com/wiki/Skybox_(2D)_with_Terragen" target="_new">Valve Developer Community</a>.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/10083/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/10083/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=10083&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2012/07/peaksandvalleys-webgl-sample/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/0788073ae3c85a2b7e415fa106832a51?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">eoros</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/07/webgl-sample.jpg" medium="image">
			<media:title type="html">TITLE_IMAGE</media:title>
		</media:content>
	</item>
		<item>
		<title>Packaged WebGL Game Now Available in BlackBerry App World</title>
		<link>http://devblog.blackberry.com/2012/03/download-tunneltilt/</link>
		<comments>http://devblog.blackberry.com/2012/03/download-tunneltilt/#comments</comments>
		<pubDate>Tue, 27 Mar 2012 18:32:59 +0000</pubDate>
		<dc:creator>Eduardo P-L.</dc:creator>
				<category><![CDATA[Game Development]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[apps]]></category>
		<category><![CDATA[blackberry playbook]]></category>
		<category><![CDATA[Community]]></category>
		<category><![CDATA[demo]]></category>
		<category><![CDATA[game development]]></category>
		<category><![CDATA[games]]></category>
		<category><![CDATA[github]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[playbook apps]]></category>
		<category><![CDATA[PlayBook games]]></category>
		<category><![CDATA[ripple]]></category>
		<category><![CDATA[TunnelTilt]]></category>
		<category><![CDATA[WebGL]]></category>
		<category><![CDATA[webworks]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=8769</guid>
		<description><![CDATA[The open sourced TunnelTilt demo is now available for download in BlackBerry App World.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=8769&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p style="text-align:center;"><img class="aligncenter size-full wp-image-8781" src="http://rimdevblog.files.wordpress.com/2012/03/img_000001021.jpg?w=550&#038;h=322" alt="TITLE_IMAGE" width="550" height="322" /></p>
<p>Last month, <a href="http://devblog.blackberry.com/author/adamstan1/" target="_new">Adam Stanley</a> discussed the giant leap forward that our <a href="http://devblog.blackberry.com/2012/02/playbook-native-webgl-development/" target="_new">WebGL support</a> has brought to web development for the BlackBerry® PlayBook™ tablet, Adam wrote:</p>
<blockquote><p>“&#8230;you could build a standalone BlackBerry application, powered by WebGL, using theBlackBerry WebWorks SDK, and distribute that app to other BlackBerry PlayBook tablet users through the BlackBerry App World™ storefront.”</p></blockquote>
<p>To get a true understanding of what you can do with WebGL, we’ve made our demo game “TunnelTilt” <a href="http://appworld.blackberry.com/webstore/content/79082" target="_new">available for download</a> in BlackBerry App World™ &#8211; check it out. This is really the power of our Web tools. This game feels native.</p>
<p>We took the TunnelTilt demo, which we had previously open sourced in the <a href="https://github.com/blackberry/WebGL-Samples" target="_new">WebGL-Samples</a> repository on our GitHub page, packaged it with our WebWorks SDK, signed the BAR file and submitted to BlackBerry App World – just like any other game. TunnelTilt is implemented completely using WebGL (<a href="http://www.khronos.org/webgl/" target="_new">specification</a>, <a href="http://en.wikipedia.org/wiki/Webgl" target="_new">Wikipedia</a>) and it is indistinguishable from any other BlackBerry PlayBook tablet application in how it performs!</p>
<p><a href="http://appworld.blackberry.com/webstore/content/79082" target="_new">Download TunnelTilt today</a> and see if you can get through all five levels!</p>
<p>This game is also a great example of RIM’s continued commitment to the open source community. The source code, runtime, and tooling are all available on our <a href="http://blackberry.com/developers" target="_new">developer site</a> and <a href="https://github.com/blackberry/WebGL-Samples" target="_new">Github page</a>.</p>
<h3><strong>Additional Readings</strong></h3>
<ul>
<li><a href="http://devblog.blackberry.com/2012/02/playbook-native-webgl-development/" target="_new">Native WebGL: A giant leap for the web development community on the BlackBerry PlayBook</a> – Detailed overview of WebGL and its support on the BlackBerry PlayBook.</li>
<li><a href="http://openbbnews.wordpress.com/2011/11/16/tunneltilt-github/" target="_new">TunnelTilt – From GitHub to Your PlayBook</a> – Step-by-step on how to compile the sources into an app.</li>
</ul>
<p>Let us know what you think of our WebGL support and make sure to let us know as your Web apps launch.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/8769/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/8769/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=8769&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2012/03/download-tunneltilt/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/f662e1b4e55509b4205db5b8187e374f?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">eduardopele</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/03/img_000001021.jpg" medium="image">
			<media:title type="html">TITLE_IMAGE</media:title>
		</media:content>
	</item>
		<item>
		<title>Native WebGL: A giant leap for the web development community on the BlackBerry PlayBook</title>
		<link>http://devblog.blackberry.com/2012/02/playbook-native-webgl-development/</link>
		<comments>http://devblog.blackberry.com/2012/02/playbook-native-webgl-development/#comments</comments>
		<pubDate>Wed, 22 Feb 2012 16:36:00 +0000</pubDate>
		<dc:creator>Adam S.</dc:creator>
				<category><![CDATA[Native SDK Development]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[app development]]></category>
		<category><![CDATA[blackberry playbook]]></category>
		<category><![CDATA[BlackBerry PlayBook OS 2.0]]></category>
		<category><![CDATA[BlackBerry web platform]]></category>
		<category><![CDATA[blackberry webworks]]></category>
		<category><![CDATA[github]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[WebGL]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=8460</guid>
		<description><![CDATA[The BlackBerry web platform for BlackBerry PlayBook tablet OS 2.0 supports WebGL - learn more about how to utilize this in your web development.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=8460&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p style="text-align:center;"><img class="aligncenter size-full wp-image-8462" title="Image courtesy of Khronos Group™" src="http://rimdevblog.files.wordpress.com/2012/02/webgl-logo.jpg?w=335&#038;h=174" alt="Image courtesy of Khronos Group™" width="335" height="174" /></p>
<p>BlackBerry® developers, you’re in for a treat. If you haven’t heard already, the BlackBerry web platform for <a href="http://www.blackberry.com/playbook" target="_new">BlackBerry® PlayBook™</a> tablet OS 2.0 supports WebGL. WebGL is an exciting new technology that is designed to offer advanced rendering capabilities and 3D Graphics for web development. Support for this feature was announced during the <a href="http://www.blackberrydevcon.com/americas/content/on-demand" target="_new">BlackBerry DevCon Americas 2011</a> keynote, and developers can use it as part of their <a href="http://developer.blackberry.com/html5" target="_new">HTML5 and BlackBerry® WebWorks™</a> web applications.</p>
<p>That’s right &#8211; if you wanted to, you could build a standalone BlackBerry application, powered by WebGL, using the BlackBerry WebWorks SDK, and distribute that app to other BlackBerry® PlayBook™ tablet users through the BlackBerry App World™ storefront.</p>
<p>This is a giant step forward for the web development community. As one of the first mobile development platforms to offer a native implementation of WebGL to its developers, BlackBerry provides the web development community a unique opportunity to push the boundaries of what they can do in their application content. WOW!</p>
<p><span id="more-8460"></span></p>
<h3><strong>This is amazing! Wait a sec, what’s WebGL?</strong></h3>
<p><a href="https://www.khronos.org/registry/webgl/specs/1.0/" target="_new">WebGL</a> is a cross-platform web standard that is designed to define a specification for enabling 3D graphics, powered by OpenGL ES 2.0. Using WebGL, you can create amazing graphics and subsequently more fun user experiences.</p>
<p>Here is a demo of a game named <a href="http://blackberry.github.com/WebGL-Samples/tunneltilt/" target="_new">TunnelTilt</a> running on BlackBerry PlayBook tablet OS 2.0. This sample app was created for the purpose of announcing WebGL at BlackBerry DevCon Americas 2011, and it has since been open sourced as the BlackBerry <a href="https://github.com/blackberry/WebGL-Samples/" target="_new">WebGL-Samples</a> repo in Github:</p>
<p style="text-align:center;"><span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='560' height='315' src='http://www.youtube.com/embed/TxazzRLa0qQ?version=3&#038;rel=1&#038;fs=1&#038;showsearch=0&#038;showinfo=1&#038;iv_load_policy=1&#038;wmode=transparent' frameborder='0'></iframe></span></p>
<p style="text-align:center;">[<a href="http://www.youtube.com/watch?v=TxazzRLa0qQ" target="_new">YouTube link for mobile viewing</a>]</p>
<p>The 3D graphics are rendered in an HTML5 canvas element that is hardware accelerated. This content can even be interacted with using JavaScript™ and the document object model (DOM).</p>
<p><code>function webGLStart() {<br />
var canvas = document.getElementById("lesson01-canvas");<br />
initGL(canvas);<br />
initShaders();<br />
initBuffers();</code></p>
<p>gl.clearColor(0.0, 0.0, 0.0, 1.0);<br />
gl.enable(gl.DEPTH_TEST);</p>
<p>drawScene();<br />
}</p>
<p><strong>Code sample:</strong> Learning WebGL Lesson 1 (<a href="http://learningwebgl.com/blog/?p=28">http://learningwebgl.com/blog/?p=28</a>)</p>
<h3><strong>Libraries and Frameworks</strong></h3>
<p>The WebGL code that provides highly visual graphics can be very complex, and may present a steep learning curve for new developers who are not familiar with the necessary principles. Building compelling WebGL content may require a deep understanding of trigonometry, geometry and Open GL features.</p>
<p>For example, after reading the following tutorial about <a href="http://learningwebgl.com/blog/?p=28" target="_new">how to draw a triangle and square</a> using WebGL, ask yourself if you were expecting to see so many lines of code. There may not be the higher level “draw” or “square” primitives and methods that a developer may find helpful in building real-world applications. WebGL offers lower-level primitives to its developers for building content. Why? It’s because WebGL is a language, not an application framework.</p>
<p>Don’t worry if that’s not what you were hoping to hear! Keep reading.</p>
<p><code>var square = gl.createBuffer();<br />
var square_vertices = [<br />
1.0, 1.0, 0.0,<br />
-1.0, 1.0, 0.0,<br />
1.0, -1.0, 0.0,<br />
-1.0, -1.0, 0.0<br />
];<br />
gl.bindBuffer(gl.ARRAY_BUFFER, square);<br />
gl.bufferData(gl.ARRAY_BUFFER, new Float32Array(square_vertices), gl.STATIC_DRAW);<br />
square.itemSize = 3;<br />
square.numItems = 4;<br />
</code></p>
<p><strong>Code sample:</strong> creating a square using basic WebGL constructs.</p>
<p>Many, and I mean many, developers have recognized the need to simplify WebGL development, and have spent a lot of time and energy building great libraries and frameworks for other developers to use. These libraries translate the low-level functionality of WebGL into higher-level APIs that are easier to use in the context of application development.</p>
<p>Another benefit to developers is that all of this is done using JavaScript APIs. So if you are already familiar with the JavaScript language, you are off to a great start. You can continue to use all of the existing JavaScript development tools that you currently use (e.g. Web Inspector, IDEs, Jslint, etc).</p>
<p>A few examples of community-led projects that web developers can use to build great WebGL content include <a href="http://mrdoob.github.com/three.js/" target="_new">three.js</a>, <a href="http://www.ambiera.com/copperlicht/" target="_new">CopperLicht</a>, <a href="http://scenejs.org/" target="_new">SceneJS</a>, <a href="http://www.glge.org/" target="_new">GLGE</a> and <a href="http://www.c3dl.org/" target="_new">Canvas 3d library</a>. There are many more, and the list will continue to grow. These libraries have traditionally focused on desktop browsers, which means authors will need to ensure they have successfully been optimized for mobile too. If you end up using a 3rd party library and find a bug, or if you are concerned about performance, please contact the appropriate author(s) and file an issue with them. Many of these frameworks exist as open source, meaning there is a great opportunity for improvement. As a community, we can work together to ensure these libraries work great on BlackBerry.</p>
<p><code>var rect = new THREE.Rectangle();<br />
rect.set(0, 0, 100, 100);</code></p>
<p><strong>Code sample:</strong> using three.js library to create a square. Only 2 lines of code!</p>
<h3><strong>Performance</strong></h3>
<p>So obviously there is a mobile version of the WebGL spec, right? Developers can expect to work with a specification that’s optimized for mobile devices and doesn’t have high memory or CPU requirements as desktop computers?</p>
<p>No, actually, there isn’t! OpenGL ES 2.0 does not have a mobile spec. So the same libraries that are used to produce WebGL content for powerful desktop hardware are also the same libraries used to build content for mobile devices.</p>
<p>What does this mean? It means that WebGL code that was designed for desktop browsers will need to be properly optimized to run on mobile smartphones and tablets. If not, you can expect to experience slow rendering or performance. This is very important for developers to recognize: one cannot assume that if it works on desktop, it will also work on mobile.</p>
<p><a href="http://rimdevblog.files.wordpress.com/2012/02/stopwatch.jpg"><img class="aligncenter size-full wp-image-8461" title="" src="http://rimdevblog.files.wordpress.com/2012/02/stopwatch.jpg?w=178&#038;h=238" alt="" width="178" height="238" /></a></p>
<h3><strong>Community Activity</strong></h3>
<p>Many of you have already seen our web platform team members participating in HTML5 and WebGL developer events worldwide. Recently we had delegates attend and present at events such as <a href="http://ongamestart.com/" target="_new">onGameStart</a> and <a href="http://www.newgameconf.com/" target="_new">New Game Conference</a>. Here are some highlights from these events:</p>
<blockquote><p>“WebGL is huge!!! And the fact that we will be the first tablet to have it built-in is extra-huge. We need to engage aggressively here to showcase our wares … interest in tablets is high.”</p></blockquote>
<p>- Laurent Hasson, Director Web Platform, Research In Motion® (RIM®) (onGameStart, Warsaw, Poland)</p>
<blockquote><p>“Good News! We are actually well positioned in terms of technology … There’s no reason we can’t have the best mobile web platform for gaming and game development.”</p></blockquote>
<p>- Genevieve Mak, Software Developer, RIM (New Game Conference, San Francisco, USA)</p>
<h3><strong>This is awesome. I love WebGL. What should I do now?</strong></h3>
<p>The following steps can help you learn how to build a WebGL-powered BlackBerry application:</p>
<p>1. The <a href="https://github.com/blackberry/WebGL-Samples/downloads" target="_new">BlackBerry open source project on Github</a> contains a <a href="https://github.com/blackberry/WebGL-Samples" target="_new">WebGL-Samples</a> repo where developers can download and/or contribute to code examples. In fact, the source code for the TunnelTilt sample app shown above is available in this repo! Download it today and see how JavaScript, HTML5 and WebGL are being used together to provide an awesome user experience.</p>
<p>2. Log into the <a href="http://www.blackberrydevcon.com/americas/content/on-demand" target="_new">DevCon on Demand</a> portal and read through the DEV46 session “Advanced Web Rendering: WebGL, Canvas and Gaming” session that was delivered at BlackBerry DevCon Americas 2011. Don’t miss this session, where Eli Fiddler and Ram Rajagopalan from RIM presented a great overview and best practices about using WebGL as well as some helpful code snippets and examples.</p>
<p>3. Take advantage of the many helpful learning resources you can find online, such as <a href="http://learningwebgl.com/" target="_new">learningwebgl.com</a> by Giles Thomas, which contains many tutorials and sample code. Remember: WebGL is a standard that the BlackBerry web platform supports. This means that most &#8211; if not all &#8211; tutorials, sample code or labs that you will find can be used to assist you in building WebGL content for BlackBerry. Check out the Mozilla Developer network for a robust collection of <a href="https://developer.mozilla.org/en/WebGL" target="_new">WebGL learning resources</a>.</p>
<p>4. Discover how you can use Ripple Mobile Emulator to <a href="http://devblog.blackberry.com/2011/12/ripple-beta-refresh-download/" target="_new">test WebGL content</a>, and the <a href="https://bdsc.webapps.blackberry.com/html5/documentation/ww_getting_started/what_is_a_webworks_app_1845471_11.html" target="_new">BlackBerry WebWorks SDK</a> to transform that content into a standalone BlackBerry application.</p>
<p>Did you find a bug? Report bugs in the <a href="https://www.blackberry.com/jira/secure/Dashboard.jspa+" target="_new">developer issue tracker</a>. Our goal is to provide developers with a world class WebGL experience on the BlackBerry platform, and we want to hear from you to ensure we are doing so.</p>
<p>Finally, I wanted to extend an invite to you to stay in touch with us. We want to know when you have created a WebGL application, framework and/or game content that runs great on the <a href="http://www.blackberry.com/playbook" target="_new">BlackBerry PlayBook</a> tablet. <a href="http://twitter.com/blackberrydev" target="_new">Send us a message</a> or ask a question in the comments below, or else share a great idea <a href="http://supportforums.blackberry.com/t5/Web-and-WebWorks-Development/bd-p/browser_dev" target="_new">in the forums</a>.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/8460/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/8460/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=8460&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2012/02/playbook-native-webgl-development/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/16f032fc46b780f6d9fa38b24a7f8ff2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">adamstan1</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/02/webgl-logo.jpg" medium="image">
			<media:title type="html">Image courtesy of Khronos Group™</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2012/02/stopwatch.jpg" medium="image" />
	</item>
		<item>
		<title>Not Your Grandfather&#8217;s Simulator: Ripple Beta Refresh Available for Download</title>
		<link>http://devblog.blackberry.com/2011/12/ripple-beta-refresh-download/</link>
		<comments>http://devblog.blackberry.com/2011/12/ripple-beta-refresh-download/#comments</comments>
		<pubDate>Tue, 20 Dec 2011 19:18:31 +0000</pubDate>
		<dc:creator>Ken W</dc:creator>
				<category><![CDATA[Announcements]]></category>
		<category><![CDATA[Java Development]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[API]]></category>
		<category><![CDATA[beta]]></category>
		<category><![CDATA[blackberry webworks]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[download]]></category>
		<category><![CDATA[Ripple Emulator]]></category>
		<category><![CDATA[WebGL]]></category>

		<guid isPermaLink="false">http://devblog.blackberry.com/?p=8167</guid>
		<description><![CDATA[The latest version of the Ripple Emulator v0.9.1 beta for Microsoft Windows and Mac is now available for download.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=8167&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><img class="aligncenter size-full wp-image-8168" title="" src="http://rimdevblog.files.wordpress.com/2011/12/ripple.jpg?w=400&#038;h=402" alt="" width="400" height="402" /></p>
<p>The latest version of the Ripple Emulator v0.9.1 beta for Microsoft® Windows and Mac is now <a href="http://developer.blackberry.com/html5/download/ripple" target="_new">available for download</a>. This beta refresh is designed to add more BlackBerry® WebWorks™ API support, debugging support, bug fixes and a designated area where you can place your application files to use with the Ripple Emulator without configuring your own local web server.</p>
<p>The full list of improvements:</p>
<ul>
<li>Support for JavaScript® breakpoints in Web Inspector</li>
<li>Added SSL support for Microsoft Windows®</li>
<li><a href="http://developer.blackberry.com/html5/apis/blackberry.io.file.html" target="_new">WebWorks File I/O API support</a></li>
<li>HTML5 Audio/Video support on Microsoft Windows</li>
<li>Local solution for emulating your app without configuring your own local web server</li>
<li>Ability to work offline after an initial connection to the Internet</li>
</ul>
<p><strong>Did you know that the Ripple Emulator v0.9.1 beta and BlackBerry® PlayBook™ OS 2.0 beta support WebGL in BlackBerry WebWorks?</strong></p>
<p>That’s right! The latest BlackBerry PlayBook tablet OS 2.0 beta developer release has support for WebGL when used inside of an HTML5 application packaged with BlackBerry WebWorks. When packaged with BlackBerry WebWorks, it is the same as any OpenGL based application on the platform.</p>
<p>On top of that, WebGL is also enabled in the Ripple Emulator so that you can test out your application with the desired screen size and incorporate touch events in order to get your application just right. We have even made the source code available for the <a href="https://github.com/blackberry/WebGL-Samples" target="_new">Tunnel Tilt WebGL demo</a> seen at <a href="http://www.blackberrydevcon.com/americas" target="_new">BlackBerry® DevCon Americas</a>.</p>
<p><span id="more-8167"></span></p>
<p><strong>How does the Local Solution work?</strong></p>
<p>This latest Ripple Emulator refresh is designed to provide a way to allow developers to emulate and test their applications residing on their development machine. Leveraging node.js which is run as part of Ripple’s build and deploy features, we effectively configure and run a local web server that can be accessed from the Ripple Emulator.</p>
<p>In order to test your local application, ensure that your application is stored on your file system at the locations listed below, and access your application by entering <a href="http://localhost:9900//index.html" rel="nofollow">http://localhost:9900//index.html</a> into the URL bar of the tool.</p>
<p>On Microsoft® Windows XP machines: Documents and Settings\&lt;Username&gt;\RippleSites<br />
On Microsoft® Windows 7 machines: Users\&lt;Username&gt;\RippleSites<br />
On Mac OS X machines: /Users/&lt;Username&gt;/RippleSites</p>
<p><strong>Playing HTML5 audio/video content in Ripple Emulator v0.9.1 beta</strong></p>
<p>Ripple Emulator v0.9.1 beta is designed to allow you to play HTML5 audio/video content so that you can ensure your media content is integrated correctly. While the tags are supported in the Ripple Emulator, they rely on the system having appropriate codecs installed for the media content type you are trying to use. The Ripple Emulator does not bundle any media codecs, so in the event that your content is not played in the Ripple Emulator, please download the appropriate codecs.</p>
<p><strong>What will happen to the Google® Chrome™ plug-in?</strong></p>
<p>The <a href="http://devblog.blackberry.com/2011/06/blackberry-webworks-tooling-evolved/" target="_new">existing Google Chrome plug-in</a> will remain available for download up until February 29th, 2012, when it will be removed from the extension store. The stand-alone Ripple Emulator architecture is evolving daily to allow us to provide a more extensive emulation framework with the ability to tailor the rendering and simulation to each platform Ripple supports.</p>
<p>Our goal is to minimize the time our community needs to spend testing on simulators or devices by providing a best in class desktop browser-like emulation environment that comes as close as possible to runtime behavior. We encourage all our developers to make the transition to the current Ripple Emulator tool found on our site at <a href="http://developer.blackberry.com/html5/download/ripple" target="_new">http://developer.blackberry.com/html5/download/ripple</a>.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/rimdevblog.wordpress.com/8167/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/rimdevblog.wordpress.com/8167/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=devblog.blackberry.com&#038;blog=17235680&#038;post=8167&#038;subd=rimdevblog&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://devblog.blackberry.com/2011/12/ripple-beta-refresh-download/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/3b422c1a037b89d4ddf5bef834dbdeef?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">kjwallis</media:title>
		</media:content>

		<media:content url="http://rimdevblog.files.wordpress.com/2011/12/ripple.jpg" medium="image" />
	</item>
	</channel>
</rss>
