-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
30 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
...tyPackage/Packages/megumin.explosion4unity/Runtime/Scripts/NewClass/Test/Matrix4x4Test.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
using System.Collections; | ||
using System.Collections.Generic; | ||
using System.ComponentModel; | ||
using UnityEngine; | ||
|
||
namespace Megumin | ||
{ | ||
public class Matrix4x4Test : MonoBehaviour | ||
{ | ||
[Editor] | ||
public void Test() | ||
{ | ||
var l2w = transform.localToWorldMatrix; | ||
var w2l = transform.worldToLocalMatrix; | ||
Debug.Log($"localToWorldMatrix \n{l2w}"); | ||
Debug.Log($"worldToLocalMatrix \n{w2l}"); | ||
var result1 = l2w * w2l; | ||
var result2 = w2l * l2w; | ||
var result3 = l2w.inverse == w2l; | ||
var result4 = l2w == w2l.inverse; | ||
Debug.Log($"{result1}\n ---- \n{result2}\n ---- \n{result3}\n ---- \n{result4}"); | ||
} | ||
} | ||
} | ||
|
||
|
||
|
2 changes: 2 additions & 0 deletions
2
...kage/Packages/megumin.explosion4unity/Runtime/Scripts/NewClass/Test/Matrix4x4Test.cs.meta
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.