Home
Explore
Submit Search
Upload
Login
Signup
Advertisement
Firefox os関東勉強会20130719
Report
Takashi Yasukawa
Follow
代表社員 at DWORD LLC.
Jul. 19, 2013
•
0 likes
4 likes
×
Be the first to like this
Show More
•
1,825 views
views
×
Total views
0
On Slideshare
0
From embeds
0
Number of embeds
0
Check these out next
The Student's Guide to LinkedIn
LinkedIn
Different Roles in Machine Learning Career
Intellipaat
Defining a Tech Project Vision in Eight Quick Steps pdf
TechSoup
The Hero's Journey (For movie fans, Lego fans, and presenters!)
Dan Roam
10 Inspirational Quotes for Graduation
Guy Kawasaki
The Health Benefits of Dogs
The Presentation Designer
The Benefits of Doing Nothing
INSEAD
A non-technical introduction to ChatGPT - SEDA.pptx
Sue Beckingham
1
of
20
Top clipped slide
Firefox os関東勉強会20130719
Jul. 19, 2013
•
0 likes
4 likes
×
Be the first to like this
Show More
•
1,825 views
views
×
Total views
0
On Slideshare
0
From embeds
0
Number of embeds
0
Download Now
Download to read offline
Report
Takashi Yasukawa
Follow
代表社員 at DWORD LLC.
Advertisement
Advertisement
Advertisement
Recommended
僕が構文解析にこんなにも時間をかけてしまった理由 〜Yacc/Bisonにおけるノウハウ〜
Yuki Ito
1.2K views
•
67 slides
zshでコマンドライン履歴を活用する
Hideaki Miyake
1.2K views
•
40 slides
pecoを使おう
Hideaki Miyake
3.7K views
•
54 slides
Zombie2601 2011 06-06
kiwofusi
516 views
•
14 slides
Stage 3 a minna l26 ndesu 2018
MikiUoN17
50 views
•
17 slides
Devsumi2012フィードバック オープニング
Rakuten Group, Inc.
682 views
•
10 slides
More Related Content
Featured
(20)
The Student's Guide to LinkedIn
LinkedIn
•
77.5K views
Different Roles in Machine Learning Career
Intellipaat
•
9.2K views
Defining a Tech Project Vision in Eight Quick Steps pdf
TechSoup
•
7.3K views
The Hero's Journey (For movie fans, Lego fans, and presenters!)
Dan Roam
•
27.2K views
10 Inspirational Quotes for Graduation
Guy Kawasaki
•
300.5K views
The Health Benefits of Dogs
The Presentation Designer
•
33.2K views
The Benefits of Doing Nothing
INSEAD
•
49.9K views
A non-technical introduction to ChatGPT - SEDA.pptx
Sue Beckingham
•
17.7K views
The Dungeons & Dragons Guide to Marketing
Ian Lurie
•
15.6K views
How You Can Change the World
24Slides
•
57.4K views
signmesh snapshot - the best of sustainability
signmesh
•
9.4K views
The Science of a Great Career in Data Science
Kate Matsudaira
•
38.1K views
The ABC’s of Living a Healthy Life
Dr. Omer Hameed
•
1.1M views
CAREER FORWARD - THE TOOLS YOU NEED TO START MOVING
Kelly Services
•
2.8K views
Top 5 Skills for Project Managers
LinkedIn Learning Solutions
•
22.7K views
Mind-Blowing Facts About National Parks
Ethos3
•
43.2K views
8 Easy Ways to Relieve Stress At Work (Backed By Science)
True Stress Management
•
2.7K views
ChatGPT What It Is and How Writers Can Use It.pdf
Adsy
•
31.5K views
Pixar's 22 Rules to Phenomenal Storytelling
Gavin McMahon
•
4.6M views
2022 Women in the Workplace Briefing
McKinsey & Company
•
22.7K views
Advertisement
Firefox os関東勉強会20130719
関東Firefox OS勉強会 2nd 3次元のJSをおさわりする
本日のレシピ FirefoxOSで3次元CGを扱うために用意するもの ポリゴンを表示するにはこの3つが必要
右手座標系と右ネジの法則 カメラと視錐台(視野) ポリゴンと色 デモを動かしてみる
自己紹介
自己紹介(twitter:@inuchin 安川貴志) 3次元の嫁より2.5次元の嫁がいいです。
15年ほど出版やゲーム関係に従事 武礼堂/DWORDで作品がいくつか。 現在は株式会社ブリリアントサービス所属 最近だとこんな仕事をしてました。
http://www.youtube.com/user/koihimearcade?feature=watch
ポリゴンを表示するに はこの3つが必要
FirefoxOSで3次元CGを扱うために 用意するもの three.js http://threejs.org/
右手座標系 右ネジの法則
右手座標系 指先が+方向として、 親指:X座標 人差し指:Y座標 中指:Z座標 となる X Y Z
m9(^Д^)プギャーwwwwww ではないので注意
右ねじの法則 Y 親指の方向が 回転させたい軸 残りの4本の指の 指先方向に回転する。 回転角度θは、ラジアン(rad)で表記 rad = θ
✕ π / 180
角度(度数法)をラジアンに変換する公式
カメラと視錐台(視野)
カメラと視錐台 1 1 カメラの座標を(0,1,1)に設定 カメラは、どの座標からドッチの 向き(座標)にあるポリゴンを描画 するかを決める。 さらにカメラにはUPベクトルが あり、カメラの上方向を定義する ことができる。 カメラのUPベクトルを変えると、 画面全体が回転する(ロール)
カメラと視錐台 視錐台(PerspectiveCamera)を (90, aspect比, 1,
1000)に設定 1 1000 視錐台は、左の点線に囲まれた領 域のみを描画する為に設定します。 視野角(上下左右90度の範囲内)で、 かつ距離が1〜1000までの間に 入っているポリゴンが描画対象
three.jsのコードで表現 var aspect =
window.innerWidth / window.innerHeight; var camera = new THREE.PerspectiveCamera(90,aspect, 1, 1000); camera.position.x = 0; camera.position.z = 1; camera.position.y = 1; camera.up.x = 0; camera.up.y = 1; camera.up.z = 0;
ポリゴンと色
ポリゴンと色 1)レンダリング方法の設定 2)ポリゴンは組み込みのプリミティブから作成 3)マテリアル(素材)をポリゴンに設定する
three.jsのコードで表現 for ( var
i = 0; i < 500; i ++ ) { material = new THREE.MeshPhongMaterial( { specular: 0xffffff, shading: THREE.FlatShading, vertexColors: THREE.VertexColors } ); var size = Math.random() * 10.0 + 10.0; geometry = new THREE.CubeGeometry( size, size, size ); var mesh = new THREE.Mesh( geometry, material ); mesh.position.x = Math.floor( Math.random() * 20 - 10 ) * 20; mesh.position.y = Math.floor( Math.random() * 20 ) * 20 + 10; mesh.position.z = Math.floor( Math.random() * 20 - 10 ) * 20; scene.add( mesh ); material.color.setHSL( Math.random() * 1.0, 0.75, Math.random() * 0.25 + objects.push( mesh ); } 1 2 3
デモンストレーション
Advertisement