What's coming for HTML5

Forum Home Forum Home > General > Open Topic
 Post Reply Post Reply Page  12>
Author
7,980 Rep
Post Options Post Options   Quote Kiyoshi Quote  Post ReplyReply Direct Link To This Post Topic: What's coming for HTML5
    Posted: 07 Mar 2012 at 11:47pm
That clever tricks the guy made are only relevant on Canvas. WebGL doesn't need that. Of course the core idea he used, of only drawing what is visible makes total sense and it's perfectly applicable to WebGL. Out of curiosity Ashley have you tried making Bunny Mark on C2 ? Just to see how much C2 could handle compared to new Flash and HaxeNME. For reference: Bunnymark. Would be a good promotion to C2 posting something like it on the blog.

Edited by Kiyoshi - 07 Mar 2012 at 11:49pm
Back to Top
1,670 Rep
Post Options Post Options   Quote imothep85 Quote  Post ReplyReply Direct Link To This Post Posted: 07 Mar 2012 at 6:55pm
14.000 lol crazy [<:o)]
Back to Top

Scirra Developer
81,281 Rep
Post Options Post Options   Quote Ashley Quote  Post ReplyReply Direct Link To This Post Posted: 07 Mar 2012 at 4:33pm
@imothep85, Construct 2 supports WebGL and my last benchmark can get 14000 sprites on-screen at 30 fps. So it should be able to do 7000 at 60 fps already.
Back to Top

Moderator
8,448 Rep
Post Options Post Options   Quote SoldjahBoy Quote  Post ReplyReply Direct Link To This Post Posted: 07 Mar 2012 at 11:24am
It freezes my browser too.

Using Firefox 10.0.2

~Sol

Tired of sh*tty file hosts that are sh*tty? GET DROPBOX!
Back to Top
5,315 Rep
Post Options Post Options   Quote Pode Quote  Post ReplyReply Direct Link To This Post Posted: 07 Mar 2012 at 8:27am
From the comments of the video : he used a clever trick, nothing "HTML" specific. As Kiyoshi said, you need 2 canvases. The slow part with Canvas is drawImage(). So you need to move the viewport, know how much you moved by using two variables, and only draw new tiles in the white row or columns that has just been created. So the number of redraw is only linear, not exponential.
Back to Top
1,670 Rep
Post Options Post Options   Quote imothep85 Quote  Post ReplyReply Direct Link To This Post Posted: 06 Mar 2012 at 1:49am
i hope Ashley is going to look at this :D
Back to Top
7,980 Rep
Post Options Post Options   Quote Kiyoshi Quote  Post ReplyReply Direct Link To This Post Posted: 06 Mar 2012 at 1:21am
The guy used a clever optimization. Since he didn't post the code i can't tell exactly what he used. But from what i understood it's a double buffer technique with two canvas and copying only what's visible each time from one to other.
Back to Top
1,670 Rep
Post Options Post Options   Quote imothep85 Quote  Post ReplyReply Direct Link To This Post Posted: 06 Mar 2012 at 12:28am
I saw THIS on youtube. it is possible with scirra??? because scirra use html5 http://www.youtube.com/watch?v=lP0guzk1nS4
Back to Top
7,980 Rep
Post Options Post Options   Quote Kiyoshi Quote  Post ReplyReply Direct Link To This Post Posted: 06 Mar 2012 at 12:24am
What browser are you using ? I'm using Chrome 17, works ok here. If you're using the same then i'm lucky i guess. Should work on Chrome and Firefox i think.
Back to Top
11,239 Rep
Post Options Post Options   Quote lucid Quote  Post ReplyReply Direct Link To This Post Posted: 05 Mar 2012 at 10:51pm
i like how the whats next for html5 site just freezes my browser
Back to Top
 Post Reply Post Reply Page  12>

Forum Jump Forum Permissions View Drop Down