<?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>CoderHump.com &#187; Opinion</title>
	<atom:link href="http://coderhump.com/archives/category/opinion/feed" rel="self" type="application/rss+xml" />
	<link>http://coderhump.com</link>
	<description>Game Development Technology, in Flash and Elsewhere</description>
	<lastBuildDate>Tue, 06 Jul 2010 17:18:41 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>PushButton Engine 101 Talk Video Now Available</title>
		<link>http://coderhump.com/archives/599</link>
		<comments>http://coderhump.com/archives/599#comments</comments>
		<pubDate>Sun, 11 Apr 2010 09:00:27 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Flash]]></category>
		<category><![CDATA[Opinion]]></category>
		<category><![CDATA[Publication]]></category>
		<category><![CDATA[Talks]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=599</guid>
		<description><![CDATA[
I gave a talk on the PushButton Engine at the Flash Gaming Summit a few weeks ago, titled &#8220;PushButton Engine 101.&#8221; It is available online, thanks to Adobe&#8217;s kind support in sponsoring FGS and recording the sessions. You can view the PushButton Engine 101 talk here. It&#8217;s about 40 minutes long. People seemed to like [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://partners.adobe.acrobat.com/p26778869/"><img src="http://coderhump.com/wp-content/uploads/2010/04/ben_talk-300x95.jpg" alt="" title="ben_talk" width="300" height="95" class="aligncenter size-medium wp-image-601" /></a></p>
<p>I gave a talk on the <a href="http://pushbuttonengine.com/">PushButton Engine</a> at the <a href="http://flashgamingsummit.com/">Flash Gaming Summit</a> a few weeks ago, titled &#8220;PushButton Engine 101.&#8221; It is available online, thanks to Adobe&#8217;s kind support in sponsoring FGS and recording the sessions. You can <a href="http://partners.adobe.acrobat.com/p26778869/">view the PushButton Engine 101 talk here</a>. It&#8217;s about 40 minutes long. People seemed to like it!</p>
<p>If you have comments/questions/feedback, I highly recommend visiting the <a href="http://pushbuttonengine.com/forum/viewtopic.php?f=15&#038;t=789&#038;start=0">PushButton Engine forums thread about it</a>.</p>
<p>The Flash Gaming Summit was a blast. I got to spend time with the guys from <a href="http://8bitrocket.com/">8bit Rocket</a>, with <a href="http://lostgarden.com/">Dan Cook</a>, and, of course, the crews from Adobe and Mochi. For the second conference, <a href="http://www.adamatomic.com/">Adam Saltsman</a> eluded me, but I had a great conversation with <a href="http://ncannasse.fr/">Nicolas Cannasse</a> about building companies. Lunch was spent with the PBE crew in attendance &#8211; <a href="http://www.jdconley.com/blog/">JD Conley</a>, Dion Whitehead, and a couple of others. I had a million other awesome conversations, too, which is why I love going to conferences. <img src='http://coderhump.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Other than the very early start, I thought FGS went a lot better than last year. (Perhaps because they had me on the <a href="http://www.flashgamingsummit.com/">advisory board</a> &#8211; conference organizers take note! <img src='http://coderhump.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> ) They had a solid tech track in addition to their business track. Maybe next year it can be two days &#8211; or just start a little later.</p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/599/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Flash on iPhone: My Experience</title>
		<link>http://coderhump.com/archives/517</link>
		<comments>http://coderhump.com/archives/517#comments</comments>
		<pubDate>Sat, 10 Oct 2009 02:37:52 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Flash]]></category>
		<category><![CDATA[Opinion]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=517</guid>
		<description><![CDATA[Hello, world! 
I wanted to post some real world information on Adobe&#8217;s latest big announcement, Adobe Flash Applications for iPhone. I participated in the pre-release beta along with several other very talented Flash developers. We got to be some of the first outsiders to work with the iPhone technology. To try out the tech, we [...]]]></description>
			<content:encoded><![CDATA[<p>Hello, world! <img src="http://pushbuttonlabs.com/wp-content/uploads/2009/09/flash_iphone_graphic.jpg" hspace=5 vspace=5 align=right></p>
<p>I wanted to post some real world information on Adobe&#8217;s latest big announcement, <a href="http://labs.adobe.com/technologies/flashcs5/appsfor_iphone/">Adobe Flash Applications for iPhone</a>. I participated in the pre-release beta along with several other very talented Flash developers. <b>We got to be some of the first outsiders to work with the iPhone technology.</b> To try out the tech, we wrote and shipped <a href="http://tradingstuff.pushbuttonlabs.com/">Trading Stuff in Outer Space</a> in just 8 days.</p>
<p>By the way, <b>if this is Flash on iPhone stuff is new to you</b>, you should definitely read <a href="http://www.adobe.com/devnet/logged_in/abansod_iphone.html">Aditya&#8217;s &#8220;Developing for the Apple iPhone using Flash&#8221;</a> article on adobe.com. In addition to being an all around great guy, Aditya was also a huge help in working through the very early beta issues we encountered. <a href="http://onflash.org/ted/2009/10/source-to-4-flash-iphone-apps.php">Ted Patrick posted some cool iPhone example apps with source</a>. (Not only does Ted make <a href="http://www.flickr.com/photos/15543694@N06/3989934309/">a good jedi</a>, he also helped me debug some rendering issues in Trading Stuff at the last minute. Thanks, Ted!) And Mike Chambers, who brought me into the program, has posted <a href="http://www.mikechambers.com/blog/2009/10/05/building-applications-for-the-iphone-with-flash/">more explanation with a lot of useful links for Flash/iPhone work</a>.</p>
<p>It&#8217;s worth stating emphatically that <b>Adobe has a large, talented team working hard on iPhone</b>. I couldn&#8217;t hope to properly thank all the Adobe folk who explained, demonstrated, debugged, and implemented through long sleepless nights to build this tech and fix bugs so we could ship Trading Stuff. Guys, you rock!</p>
<p>A brief history of Ben &#8211; I spent five years working on <a href="http://www.garagegames.com/">3D and 2D C++ game engine technology</a> before I moved to Flash, so I have a little different background than most Flash developers.</p>
<p>Ok &#8211; thanks and context out of the way. Let&#8217;s get to the meat. What&#8217;s it like to develop for the iPhone with Flash?</p>
<p>First, <b>the toolchain is fantastic</b>. All you do to get on the iPhone is write a Flash app however you like, and then (more or less) click the &#8220;compile IPA&#8221; button. You get an IPA, you deploy it on your device, and bob&#8217;s your uncle. That&#8217;s the easy part, and it has been that easy since day one. (For comparison, I&#8217;ve seen builds with pre-release and final XBox 360 SDKs, with homebrew PSP and Nintendo DS, with PS3 and Wii &#8211; they are all a lot harder to start building on.) Sometimes takes a while for all the optimization to happen, but you don&#8217;t need that unless you are packaging a release for distribution.</p>
<p>Deploying to the iPhone is the easy part. The hard part is <b>getting your content to run silky smooth and in an iPhone-friendly way</b>. What do I mean by that? Performance? Sure, you have to be careful with performance, but you also need to make sure you respect the touch interface&#8217;s limitations, that you obey Apple&#8217;s guidelines, that your art fits the device, and so forth. We spent as much time on that stuff as we did on performance in Trading Stuff.</p>
<p><img src="http://pushbuttonlabs.com/wp-content/uploads/2009/09/031044.jpg" hspace=5 vspace=5 width="240" height="320" align=left>The main things to watch out for is <b>rendering</b> &#8211; you must use hardware acceleration, which acts a lot like cacheAsBitmap &#8211; and <b>memory allocation</b> &#8211; the iPhone has very slow memory, so the GC running is the kiss of death. I could list a bunch of specifics but at this stage in the game, they would be out of date by the next SDK update. The best thing to do in this and all other optimization cases is to measure, find the biggest bottleneck, change it, and measure again to see if you got a win. Repeat until you have adequate performance.</p>
<p><a href="http://devwhy.blogspot.com/2009/10/flash-on-iphone.html">Louis Gerbarg posted a great analysis of the iPhone tech</a> based on Trading Stuff. Since I wrote Trading Stuff, I figured I should comment on it. <img src='http://coderhump.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>On the LLVM piece, Adobe has put in major effort to make this function properly. And it really does work. <b>Even on day one of the prerelease, the compiler worked pretty well.</b> Occasionally you&#8217;d hit an optimizer error &#8211; but it&#8217;s worth noting that in LLVM most optimization operations are separate from the backend. IMHO, Adobe was very smart to use LLVM as opposed to rolling their own or repurposing GCC, due to code maintainability and extensibility issues. You will notice that they have used LLVM before in <a href="http://labs.adobe.com/technologies/alchemy/">Alchemy</a>, so there&#8217;s prior experience here. And though Louis cites Apple not using LLVM for iPhone compilation as a weakness, Apple <i>is</i> using LLVM for their desktop compilation, which shows that LLVM is going to be a good choice long term.</p>
<p>For the resource bundling, that&#8217;s entirely my fault &#8211; <b>I chose to embed all my resources in my SWF and when the SWF was converted, it was converted to a binary with those resources in it.</b> I could have put them alongside the SWF and they would have been bundled as part of the IPA (in fact, this is the case for Default.png, which is treated as a normal file even though it has special behavior thanks to OS X). I&#8217;m not so sure about this linker behavior Louis is referring to; checking the <a href="http://developer.apple.com/mac/library/documentation/DeveloperTools/Conceptual/MachORuntime/Reference/reference.html#//apple_ref/c/tag/section">Mach-O segment reference</a> doesn&#8217;t reveal any insights beyond that yes, it is probably bad to keep the compressed version of assets in RAM. But Trading Stuff isn&#8217;t paging anyway, making it a non-issue.</p>
<p><img src="http://pushbuttonlabs.com/wp-content/uploads/2009/09/031044_4.jpg" hspace=5 vspace=5 width="240" height="320" align=right>For the rendering performance, <b>the build of Trading Stuff that is on the App Store is not using hardware acceleration at all</b>. And the ARM11 is a crappy chip for software rendering. I was showing a build at Adobe MAX that used hardware rendering, and it runs smoothly, like a real game should. I am waiting for a few bugs in Adobe&#8217;s SDK to be fixed, at which point I will release a new version on the store. The performance difference is night and day. I&#8217;ll post about that when I get the update out.</p>
<p>Let me put a caveat here: <b>the iPhone is something like a tenth of the machine your desktop PC is</b>. So if you want to do incredible 3d graphics and hand-optimize your assembly, maybe you should look into using XCode and Objective C, and build your content and code explicitly for the iPhone. However, if you know Flash (or have a project in it to port) and want to put something out quickly, this is a fantastic path, and worth a look. And it&#8217;s only going to improve from this very early version.</p>
<p>Time for some closing thoughts. Adobe has shown that they value the platform and want to bring their content to it by making some serious technology investments. <b>I hope that Apple will respect that, and work with Adobe to make sure Flash works well on the iPhone.</b></p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/517/feed</wfw:commentRss>
		<slash:comments>32</slash:comments>
		</item>
		<item>
		<title>OMG AS3: Some thoughts on AS3 &amp; Adobe/Community relations</title>
		<link>http://coderhump.com/archives/481</link>
		<comments>http://coderhump.com/archives/481#comments</comments>
		<pubDate>Sat, 08 Aug 2009 23:05:00 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Flash]]></category>
		<category><![CDATA[Opinion]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=481</guid>
		<description><![CDATA[Is AS3 any good at all? JavaScript keeps getting better &#8211; well, faster, anyway. C# is kicking ass in raw programming language chutzpah. haXe isn&#8217;t bad, either, and then there&#8217;s Objective-C for iPhone and Java and C/BREW on other mobile devices. And don&#8217;t forget the guys slaving away on AS2 and Flash Lite content!
What&#8217;s the [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://coderhump.com/wp-content/uploads/2009/08/kid_sullivan-217x300.jpg" hspace="20" alt="kid_sullivan" title="kid_sullivan" width="217" height="300" class="alignleft size-medium wp-image-495" /><b>Is AS3 any good at all?</b> JavaScript <a href="http://code.google.com/p/v8/">keeps</a> <a href="https://developer.mozilla.org/En/SpiderMonkey/Internals/Tracing_JIT">getting</a> <a href="http://webkit.org/blog/189/announcing-squirrelfish/">better</a> &#8211; well, faster, anyway. C# is kicking ass in raw programming language chutzpah. <a href="http://www.haxe.org/">haXe</a> isn&#8217;t bad, either, and then there&#8217;s Objective-C for iPhone and Java and C/BREW on other mobile devices. And don&#8217;t forget the guys slaving away on AS2 and Flash Lite content!</P></p>
<p>What&#8217;s the Flash community been saying about AS3 recently?</p>
<ul>
<li>Nicolas Canasse, the guy behind <a href="http://www.haxe.org/">haXe</a>, wrote an insightful article about <a href="http://ncannasse.fr/blog/the_failure_of_as3">whether AS3 has really delivered on its promises</a>. Lack of language feature velocity and lack of conciseness are his major points.</li>
<li>Joa Ebert, a talented Flash hacker (<a href="http://code.google.com/p/as3v/">AS3V</a>, <a href="http://blog.joa-ebert.com/2009/08/05/alchemy-for-actionscript/">AS3C</a>, etc.), is <a href="http://blog.joa-ebert.com/2009/08/06/this-is-an-outrage/">a little bit incensed</a> about Adobe&#8217;s troubles with involving the community. He cites some examples where they have <a href="https://bugs.adobe.com/jira/browse/FP-487">ignored<a> <a href="https://bugs.adobe.com/jira/browse/SDK-18954">code contributions</a>.</li>
<li>Even Andre Michelle, of <a href="http://www.hobnox.com/audiotool">Hobnox audioTool</a> fame, and one of the guys who helped drive the <a href="http://www.make-some-noise.info/">Make Some Noise</a> petition to get Adobe to improve audio in FP, has <a href="http://blog.andre-michelle.com/2009/as3-failure/">weighed in</a> in some areas where Flash should improve.</li>
</ul>
<p></p>
<p>I&#8217;ll be honest about where I stand on this. <b>Flash 9 is great, 10 even better.</b> For desktop/web interactive apps I am very happy. There are a lot of things that would be nice to see, and a few things that need to be fixed. But I would not have stopped doing <a href="http://www.garagegames.com/">C++ 3d game development</a> unless Flash was good.</p>
<p>I hope to see Adobe releasing a lot of improvements to AS3 (perhaps even an AS4 someday!), and there are some features, like generics, delegates, overloads, and enums, that would make my daily life easier. But the fact is that <b>being able to target a single, mostly consistent platform with AS3 is great</b>, and that there are nearly a billion people with Flash Player makes it very worthwhile. It is easy to create quality interactive content accessible by hundreds of millions of people in Flash, and that is a huge win.</p>
<p>If I had to agree with one complaint out of all the comments by my fellow Flash developers, it would be that <b>Adobe is having some trouble getting the community involved in what they are doing</b>. I can&#8217;t blame them &#8211; the Flash community is hugely varied in skill level and interest area. You have artists using it to create TV shows, <a href="http://www.homestarrunner.com/">web content</a>, and <a href="http://youtube.com/">deliver video</a>. At the same time, there are skilled coders building <a href="http://www.hobnox.com/audiotool">DAWs</a> and <a href="http://papervision3d.org/">3d renderers</a>. There are developers making <a href="http://kongregate.com/">games</a> and <a href="http://www.adobe.com/devnet/flex/tourdeflex/">building business applications</a>. I&#8217;m not sure there&#8217;s a broader set of users out there.</p>
<p>The best thing to do in a situation like this is to <b>stop treating Adobe like a big faceless company and start to get to know the people who work on Flash</b>. In the last two years I&#8217;ve had opportunities to visit the Player VM team, the Flash Builder team, and several of the Flash community managers and members. Everyone on those teams is, in my experience, willing to listen to your problems and interested in improving their product. <b>Obviously, they don&#8217;t implement every hair brained idea that I propose.</b> But they listen and there is forward motion.</p>
<p>So what does this come down to? I have to agree with Ted&#8217;s advice from his <a href="http://onflash.org/ted/2009/08/future-of-flash-platform.php">The Future of Flash</a> &#8211; be public about it. But also make sure you are reaching out to Adobe. <b>They are human and they respond a lot better to respectful conversation from people they know than they do to internet rage. </b> <img src='http://coderhump.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/481/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Making Flash The Console For The Web</title>
		<link>http://coderhump.com/archives/461</link>
		<comments>http://coderhump.com/archives/461#comments</comments>
		<pubDate>Thu, 25 Jun 2009 18:31:05 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Flash]]></category>
		<category><![CDATA[Opinion]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=461</guid>
		<description><![CDATA[Dear Adobe,
Please make Flash into the ultimate console for the web and mobile devices.
Do not listen to the people who want you to make DRM. Centralized DRM for games doesn&#8217;t work. Adobe, we developers are a fearful lot and wish not to face the reality that all DRM can be cracked. It is much better [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://coderhump.com/wp-content/uploads/2009/06/adobe-mini-gaming-summit-225x300.jpg" alt="adobe-mini-gaming-summit" title="adobe-mini-gaming-summit" width="225" height="300" class="alignright size-medium wp-image-449" /><br />Dear Adobe,</p>
<p><b>Please make Flash into the ultimate console for the web and mobile devices.</b></p>
<p>Do not listen to the people who want you to make DRM. Centralized DRM for games doesn&#8217;t work. <b>Adobe, we developers are a fearful lot and wish not to face the reality that all DRM can be cracked.</b> It is much better for 3rd parties to do their own DRM. People will claim they want you to do DRM, but don&#8217;t listen to them. Adobe, they do not know what they are asking. <a href="http://libtomcrypt.com/index.old.html">A good fast crypto library</a> would be nice, though.</p>
<p>Do not listen to the people who want you to add high-end GPU capabilities. Games don&#8217;t need to be able to launch a background thread that does deferred collision using a secondary GPU. They need to be fun. HW accelerated rendering on the platforms that can support it would be nice, but it is <b>more important that there be consistent performance than that there be high performance on some computers and bad performance on others.</b>.</p>
<p>Do not listen to the people who want you to write their game logic for them. Adobe, they do not know it, but they are asking for a monoculture that will ruin your platform. <b>Let the distributors and publishers create good high score and friend and sign on features.</b> They will promote them and make them good because they are financially motivated to do so.</p>
<p>Do not listen to the people who want per-pixel collision primitives. For, lo, they are lazy as hell and do not realize that it is a bad idea to tie collision to visual appearance. <b>Every serious game from Super Mario Bros on down implements collision using bounding volume checks behind the scenes.</b> Many games use <a href="http://box2dflash.sourceforge.net/">good collision libraries</a>, which are more easily extended and debugged than native code in the Player.</p>
<p>Oh Adobe, devourer of companies, creator of digital art tools, <b>hark unto the example of Microsoft.</b> For were they not like the wild beast of the field, clueless as to the nature of game development? Then they created DirectX 1, and it was shitty. DirectX 2 was right out, and DirectX 3 could draw sprites ok but not do 3d for beans. Did it not take <a href="http://en.wikipedia.org/wiki/DirectX#Release_history">Microsoft fully eighteen revisions to achieve a game API that was good?</a> </p>
<p>But what truly made their API good? Was it the functionality, which was adequate? <b>No, it was the tools and the consistency!</b> The consistency they achieved by enforcing it on hardware manufacturers and having strict standards! The developer tools they created for the XBox and the XBox 360! These excellent tools made developers love working with the XBox 360. Even Carmack switched to using the 360, because of these excellent tools!</p>
<p>Adobe, make Flash like unto a console! <b>Give us consistent performance! Give us excellent tools!</b> Flex Builder is not that great, Adobe. <a href="http://coderhump.com/archives/438">Your compilers could be a lot better, too.</a> Don&#8217;t worry too much about lots of fancy features. People who have to have super high end 3d and do not want to run everywhere will use tools like Torque or Unity that do 3d really well. Be everywhere, run well, be easy to develop for, and you will be loved and well rewarded.</p>
<p>Adobe, I have a vested interest in you succeeding. Please listen to my words. I have spent years developing game middleware on a variety of platforms. Now I am working with Flash. <b>If Flash dominates the game industry, it will be possible for me to afford to eat.</b></p>
<p>Please, Adobe. I am hungry.</p>
<p>Your Pal,<br />
Ben</p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/461/feed</wfw:commentRss>
		<slash:comments>60</slash:comments>
		</item>
		<item>
		<title>Adobe, Please Buy HaXe.</title>
		<link>http://coderhump.com/archives/438</link>
		<comments>http://coderhump.com/archives/438#comments</comments>
		<pubDate>Fri, 22 May 2009 21:02:30 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Opinion]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=438</guid>
		<description><![CDATA[ If you&#8217;re in the Flash space, you&#8217;ve probably seen a lot of coverage of HaXe lately. HaXe targets Flash 9 and 10, as well as JavaScript, PHP, NekoVM, and most recently C++. You can write code once and easily retarget it to different platforms, which is very exciting. This has been used to good [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://coderhump.com/wp-content/uploads/2009/05/haxe_and_neko-150x150.jpg" alt="haxe_and_neko" title="haxe_and_neko" width="150" height="150" class="alignright size-thumbnail wp-image-442" /> If you&#8217;re in the Flash space, you&#8217;ve probably seen a lot of coverage of <a href="http://haxe.org/">HaXe</a> lately. HaXe targets Flash 9 and 10, as well as JavaScript, PHP, NekoVM, and <b>most recently C++</b>. You can write code once and easily retarget it to different platforms, which is very exciting. This has been used to good effect by Hugh Sanderson, who is developing an <a href="http://gamehaxe.com/2009/05/22/haxe-on-iphone-simulator/">iPhone</a> path.</p>
<p>HaXe is cool not only for platform compatibility with things like the iPhone (and who knows &#8211; maybe other platforms like Android or Windows Mobile), but also for its <b>language features</b>. They <a href="http://www.ncannasse.fr/blog/virtual_memory_api">deployed support for the new Flash 10 high-performance memory intrinsics</a> before the official Adobe compiler. HaXe has <a href="http://haxe.org/ref/type_params">generics/templates</a>, decent <a href="http://haxe.org/ref/conditionals">conditional compilation</a>, <a href="http://haxe.org/ref/inline">inlining</a>, <a href="http://haxe.org/ref/type_advanced>advanced typing</a> a lot more. The biggest claim to fame HaXe has is <a href="http://lab.polygonal.de/2009/03/12/hx3ds/">a big performance margin over AS3</a>, as well <a href="http://lab.polygonal.de/2009/03/14/a-little-alchemy-in-hx3ds/">as better memory management options</a>.</p>
<p>And <b>performance is a big deal</b> when you&#8217;re an interpreted language trying to run on <a href="http://en.wikipedia.org/wiki/Netbook">Netbooks</a> and <a href="http://news.bbc.co.uk/1/hi/technology/8008070.stm">televisions</a>.</p>
<p>Since my day (and sometimes nights, too) job is working on a <a href="http://www.pushbuttonengine.com/">Flash game framework</a>, HaXe looms large on my radar. <a href="http://haxe.org/doc/advanced/swc">AS3 and HaXe can already interoperate</a> so if you want to use a HaXe physics library from your ActionScript 3 code, there&#8217;s no problem. But should we switch the core engine over? Having a seamless way to target iPhone would be big. Having an easy way to run your server code without requiring an integration with Tamarin would also be nice.</p>
<p><a href="http://www.unitzeroone.com/blog/2009/05/22/another-scream-on-flash-alchemy-memory-and-compilers/">Ralph Hauwert over at unitzeroone summarizes the HaXe situation</a> very well:</p>
<blockquote><p><i>The language is great and has many features ActionScript lacks. It baffles me how one man army nicolas can single handedly write a language and a multi target compiler, and in many respects stay on top of the ActionScript compiler.</p>
<p>My first problem with Haxe is just that. The one man army. Should nicolas decide he doesn&#8217;t feel like it anymore, the platform is dead. Sure, there&#8217;s more people working on it, but in it&#8217;s core it seems to be that nicolas is the driving force. My second problem is that although there is a huge pool of ActionScript developers, which can work together within the industry standard called ActionScript. There&#8217;s not even near that many people who&#8217;ve even touched haxe, let alone the number of developers who are able to call themselves &#8220;Haxe Professionals&#8221;.</i></p></blockquote>
<p><b>HaXe is very cool.</b> But it doesn&#8217;t have the ecosystem and infrastructure to justify targeting it exclusively. As a small startup, we only get to target one platform for our technology, and AS3, although it leaves performance on the table, wins in terms of the pool of potential developers and the accessibility of the toolchain. How many people out there are using PHP or Java vs. x86 assembly?</p>
<p>If the basic technology is good enough, <b>ease of use always wins out over performance</b>. So for now we are going to stick with ActionScript 3 for <a href="http://www.pushbuttonengine.com">PushButton Engine</a>. You can write compelling content on it. If you really need HaXe for something, the option is there to link it in.</p>
<p>But I want to put the plea out to Adobe. I love you guys and all you have done in the Flash space. But please update your compiler technology. At least give us the compiler optimization wins like <a href="http://blog.haxe.org/entry/31">inlining and generics</a>. It&#8217;s simply embarassing that one guy&#8217;s work can outperform you on your own VM! </p>
<p>Adobe, you have smart people working for you. You have smart people in your community. You have pretty decent tools. None of us want to jump over to a third-party technology, but if HaXe keeps beating you at your own game, it might be necessary. <b>Buy HaXe if you must</b>, or else match it with your in-house tech, but either way &#8211; I know you can solve this problem. </p>
<p>The web is catching up with you on the player front. You could dominate on the tools front and make the world better for everyone. Please. As a middleware developer, I really don&#8217;t want to have to support anything other than a single mainstream language and platform. <img src='http://coderhump.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/438/feed</wfw:commentRss>
		<slash:comments>17</slash:comments>
		</item>
		<item>
		<title>Technical Notes on O3D</title>
		<link>http://coderhump.com/archives/427</link>
		<comments>http://coderhump.com/archives/427#comments</comments>
		<pubDate>Tue, 21 Apr 2009 22:23:49 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Cool Stuff]]></category>
		<category><![CDATA[Opinion]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=427</guid>
		<description><![CDATA[
Google released O3D, a web plugin for 3d rendering, today. It&#8217;s a pretty sweet piece of work. Definitely check it out if you have any interest in 3d rendering, the web, or JavaScript.
There are a couple of cool pieces to this puzzle, and I wanted to call them out to other people who might be [...]]]></description>
			<content:encoded><![CDATA[<p><center><object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/uofWfXOzX-g&#038;rel=0&#038;color1=0xb1b1b1&#038;color2=0xcfcfcf&#038;hl=en&#038;feature=player_embedded&#038;fs=1"></param><param name="allowFullScreen" value="true"></param><embed src="http://www.youtube.com/v/uofWfXOzX-g&#038;rel=0&#038;color1=0xb1b1b1&#038;color2=0xcfcfcf&#038;hl=en&#038;feature=player_embedded&#038;fs=1" type="application/x-shockwave-flash" allowfullscreen="true" width="425" height="344"></embed></object></center></p>
<p><b>Google released <a href="http://code.google.com/apis/o3d/">O3D, a web plugin for 3d rendering</a>, today.</b> It&#8217;s a pretty sweet piece of work. Definitely check it out if you have any interest in 3d rendering, the web, or JavaScript.</p>
<p>There are a couple of cool pieces to this puzzle, and I wanted to call them out to other people who might be reviewing this technology. The two sentence review: <b>I am blown away. They got this right.</b></p>
<p>(FYI: This post isn&#8217;t meant to be a full walkthrough, just a quick indication of the cool jumping off points in the codebase.)</p>
<p>Stop number one is <b>the graphics API abstraction</b>. This is rooted in <a href="http://o3d.googlecode.com/svn/trunk/googleclient/o3d/core/cross/renderer.h">o3d/core/cross/renderer.h</a>, which provides an abstract interface for performing render operations. This is sensibly designed, oriented for SM2.0 through SM4.0 level hardware. It will also deal with DX11 class hardware, although it won&#8217;t expose all of the niceties DX11 gets you. It wraps GL (<a href="http://o3d.googlecode.com/svn/trunk/googleclient/o3d/core/cross/gl/">o3d/core/cross/gl/</a>) and D3D9 (<a href="http://o3d.googlecode.com/svn/trunk/googleclient/o3d/core/win/d3d9/">o3d/core/win/d3d9</a>). The purpose of all this is to provide a common ground for all the higher level code to issue draw commands from. It is not directly accessible from JavaScript (although some of the related classes like <a href="http://code.google.com/apis/o3d/docs/reference/classo3d_1_1_sampler.html">Sampler</a> and <a href="http://code.google.com/apis/o3d/docs/reference/classo3d_1_1_state.html">State</a> are.)</p>
<p>As an aside, writing a <a href="http://www.radgametools.com/pixomain.htm">Pixomatic</a> or <a href="http://en.wikipedia.org/wiki/Larrabee_(GPU)">Larrabee</a> backend would not be hard. At <a href="http://www.garagegames.com/">GarageGames</a>, we had a rendering API similar to this (unimaginatively called GFX), and it was fantastically useful. Last time I checked, there were DX8, DX9, DX10/11, GL, and Pixomatic backends for it in varying states of usefulness. We even had one guy write a backend that would stream draw commands over a socket, which was pretty cool. In the context of O3D, they have <a href="http://o3d.googlecode.com/svn/trunk/googleclient/o3d/core/cross/command_buffer/">an implementation of Renderer that queues everything into command_buffer</a>, then streams it to a <a href="http://o3d.googlecode.com/svn/trunk/googleclient/o3d/core/win/command_buffer/">command buffer server</a> running in a separate thread, which issues the actual draw commands. It&#8217;s unclear whether this is used in the current version of the plugin based on casual inspection, but it&#8217;s a great example of what good design can get you.</p>
<p>The next piece is <b>the DrawList</b>, which is where most of the heavy lifting for drawing happens. JavaScript, of course, is not really desirable to have in your inner rendering loops, so you queue everything you want to draw (<a href="http://code.google.com/apis/o3d/docs/reference/classo3d_1_1_draw_element.html">DrawElements</a>) into a <a href="http://code.google.com/apis/o3d/docs/reference/classo3d_1_1_draw_list.html">DrawList</a>. This is wrapped by higher levels, of course, but it represents the lowest level API that&#8217;s available to JS code. All the sorting and state management to get stuff on screen happens in this area.</p>
<p>Alongside the DrawList stuff, you find <b>the <a href="http://code.google.com/apis/o3d/docs/shadinglanguage.html">material system</a></b>, which is pretty slick. You write your shaders in their shading language, and it converts to HLSL SM2.0 and Cg (arbvp1/arbfp1). This is enough to do almost anything you might want to (as fantastic as SM3.0+ is it&#8217;s not really necessary for most rendering). There&#8217;s a full SAS system so you can interface programmatically with your shaders.</p>
<p>Above this, you get into <b>the scenegraph</b>. Now, I subscribe to <a href="http://home.comcast.net/~tom_forsyth/blog.wiki.html#%5B%5BScene%20Graphs%20-%20just%20say%20no%5D%5D">Tom Foryth&#8217;s views on scenegraphs</a>, which is that they are basically a bad idea, but I think the Google guys were smart and set up their API so intelligent developers can avoid being screwed by the scenegraph. The scenegraph-esque stuff they do have (<a href="http://code.google.com/apis/o3d/docs/rendering.html">they call it a rendergraph</a>) is powerful enough you can do most rendering without going nuts, and lets a lot of the heavy lifting stay in native code, where it will be fast. You end up doing retained mode-ish things, but since JS is slow, and most JS developers come from a DOM background, it works better than you might expect.</p>
<p>There are a lot of <b>cool miscellaneous features</b>, too. They <a href="http://code.google.com/apis/o3d/docs/v8engine.html">embed the fast V8 JS engine</a> right in the plugin so you can have consistently fast JS execution. They support falling back to an <a href="http://code.google.com/apis/o3d/docs/reference/classo3d_1_1_client.html#49f18f81e6184cbeeeb87306f0cf59ca">error texture (via Client.SetErrorTexture)</a> when you fail to bind a sampler.  You can group objects via <a href="http://code.google.com/apis/o3d/docs/reference/classo3d_1_1_pack.html">Pack</a> objects for easier management and <a href="http://code.google.com/apis/o3d/docs/reference/classo3d_1_1_archive_request.html">stream things from archives</a>, too. There are <a href="http://code.google.com/apis/o3d/docs/reference/jsdocs/js_1_0_o3djs.debug_ref.html">debugging aids</a> and libraries for <a href="http://code.google.com/apis/o3d/docs/reference/jsdocs/js_1_0_o3djs.math_ref.html">math</a> and <a href="http://code.google.com/apis/o3d/docs/reference/jsdocs/js_1_0_o3djs.quaternions_ref.html">quaternions</a>.</p>
<p>You should check out the <a href="http://code.google.com/apis/o3d/docs/samplesdirectory.html#demos">samples</a>. There&#8217;s a lot of impressive stuff. There&#8217;s the <a href="http://o3d.googlecode.com/svn/trunk/samples/beachdemo/beachdemo.html">beach demo</a> in the video at the top of this post, but they also do some cool stuff with <a href="http://o3d.googlecode.com/svn/trunk/samples/animated-scene.html">animation</a>, <a href="http://o3d.googlecode.com/svn/trunk/samples/hud-2d-overlay.html">HUDs</a>, <a href="http://o3d.googlecode.com/svn/trunk/samples/canvas-fonts.html">text rendering</a>, <a href="http://o3d.googlecode.com/svn/trunk/samples/picking.html">picking</a>, and <a href="http://o3d.googlecode.com/svn/trunk/samples/stencil_example.html">stenciled teapots</a>. And everything is done in JavaScript right in the web page. Even the shaders are embedded in &lt;script&gt; tags!</p>
<p><b>O3D is a great piece of technology</b>, and I hope it thrives. I&#8217;m excited to see what people build on this (and I&#8217;ve got a few ideas myself <img src='http://coderhump.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> .</p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/427/feed</wfw:commentRss>
		<slash:comments>29</slash:comments>
		</item>
		<item>
		<title>PlayStation Home: Serial Killer Edition</title>
		<link>http://coderhump.com/archives/289</link>
		<comments>http://coderhump.com/archives/289#comments</comments>
		<pubDate>Mon, 15 Dec 2008 23:59:06 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Opinion]]></category>
		<category><![CDATA[playstation home]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=289</guid>
		<description><![CDATA[PlayStation Home came out not too long ago. Penny Arcade pretty much said what needs to be said about it, but I had to try it myself. Naturally the first thing you do is create your character from a randomized (I hope) default character.
To the left is the default character that I got.
&#8230;
Sony appears to [...]]]></description>
			<content:encoded><![CDATA[<div id="attachment_290" class="wp-caption alignleft" style="width: 235px"><a href="http://coderhump.com/wp-content/uploads/2008/12/terrifying_man.jpg"><img src="http://coderhump.com/wp-content/uploads/2008/12/terrifying_man-225x300.jpg" alt="My Default Playstation Home Avatar" title="My Default Playstation Home Avatar" width="225" height="300" class="size-medium wp-image-290" /></a><p class="wp-caption-text">My Default Playstation Home Avatar</p></div>
<p>PlayStation Home came out not too long ago. <a href="http://www.penny-arcade.com/2008/12/12/">Penny Arcade</a> pretty much said what needs to be said about it, but I had to try it myself. Naturally the first thing you do is create your character from a randomized (I hope) default character.</p>
<p>To the left is the default character that I got.</p>
<p>&#8230;</p>
<p>Sony appears to be targeting the coveted 18-25 male Caucasian skinhead/serial killer demographic. I&#8217;m kind of surprised that they didn&#8217;t filter the default characters to avoid characters that appeared obviously threatening/defective. If this guy showed up at my front door, I&#8217;d call the cops.</p>
<p>Naturally, I ended up tweaking him to try and make him freakier, but honestly, what I ended up with was less terrifying. He resembled a creepy real life version of <a href="http://coderhump.com/wp-content/uploads/2008/12/robbierotten.jpg">Robbie Rotten</a>.</p>
<p>He stood out nicely compared to all the cookie cutter people on Home, but nobody really cared. In fact, it was hard to communicate with people or interact with the world at all. The loading times were ludicrous. The difference between last gen and this gen is that you can let things load in the background while you stare at the room you&#8217;re stuck in. Why would Sony spend millions of dollars and years of time on something like this?</p>
<p><b>Does anyone else get the feeling that big game projects don&#8217;t have fun on their agendas?</b></p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/289/feed</wfw:commentRss>
		<slash:comments>17</slash:comments>
		</item>
		<item>
		<title>Web Service Explosion: Put Out The Fire With FriendFeed</title>
		<link>http://coderhump.com/archives/243</link>
		<comments>http://coderhump.com/archives/243#comments</comments>
		<pubDate>Tue, 14 Oct 2008 21:38:47 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Opinion]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=243</guid>
		<description><![CDATA[How many web services do you use that have a section for linking into your other web services? I love having my internet presence linked together. But the number of links grows quickly. 10 services means 50 links that you have to maintain.
Most of these integrations are there just to post nice status messages from one place [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://coderhump.com/wp-content/uploads/2008/10/links.png"><img class="size-thumbnail wp-image-244 alignright" title="links" src="http://coderhump.com/wp-content/uploads/2008/10/links-150x150.png" alt="" width="150" height="150" /></a>How many web services do you use that have a section for linking into your other web services? I love having my internet presence linked together. But the number of links grows quickly. <strong>10 services means 50 links that you have to maintain.</strong></p>
<p>Most of these integrations are there just to post nice status messages from one place to another or provide a link to a profile. Why not use a central service like <a href="http://www.friendfeed.com/">FriendFeed</a> to handle the details? The <a href="http://code.google.com/p/friendfeed-api/wiki/ApiDocumentation">FriendFeed API</a> is almost there. <strong>If </strong><strong>FriendFeed had better options for the API to push outwards, 90% of that service configuration box could go away.</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/243/feed</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Larrabuzz</title>
		<link>http://coderhump.com/archives/210</link>
		<comments>http://coderhump.com/archives/210#comments</comments>
		<pubDate>Sat, 16 Aug 2008 21:04:04 +0000</pubDate>
		<dc:creator>Ben</dc:creator>
				<category><![CDATA[Opinion]]></category>

		<guid isPermaLink="false">http://coderhump.com/?p=210</guid>
		<description><![CDATA[A bunch of great papers related to Larrabee from Siggraph 08. Great perspective on parallel computing in general.
My read is that the GPU guys don’t have a clue. A lot of their talent has moved on. They’re focusing on maximizing flops without realizing that it isn’t always the flops that matter &#8211; it’s how you [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://s08.idav.ucdavis.edu/" target="_blank">A bunch of great papers related to Larrabee from Siggraph 08</a>. Great perspective on parallel computing in general.</p>
<p>My read is that the GPU guys don’t have a clue. A lot of their talent has moved on. They’re focusing on maximizing flops without realizing that it isn’t always the flops that matter &#8211; it’s how you spend them. There’s for sure a market for teraflops of raw power, but LRB’s feature set maps so beautifully to rendering that I think the reduced performance is going to more than make up for it.</p>
<p>The trend in rendering is towards branch-heavy shaders doing random access. GPUs are fast when you’re doing branchless shaders with linear access patterns &#8211; but the trend is forcing them into the realm that Intel has been dominating for thirty years.</p>
<p>I guess we’ll see where things are in five years. But you can see which way I want things to go. <img src="http://coderhump.com/wp-includes/images/smilies/icon_wink.gif" alt=";)" class="wp-smiley"/> </p>
]]></content:encoded>
			<wfw:commentRss>http://coderhump.com/archives/210/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
