Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
High Performance WebGL
Search
Luigi De Rosa
February 21, 2018
Programming
1
980
High Performance WebGL
Slides from my talk about WebGL at FEVR meetup. 21 Feb 2018
Luigi De Rosa
February 21, 2018
Tweet
Share
Other Decks in Programming
See All in Programming
PHPはいつから死んでいるかの調査
chiroruxx
1
400
SIMD Parallel Programming with the Vector API
josepaumard
0
180
GraphQLサーバの構成要素を整理する #ハッカー鮨 #tsukijigraphql / graphql server technology selection
izumin5210
4
840
dbtのドメイン分割による データ基盤の改善とDigdagとの連携
sakama
0
340
スキーマ駆動開発による品質とスピードの両立 - 私達は何故、スキーマを書くのか
kentaroutakeda
0
170
ONE WEDGE_company_guide
1wedge_one
0
480
Goのエラースタックトレースの歴史と今後
sonatard
9
1.5k
"config" ってなんだ? / What is "config"?
okashoi
0
240
Node.js v22 で変わること
yosuke_furukawa
PRO
9
3.4k
Hanami and htmx
bkuhlmann
0
210
R言語の環境構築と基礎 Tokyo.R 112
bob3bob3
0
270
初心者のためのRubyKaigi入門/RubyKaigi Introduction
a_matsuda
1
630
Featured
See All Featured
Building an army of robots
kneath
300
41k
The Invisible Side of Design
smashingmag
294
49k
Put a Button on it: Removing Barriers to Going Fast.
kastner
58
3.1k
A Tale of Four Properties
chriscoyier
151
22k
Faster Mobile Websites
deanohume
299
30k
Automating Front-end Workflow
addyosmani
1356
200k
Designing for humans not robots
tammielis
248
25k
We Have a Design System, Now What?
morganepeng
43
6.8k
Why You Should Never Use an ORM
jnunemaker
PRO
51
8.6k
Code Review Best Practice
trishagee
55
15k
Why Our Code Smells
bkeepers
PRO
331
56k
Typedesign – Prime Four
hannesfritz
36
2.1k
Transcript
HIGH PERFORMANCE WEBGL what I learned doing WebGL… FEBRUARY 21TH,
2018
@luruke
EPIC is a digital agency made of passion and
creativity. We dedicate ourselves to crafting awesome and eye-catching digital experiences that change the way your brand connects with your clients.
None
None
HTTPS://GITHUB.COM/LURUKE/DEV-EXCUSES-CHROME
None
WE ARE EPIC 1
WE ARE EPIC 1
JUST A RASTERIZATION ENGINE! UEBBGL?
WEBGL IS NOT 3D
HTTPS://NICKDESAULNIERS.GITHUB.IO/RAWWEBGL/
HTTPS://WWW.KHRONOS.ORG/API/OPENGLES/2_X
HTTPS://SIMONSCHREIBT.DE/GAT/RENDERHELL/
• Three.js (react-vr, a-frame…) • Babylon.js • PixiJS (2d only…
for now) • Nanogl • Regl • … • Vanilla WebGL (if you are brave enough) Most used WebGL framework
WHAT I LEARNED After many headaches.
None
None
None
None
None
IN THE DETAIL…
DELIVERY DAY - Promotional game - Mobile first - Easy
to play - “on the go” - Support 2-3y old phones - Multiplatform (+60 device tested)
None
None
CONCEPT 1.0 Make sure you know what you are doing!
None
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
None
BLENDER - Great for prototyping - Open Source - Three.js
exporter - All-in-one solution (modelling + texturing + sculpturing…) 1.1 Is not just for 3D artist!
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
None
LOGIC + RENDER 1.2 Divide et impera
• Just logic! • Expose the “info” (score, parcels, …)
• Event based • Unit tested (well…partially) • Rendering independent (css, terminal, canvas, webgl….) Game engine
• Passive - read info from game engine • Handles
interaction (touch, click, gyroscope…) • Can just send events • Full WebGL (but we also won CSSDesignAward…) • Three.js + PixiJS Rendering
16.6MS
>
WEBGL AND HTML? 1.3 Sometimes are not good friends
None
WE ARE EPIC 1
None
CPU & GPU 1.4 Less they talk each other, the
better
HTTPS://SIMONSCHREIBT.DE/GAT/RENDERHELL/
None
WE ARE EPIC 1
WE ARE EPIC 1
TEXTURES = DATA 1.5 Textures are more than an image
None
HTTPS://WWW.PATREON.COM/MINIONSART
HTTPS://WWW.PATREON.COM/MINIONSART
HTTPS://WWW.PATREON.COM/MINIONSART
HTTPS://WWW.PATREON.COM/MINIONSART
HTTPS://WWW.PATREON.COM/MINIONSART
WE ARE EPIC 1 HTTPS://GITHUB.COM/SPITE/THREE.FBOHELPER
WE ARE EPIC 1
WE ARE EPIC 1
None
None
1.6 “With Great Power Comes Great Responsibility” FORCE GPU UPLOAD
HTTP://GLUMPY.READTHEDOCS.IO/
WE ARE EPIC 1
None
None
None
OBJECT POOLING 1.7
None
None
None
MULTIPLATFORM WEBGL 1.8 Make WebGL run (almost) everywhere
None
None
None
None
None
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
I NEED MORE POWER! 1.9 Do you?
None
None
None
DEBUGGING IS HARD 2.0 But not impossible
None
None
None
WE ARE EPIC 1
None
None
HOW TO START? 2.1 The hard way
• How Computer Graphic works • How 3D works (math,
vectors, light, matrix…) • How WebGL/OpenGL works • Write tons of Shaders • Success Learn WebGL like a BOSS:
WE ARE EPIC 1
WE ARE EPIC 1
WE ARE EPIC 1
Thank you! YOU GOT QUESTIONS? @luruke
Thank you! YOU GOT QUESTIONS? @luruke HTTP://SOLVERSGB.UPS.COM/DELIVERY-DAY/