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
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Yukimitsu Izawa
August 19, 2012
Programming
3
340
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
30
Rubyで守る我が家の安心: IoTセンサ ーネットワーク『ゆきそっく』の実践
izawa
0
220
KVM-Mをつくったはなし
izawa
1
130
RubyでXDPプログラミング
izawa
0
72
軽くて強い素材を求めて(DCFのススメ)
izawa
2
170
指紋認証でsshログイン
izawa
0
450
展示会に出展してみた
izawa
0
250
エアコンの操作についての話
izawa
0
890
SlackにZoomの使用状況を表示したい
izawa
0
260
Other Decks in Programming
See All in Programming
Understanding Apache Lucene - More than just full-text search
spinscale
0
110
猫の手も借りたい!ので AIエージェント猫を作って社内に放した話 Claude Code × Container Lambda の Slack Bot "DevNeko"
naramomi7
0
260
コードレビューをしない選択 #でぃーぷらすトウキョウ
kajitack
3
940
AIコードレビューの導入・運用と AI駆動開発における「AI4QA」の取り組みについて
hagevvashi
0
450
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
300
「やめとこ」がなくなった — 1月にZennを始めて22本書いた AI共創開発のリアル
atani14
0
380
DSPy入門 Pythonで実現する自動プロンプト最適化 〜人手によるプロンプト調整からの卒業〜
seaturt1e
1
710
どんと来い、データベース信頼性エンジニアリング / Introduction to DBRE
nnaka2992
1
280
今更考える「単一責任原則」 / Thinking about the Single Responsibility Principle
tooppoo
3
1.6k
CSC307 Lecture 13
javiergs
PRO
0
320
encoding/json/v2のUnmarshalはこう変わった:内部実装で見る設計改善
kurakura0916
0
410
SourceGeneratorのマーカー属性問題について
htkym
0
190
Featured
See All Featured
Git: the NoSQL Database
bkeepers
PRO
432
66k
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
210
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Navigating Team Friction
lara
192
16k
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
1
320
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
Producing Creativity
orderedlist
PRO
348
40k
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.2k
Darren the Foodie - Storyboard
khoart
PRO
3
2.8k
A Modern Web Designer's Workflow
chriscoyier
698
190k
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
RailsConf 2023
tenderlove
30
1.4k
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༵