LoginSignup
0
1

More than 1 year has passed since last update.

Unity 基本まとめ

Last updated at Posted at 2022-07-30

目的

他エンジンとごっちゃになる事があるため。

座標系

左手y-up
左手系なので、軸先端から中心を見て時計回りが正方向

ポリゴンの向き

N字(時計回りが正)

行列のメジャー

c# 列メジャー
shader : 行メジャー

Quartenionの順序

計算順序

ZXY

Pivot とCenter

Center : Unityが表示する座標系が基準
pivot : 3dモデリングツールが表示する座標系が基準
image.png

Quartenion

回転情報のみ、スケール情報は捨てられる。

Aos/SoA

AoS(array of structures)
SoA(structure of arrays)

# 座標の親子関係


local_position = 0
local_rattion = 0
local_scale = 1,1,1

子供:Blazer_chinatsu
local_position = (3,3,3)
local_rattion = 0,0,0

image.png

(1) 親のscale.z = -1 (z軸反転)
この状態で、親のlocal_scale = 1,1,-1 とする。これはZ軸の反転となる。

位置も移動する。

image.png

(2) 子のscale.z = -1

親のscaleを初期状態に戻してから、子供のscale.z = -1 にする。
これはその場でZ軸反転をする。

image.png

(3) 子供のlocal_rotation = 0,45,0
回転に関しても同じで、子供を回転させた場合はその場で回転する。

image.png

(4) 親のlocal_rotation = 0,45,0

親を回転させた場合は、原点を中心に移動する。
image.png

主要な座標系

Unity UnReal Blender
1 2 3
左手Yup 左手Zup 右手Zup
FBX 3dtile glTF
選択できる 2 image.png
左手Yup 左手Zup 6

メモ:http://www.f.waseda.jp/moriya/PUBLIC_HTML/education/classes/infomath6/applet/fractal/coord/

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1