TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Ejecta – A Fast, Open Source JavaScript, Canvas and Audio Implementation for iOS

73 pointsby hisingabout 11 years ago

8 comments

pcwaltonabout 11 years ago
One of the coolest things I learned from the original blog post [1] on Ejecta was a trick that the library uses for drawing polygons on the GPU in OpenGL without triangulating them first [2]. It&#x27;s one of the coolest graphics programming tricks I&#x27;ve ever seen and when I understood how it worked my mind was blown.<p>[1]: <a href="http://phoboslab.org/log/2012/09/ejecta" rel="nofollow">http:&#x2F;&#x2F;phoboslab.org&#x2F;log&#x2F;2012&#x2F;09&#x2F;ejecta</a><p>[2]: <a href="http://www.glprogramming.com/red/chapter14.html#name13" rel="nofollow">http:&#x2F;&#x2F;www.glprogramming.com&#x2F;red&#x2F;chapter14.html#name13</a>
评论 #7486847 未加载
评论 #7486796 未加载
RyanZAGabout 11 years ago
Would be nice to see some benchmarks. I can&#x27;t see how this could be faster than just running it in Safari. In Safari you get access to far faster javascript jit than you do in the embedded app js engine. The app itself just translates the javascript canvas calls into objc calls to the core graphics.. which is what safari&#x27;s canvas does anyway? Is the extra level of indirection through safari enough to compensate for slower jit? Plus it&#x27;s a lot harder to compile this than it is to put a js game on the web.<p>Needs benchmarks to be able to make any decisions.
评论 #7486488 未加载
评论 #7486726 未加载
评论 #7486192 未加载
评论 #7486085 未加载
hopfogabout 11 years ago
Ejecta is awesome. So is ImpactJS. Dominic (the creator) is experimenting with making Ejecta cross-platform so hopefully we will see an Android version soon.
camus2about 11 years ago
<p><pre><code> The JavaScriptCore API is private on iOS, which means you&#x27;re not allowed to link to it. Ejecta therefore comes bundled with its own version of the library to circumvent these restrictions. </code></pre> So you are basically using another VM(a second javascript core) in an IOS app. Isnt it forbidden to do so,running VMs in IOS apps?<p>A better approach would be to do like TITANIUM ,except that you expose a CANVAS like API,so that your javascript canvas framework is compatible with it =&gt; less work,and no trick that would make your app kicked out of the store once the scheme is busted.
评论 #7487125 未加载
评论 #7486329 未加载
评论 #7486522 未加载
adrnslyabout 11 years ago
I use Ejecta for almost all my prototyping, super easy to make changes during a meeting to do live iteration testing.
checker659about 11 years ago
Why not use v8 and make the runtime run &quot;everywhere&quot;?<p>Edit: Sorry, just realised the development is done in Objective-C.
评论 #7486817 未加载
评论 #7486753 未加载
al2o3crabout 11 years ago
Looks cool, but &quot;works out of the box except for controls&quot; is pretty much &quot;doesn&#x27;t work out of the box&quot; for games...
adamnemecekabout 11 years ago
It&#x27;s not really a &quot;JavaScript implementation&quot; when it appears to be just a wrapper around JavaScriptCore, innit bruv.