• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EST 15:49
CET 21:49
KST 05:49
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
ByuL: The Forgotten Master of ZvT28Behind the Blue - Team Liquid History Book19Clem wins HomeStory Cup 289HomeStory Cup 28 - Info & Preview13Rongyi Cup S3 - Preview & Info8
Community News
Weekly Cups (Feb 16-22): MaxPax doubles0Weekly Cups (Feb 9-15): herO doubles up2ACS replaced by "ASL Season Open" - Starts 21/0244LiuLi Cup: 2025 Grand Finals (Feb 10-16)46Weekly Cups (Feb 2-8): Classic, Solar, MaxPax win2
StarCraft 2
General
ByuL: The Forgotten Master of ZvT How do you think the 5.0.15 balance patch (Oct 2025) for StarCraft II has affected the game? Oliveira Would Have Returned If EWC Continued Behind the Blue - Team Liquid History Book Weekly Cups (Feb 16-22): MaxPax doubles
Tourneys
The Dave Testa Open #11 Sparkling Tuna Cup - Weekly Open Tournament PIG STY FESTIVAL 7.0! (19 Feb - 1 Mar) StarCraft Evolution League (SC Evo Biweekly) Sea Duckling Open (Global, Bronze-Diamond)
Strategy
Custom Maps
Map Editor closed ? [A] Starcraft Sound Mod
External Content
Mutation # 514 Ulnar New Year The PondCast: SC2 News & Results Mutation # 513 Attrition Warfare Mutation # 512 Overclocked
Brood War
General
Soma Explains: JD's Unrelenting Aggro vs FlaSh ACS replaced by "ASL Season Open" - Starts 21/02 BGH Auto Balance -> http://bghmmr.eu/ CasterMuse Youtube TvZ is the most complete match up
Tourneys
Escore Tournament StarCraft Season 1 [Megathread] Daily Proleagues [LIVE] [S:21] ASL Season Open Day 1 Small VOD Thread 2.0
Strategy
Fighting Spirit mining rates Simple Questions, Simple Answers Zealot bombing is no longer popular?
Other Games
General Games
Battle Aces/David Kim RTS Megathread Path of Exile Nintendo Switch Thread Beyond All Reason New broswer game : STG-World
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Deck construction bug Heroes of StarCraft mini-set
TL Mafia
Vanilla Mini Mafia Mafia Game Mode Feedback/Ideas TL Mafia Community Thread
Community
General
US Politics Mega-thread Mexico's Drug War Canadian Politics Mega-thread Russo-Ukrainian War Thread Ask and answer stupid questions here!
Fan Clubs
The IdrA Fan Club The herO Fan Club!
Media & Entertainment
[Req][Books] Good Fantasy/SciFi books [Manga] One Piece Anime Discussion Thread
Sports
2024 - 2026 Football Thread Formula 1 Discussion TL MMA Pick'em Pool 2013
World Cup 2022
Tech Support
TL Community
The Automated Ban List
Blogs
Unintentional protectionism…
Uldridge
ASL S21 English Commentary…
namkraft
Inside the Communication of …
TrAiDoS
My 2025 Magic: The Gathering…
DARKING
Customize Sidebar...

Website Feedback

Closed Threads



Active: 1258 users

HTML5 hackers wanted

Blogs > mmp
Post a Reply
mmp
Profile Blog Joined April 2009
United States2130 Posts
November 22 2011 05:14 GMT
#1
I made a post in the Big Programming Thread but I'll post here too:

On November 22 2011 14:09 mmp wrote:
Are there any Javascript/Canvas/HTML5 hackers out there? I've been working on a framework for Canvas 2D Context for a while now and things are starting to come together (it's about 95% tested and 90% documented but there are some known holes, so be gentle).

The project is hosted at: http://gitorious.org/meta2d/core/trees/master/

If your browser is awesome (tested in FF7, Chrome14 -- Opera won't work right now, I assume IE will fail) you can try a demo of HTMLMouseEvent triggers here: http://mikemp.mit.edu/meta2d/demo/mouse.html

Unlike some other frameworks out there, this one is aimed at scalability of interactive applications without obfuscating the Context2D API. So you can port your existing canvas code over easily and use the extras that this framework provides to improve performance as needed.

It's a powerful utility if you want to write an HTML5 game, among other applications.

I'd appreciate some feedback & if you're interested in getting involved or have any questions feel free to pm me.


*
I (λ (foo) (and (<3 foo) ( T_T foo) (RAGE foo) )) Starcraft
Gummy
Profile Blog Joined October 2010
United States2180 Posts
Last Edited: 2011-11-22 05:22:49
November 22 2011 05:22 GMT
#2
This is pretty cool. I don't know how the browser handles the rendering/event detection of elements vs. drawn canvas shapes. iirc, you have to create the bounding boxes yourself, and do an expensive user-code loop of the mouse's current location against all the drawn shapes. Is your project relevant to this issue?
¯\_(ツ)_/¯ There are three kinds of people in the world: those who can count and those who can't.
mmp
Profile Blog Joined April 2009
United States2130 Posts
Last Edited: 2011-11-22 07:04:55
November 22 2011 05:29 GMT
#3
On November 22 2011 14:22 Gummy wrote:
This is pretty cool. I don't know how the browser handles the rendering/event detection of elements vs. drawn canvas shapes. iirc, you have to create the bounding boxes yourself, and do an expensive user-code loop of the mouse's current location against all the drawn shapes. Is your project relevant to this issue?

Yes, the project addresses this performance issue (among others).

When you define an entity's repaint behavior, you can draw on a canvas with a normal-looking Context2D, apply whatever transformations you want, and then pass that same Context over to the mouse collision detector for, say, alpha-masking.

It does mouse collisions in O(logN) expected runtime for N entities. I can run that demo with 1000 shapes on my netbook before getting significant lag.
I (λ (foo) (and (<3 foo) ( T_T foo) (RAGE foo) )) Starcraft
Hidden_MotiveS
Profile Blog Joined February 2010
Canada2562 Posts
November 22 2011 17:23 GMT
#4
So does the mouseevent trigger use any html5?
mmp
Profile Blog Joined April 2009
United States2130 Posts
November 23 2011 06:41 GMT
#5
On November 23 2011 02:23 Hidden_MotiveS wrote:
So does the mouseevent trigger use any html5?

The canvas is the HTML5. Normal HTMLMouseEvents are propagated through entities inside the canvas as though they were elements -- just set onevent to your function(Event) callback.
I (λ (foo) (and (<3 foo) ( T_T foo) (RAGE foo) )) Starcraft
Enderbantoo
Profile Blog Joined December 2009
United States465 Posts
November 23 2011 08:33 GMT
#6
hey that's exactly what i'm doing. Im writing a canvas workflow program: http://www.enderbantoo.github.com/LONI-1

and i experienced all of what gummy was talking about, expensive bounding functions client side
At the biggest upset of all of bw, Shanghai SPL finals 2011
Enderbantoo
Profile Blog Joined December 2009
United States465 Posts
November 23 2011 08:36 GMT
#7
On November 23 2011 02:23 Hidden_MotiveS wrote:
So does the mouseevent trigger use any html5?



much more simple

canvas.onmousedown = function(e);

handle eah different clicks as e.button
At the biggest upset of all of bw, Shanghai SPL finals 2011
Hidden_MotiveS
Profile Blog Joined February 2010
Canada2562 Posts
November 24 2011 02:42 GMT
#8
On November 23 2011 15:41 mmp wrote:
Show nested quote +
On November 23 2011 02:23 Hidden_MotiveS wrote:
So does the mouseevent trigger use any html5?

The canvas is the HTML5. Normal HTMLMouseEvents are propagated through entities inside the canvas as though they were elements -- just set onevent to your function(Event) callback.

Ah I see now. Thanks.
Please log in or register to reply.
Live Events Refresh
Next event in 3h 11m
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
mouzHeroMarine 442
IndyStarCraft 174
UpATreeSC 145
elazer 138
ProTech137
SteadfastSC 76
JuggernautJason58
Temp0 23
EmSc Tv 18
Dota 2
febbydoto7
LuMiX2
Counter-Strike
pashabiceps2462
fl0m1541
Heroes of the Storm
Liquid`Hasu499
Other Games
tarik_tv5311
Grubby3445
Beastyqt780
ToD209
ArmadaUGS164
RotterdaM145
Sick133
C9.Mang0106
Trikslyr72
ZombieGrub18
Organizations
Counter-Strike
PGL289
Other Games
BasetradeTV118
StarCraft 2
EmSc Tv 18
EmSc2Tv 18
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 20 non-featured ]
StarCraft 2
• HeavenSC 26
• Reevou 4
• LaughNgamezSOOP
• sooper7s
• AfreecaTV YouTube
• intothetv
• Migwel
• Kozan
• IndyKCrew
StarCraft: Brood War
• 80smullet 17
• blackmanpl 15
• RayReign 2
• STPLYoutube
• ZZZeroYoutube
• BSLYoutube
Dota 2
• WagamamaTV406
• masondota243
League of Legends
• TFBlade1389
Other Games
• imaqtpie1082
• Shiphtur269
Upcoming Events
OSC
3h 11m
The PondCast
13h 11m
Replay Cast
1d 3h
Korean StarCraft League
2 days
CranKy Ducklings
2 days
OSC
2 days
SC Evo Complete
2 days
DaveTesta Events
2 days
Replay Cast
3 days
Sparkling Tuna Cup
3 days
[ Show More ]
uThermal 2v2 Circuit
3 days
Replay Cast
4 days
Wardi Open
4 days
Monday Night Weeklies
4 days
Replay Cast
5 days
Replay Cast
6 days
Liquipedia Results

Completed

Proleague 2026-02-22
LiuLi Cup: 2025 Grand Finals
Underdog Cup #3

Ongoing

KCM Race Survival 2026 Season 1
Acropolis #4 - TS5
Jeongseon Sooper Cup
Spring Cup 2026
WardiTV Winter 2026
PiG Sty Festival 7.0
Nations Cup 2026
PGL Cluj-Napoca 2026
IEM Kraków 2026
BLAST Bounty Winter 2026
BLAST Bounty Winter Qual
eXTREMESLAND 2025
SL Budapest Major 2025

Upcoming

[S:21] ASL SEASON OPEN 2nd Round
[S:21] ASL SEASON OPEN 2nd Round Qualifier
ASL Season 21: Qualifier #1
ASL Season 21: Qualifier #2
Acropolis #4 - TS6
Acropolis #4
IPSL Spring 2026
HSC XXIX
uThermal 2v2 2026 Main Event
Bellum Gens Elite Stara Zagora 2026
RSL Revival: Season 4
PGL Astana 2026
BLAST Rivals Spring 2026
CCT Season 3 Global Finals
FISSURE Playground #3
IEM Rio 2026
PGL Bucharest 2026
Stake Ranked Episode 1
BLAST Open Spring 2026
ESL Pro League S23 Finals
ESL Pro League S23 Stage 1&2
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2026 TLnet. All Rights Reserved.