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
310
Playing With JAX
Lightning talk material.
Yukimitsu Izawa
August 19, 2012
Tweet
Share
More Decks by Yukimitsu Izawa
See All by Yukimitsu Izawa
軽くて強い素材を求めて(DCFのススメ)
izawa
1
75
指紋認証でsshログイン
izawa
0
250
展示会に出展してみた
izawa
0
150
エアコンの操作についての話
izawa
0
610
SlackにZoomの使用状況を表示したい
izawa
0
170
Kindleページめくり君 Ver.2
izawa
0
200
災害グッズとして見たときのキャンプ用品
izawa
0
270
アレクサがカメラ女子になった日
izawa
0
280
2019年上半期のキャンプお買い物ベスト8
izawa
0
300
Other Decks in Programming
See All in Programming
受け取る人から提供する人になるということ
little_rubyist
0
250
Generative AI Use Cases JP (略称:GenU)奮闘記
hideg
1
300
3 Effective Rules for Using Signals in Angular
manfredsteyer
PRO
1
100
Enabling DevOps and Team Topologies Through Architecture: Architecting for Fast Flow
cer
PRO
0
340
ヤプリ新卒SREの オンボーディング
masaki12
0
130
[Do iOS '24] Ship your app on a Friday...and enjoy your weekend!
polpielladev
0
110
Snowflake x dbtで作るセキュアでアジャイルなデータ基盤
tsoshiro
2
520
Realtime API 入門
riofujimon
0
150
タクシーアプリ『GO』のリアルタイムデータ分析基盤における機械学習サービスの活用
mot_techtalk
4
1.5k
Click-free releases & the making of a CLI app
oheyadam
2
120
ペアーズにおけるAmazon Bedrockを⽤いた障害対応⽀援 ⽣成AIツールの導⼊事例 @ 20241115配信AWSウェビナー登壇
fukubaka0825
6
2k
Creating a Free Video Ad Network on the Edge
mizoguchicoji
0
120
Featured
See All Featured
Building a Modern Day E-commerce SEO Strategy
aleyda
38
6.9k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
27
4.3k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
364
24k
Large-scale JavaScript Application Architecture
addyosmani
510
110k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
Fireside Chat
paigeccino
34
3k
Thoughts on Productivity
jonyablonski
67
4.3k
What's new in Ruby 2.0
geeforr
343
31k
A better future with KSS
kneath
238
17k
Adopting Sorbet at Scale
ufuk
73
9.1k
Building Better People: How to give real-time feedback that sticks.
wjessup
364
19k
GraphQLとの向き合い方2022年版
quramy
43
13k
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༵