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
Playing With JAX
Search
Yukimitsu Izawa
August 19, 2012
Programming
3
320
Playing With JAX
Lightning talk material.
Yukimitsu Izawa
August 19, 2012
Tweet
Share
More Decks by Yukimitsu Izawa
See All by Yukimitsu Izawa
KVM-Mをつくったはなし
izawa
1
97
RubyでXDPプログラミング
izawa
0
49
軽くて強い素材を求めて(DCFのススメ)
izawa
1
150
指紋認証でsshログイン
izawa
0
400
展示会に出展してみた
izawa
0
220
エアコンの操作についての話
izawa
0
850
SlackにZoomの使用状況を表示したい
izawa
0
240
Kindleページめくり君 Ver.2
izawa
0
270
災害グッズとして見たときのキャンプ用品
izawa
0
340
Other Decks in Programming
See All in Programming
私はどうやって技術力を上げたのか
yusukebe
43
18k
大規模アプリのDIフレームワーク刷新戦略 ~過去最大規模の並行開発を止めずにアプリ全体に導入するまで~
mot_techtalk
0
430
iOSエンジニア向けの英語学習アプリを作る!
yukawashouhei
0
190
Pythonスレッドとは結局何なのか? CPython実装から見るNoGIL時代の変化
curekoshimizu
5
1.7k
Things You Thought You Didn’t Need To Care About That Have a Big Impact On Your Job
hollycummins
0
210
育てるアーキテクチャ:戦い抜くPythonマイクロサービスの設計と進化戦略
fujidomoe
1
170
ソフトウェア設計の実践的な考え方
masuda220
PRO
4
550
XP, Testing and ninja testing ZOZ5
m_seki
3
600
Catch Up: Go Style Guide Update
andpad
0
210
Go Conference 2025: Goで体感するMultipath TCP ― Go 1.24 時代の MPTCP Listener を理解する
takehaya
8
1.6k
Web Components で実現する Hotwire とフロントエンドフレームワークの橋渡し / Bridging with Web Components
da1chi
3
2k
Cursorハンズオン実践!
eltociear
2
920
Featured
See All Featured
The Art of Programming - Codeland 2020
erikaheidi
56
14k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
132
19k
Embracing the Ebb and Flow
colly
88
4.8k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.2k
The Straight Up "How To Draw Better" Workshop
denniskardys
237
140k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
34
6.1k
Writing Fast Ruby
sferik
629
62k
How GitHub (no longer) Works
holman
315
140k
How to Ace a Technical Interview
jacobian
280
24k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
9
860
The Pragmatic Product Professional
lauravandoore
36
6.9k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
46
7.7k
Transcript
2012.08.18 Kanazawa.rb #1 Playing with JAX Yukimitsu Izawa 128݄19༵
What’s JAX ✤ JAX is a development framework ✤ for
JavaScript-driven WebGL applications ✤ JAX has MVC architecture ✤ JAX lives with RoR source tree ✤ app/assets/jax/{controllers,models,views,etc.} 128݄19༵
What’s WebGL ✤ WebGL(Web Graphics Library) is a JavaScript API
✤ for rendering 3D/2D graphics within any compatible Web browser ✤ for more info. ✤ http://www.khronos.org/webgl/ 128݄19༵
Hands on! 128݄19༵
Teatime ✤ Initialize Gemfile: gem ’jax’, ’>=2.0’ % bundle %
rails generate jax:install or % gem install jax % jax new demo 128݄19༵
Teatime ✤ Generate % jax generate scaffold teapot % jax
generate light sun directional % jax generate light candle point 128݄19༵
Teatime ✤ Code (Controller) app/assets/jax/controllers/ teapot_controller.js.coffee @world.addObject Teapot.find "actual" @world.addLightSource
"sun" @world.addLightSource "candle" 128݄19༵
Teatime ✤ Code (Model) app/assets/jax/models/ teapot.js.coffee after_initialize: -> @mesh =
new Jax.Mesh.Teapot size: this.size material: "teapot" update: () -> @camera.rotate 0.05, [0,1,0] 128݄19༵
Teatime ✤ Code (teapot’s resources) app/assets/jax/resources/teapots/ actual.resource size: 1.0 position:
x: 0 y: 0 z: -5 128݄19༵
Teatime ✤ Code (candle’s resources) app/assets/jax/resources/light_sources/ candle.resource position: x: -1.2
y: -1.2 z: -4.0 color: ambient: red: 1.0 green: 0.2 blue: 0.2 128݄19༵
Teatime ✤ run % jax server (access localhost:3000 with browser)
128݄19༵
Teatime ✤ You can see, Pink Rotation Teapot :) 128݄19༵
References ✤ Getting Started with JAX ✤ http://guides.jaxgl.com/getting_started.html ✤ JAX
Source Code in Github ✤ https://github.com/sinisterchipmunk/jax ✤ Forum ✤ http://blog.jaxgl.com/forum/jax-group1/jax-forum1/ ✤ API ✤ http://guides.jaxgl.com/api/js/index.html 128݄19༵