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
330
Playing With JAX
Lightning talk material.
Yukimitsu Izawa
August 19, 2012
Tweet
Share
More Decks by Yukimitsu Izawa
See All by Yukimitsu Izawa
3Dプリンター未経験者が初めてプリントできた道のり
izawa
0
22
Rubyで守る我が家の安心: IoTセンサ ーネットワーク『ゆきそっく』の実践
izawa
0
180
KVM-Mをつくったはなし
izawa
1
110
RubyでXDPプログラミング
izawa
0
60
軽くて強い素材を求めて(DCFのススメ)
izawa
1
160
指紋認証でsshログイン
izawa
0
420
展示会に出展してみた
izawa
0
230
エアコンの操作についての話
izawa
0
870
SlackにZoomの使用状況を表示したい
izawa
0
250
Other Decks in Programming
See All in Programming
クラウドに依存しないS3を使った開発術
simesaba80
0
200
AIエージェントの設計で注意するべきポイント6選
har1101
6
2.8k
脳の「省エネモード」をデバッグする ~System 1(直感)と System 2(論理)の切り替え~
panda728
PRO
0
130
リリース時」テストから「デイリー実行」へ!開発マネージャが取り組んだ、レガシー自動テストのモダン化戦略
goataka
0
150
チームをチームにするEM
hitode909
0
420
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
150
Deno Tunnel を使ってみた話
kamekyame
0
280
ZJIT: The Ruby 4 JIT Compiler / Ruby Release 30th Anniversary Party
k0kubun
1
300
0→1 フロントエンド開発 Tips🚀 #レバテックMeetup
bengo4com
0
440
愛される翻訳の秘訣
kishikawakatsumi
3
360
Implementation Patterns
denyspoltorak
0
140
The Art of Re-Architecture - Droidcon India 2025
siddroid
0
150
Featured
See All Featured
The SEO identity crisis: Don't let AI make you average
varn
0
42
The Cult of Friendly URLs
andyhume
79
6.7k
The World Runs on Bad Software
bkeepers
PRO
72
12k
Making the Leap to Tech Lead
cromwellryan
135
9.7k
GitHub's CSS Performance
jonrohan
1032
470k
Build your cross-platform service in a week with App Engine
jlugia
234
18k
Odyssey Design
rkendrick25
PRO
0
450
Technical Leadership for Architectural Decision Making
baasie
0
200
Imperfection Machines: The Place of Print at Facebook
scottboms
269
13k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
0
34
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
128
55k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.1k
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༵