├── LICENSE.txt
├── README.md
└── sample
├── .gitignore
├── Assembly-UnityScript-vs.unityproj
├── Assembly-UnityScript.unityproj
├── Assets
├── Editor.meta
├── Editor
│ ├── Chapter04Editor.cs
│ ├── Chapter04Editor.cs.meta
│ ├── Chapter05Editor.cs
│ └── Chapter05Editor.cs.meta
├── Meshes.meta
├── Meshes
│ ├── Materials.meta
│ ├── Materials
│ │ ├── BaseMat.mat
│ │ ├── BaseMat.mat.meta
│ │ ├── Clear Coat Plastic.mat
│ │ ├── Clear Coat Plastic.mat.meta
│ │ ├── No Name.mat
│ │ ├── No Name.mat.meta
│ │ ├── TopMat.mat
│ │ ├── TopMat.mat.meta
│ │ ├── buddhaMat.mat
│ │ ├── buddhaMat.mat.meta
│ │ ├── defaultMat.mat
│ │ └── defaultMat.mat.meta
│ ├── StanfordHappyBuddha.obj
│ ├── StanfordHappyBuddha.obj.meta
│ ├── UtahTeapot.obj
│ └── UtahTeapot.obj.meta
├── Prefabs.meta
├── Resources.meta
├── Resources
│ ├── Materials.meta
│ └── Materials
│ │ ├── CookTorrance.mat
│ │ ├── CookTorrance.mat.meta
│ │ ├── DiffuseMaterial.mat
│ │ ├── DiffuseMaterial.mat.meta
│ │ ├── Gouraud.mat
│ │ ├── Gouraud.mat.meta
│ │ ├── HalfLambertMaterial.mat
│ │ ├── HalfLambertMaterial.mat.meta
│ │ ├── NormalMap.mat
│ │ ├── NormalMap.mat.meta
│ │ ├── Phong.mat
│ │ ├── Phong.mat.meta
│ │ ├── Rim.mat
│ │ ├── Rim.mat.meta
│ │ ├── TestMaterial.mat
│ │ ├── TestMaterial.mat.meta
│ │ ├── TextureMap.mat
│ │ ├── TextureMap.mat.meta
│ │ ├── image_normal.JPG
│ │ ├── image_normal.JPG.meta
│ │ ├── image_texture.JPG
│ │ └── image_texture.JPG.meta
├── Scenes.meta
├── Scenes
│ ├── Chapter01.unity
│ ├── Chapter01.unity.meta
│ ├── Chapter02.unity
│ ├── Chapter02.unity.meta
│ ├── Chapter03.unity
│ ├── Chapter03.unity.meta
│ ├── Chapter04.unity
│ ├── Chapter04.unity.meta
│ ├── Chapter05.unity
│ ├── Chapter05.unity.meta
│ ├── Chapter06.unity
│ ├── Chapter06.unity.meta
│ ├── Chapter07.unity
│ ├── Chapter07.unity.meta
│ ├── Chapter09.unity
│ ├── Chapter09.unity.meta
│ ├── Main.unity
│ └── Main.unity.meta
├── Scripts.meta
├── Scripts
│ ├── Chapter01.cs
│ ├── Chapter01.cs.meta
│ ├── Chapter02.cs
│ ├── Chapter02.cs.meta
│ ├── Chapter03.cs
│ ├── Chapter03.cs.meta
│ ├── Chapter04.cs
│ ├── Chapter04.cs.meta
│ ├── Chapter05.cs
│ ├── Chapter05.cs.meta
│ ├── Chapter06.cs
│ ├── Chapter06.cs.meta
│ ├── Chapter07.cs
│ ├── Chapter07.cs.meta
│ ├── Chapter09.cs
│ ├── Chapter09.cs.meta
│ ├── SceneLoader.cs
│ └── SceneLoader.cs.meta
├── Shader.meta
└── Shader
│ ├── CookTorrance.shader
│ ├── CookTorrance.shader.meta
│ ├── Diffuse.shader
│ ├── Diffuse.shader.meta
│ ├── Gouraud.shader
│ ├── Gouraud.shader.meta
│ ├── HalfLambert.shader
│ ├── HalfLambert.shader.meta
│ ├── NormalMap.shader
│ ├── NormalMap.shader.meta
│ ├── Phong.shader
│ ├── Phong.shader.meta
│ ├── Rim.shader
│ ├── Rim.shader.meta
│ ├── Test.shader
│ ├── Test.shader.meta
│ ├── TextureMap.shader
│ └── TextureMap.shader.meta
├── Library
├── AnnotationManager
├── BuildPlayer.prefs
├── BuildSettings.asset
├── CurrentLayout.dwlt
├── CurrentMaximizeLayout.dwlt
├── EditorUserBuildSettings.asset
├── EditorUserSettings.asset
├── InspectorExpandedItems.asset
├── LastSceneManagerSetup.txt
├── LibraryFormatVersion.txt
├── MonoManager.asset
├── ProjectSettings.asset
├── SpriteAtlasDatabase.asset
├── TilemapEditorUserSettings.asset
└── expandedItems
├── ProjectSettings
├── AudioManager.asset
├── ClusterInputManager.asset
├── DynamicsManager.asset
├── EditorBuildSettings.asset
├── EditorSettings.asset
├── GraphicsSettings.asset
├── InputManager.asset
├── NavMeshAreas.asset
├── NetworkManager.asset
├── Physics2DSettings.asset
├── ProjectSettings.asset
├── ProjectVersion.txt
├── QualitySettings.asset
├── TagManager.asset
├── TimeManager.asset
└── UnityConnectSettings.asset
└── UnityPackageManager
└── manifest.json
/LICENSE.txt:
--------------------------------------------------------------------------------
1 | (C) 2015 Ryuichi KUBUKI
2 |
3 | The contents of this repository are licensed under CC BY-NC-SA/Creative Commons Attribution Non-Commercial Share-Alike 4.0
4 | https://creativecommons.org/licenses/by-nc-sa/4.0/legalcode
5 |
6 |
7 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # ゲームアプリの数学 サンプルコード
2 |
3 | 本gitレポジトリーは『[ゲームアプリの数学 Unityで学ぶ基礎からシェーダーまで](http://amzn.to/1UR7vmm) 』(久富木 隆一 著/SBクリエイティブ 刊)のためのサンプルコードならびに著者により更新されるサポート情報を保持します。
4 |
5 | 上記書籍は、本サンプルコードへの必要十分な注釈を含んでいます。書籍を手元に置いて参照しつつ、Unityで本サンプルコードを動かしたり、あるいは自由に改変したりして、動作結果を視覚的に確認することにより、書籍の内容を直感的に理解し応用につなげることができます。
6 |
7 | 本ページと合わせ、正誤表他の情報が記載されたSBクリエイティブ社[サポートページ](http://www.sbcr.jp/products/4797384260.html)も参照ください。
8 |
9 | ## 更新履歴
10 |
11 | * 2018-02-12 Unity 2017.3サポート(Unity 2017.3.1f1)
12 | * 2017-01-22 第5章サンプルコードDirect3D11向け修正。第5章、第7章補遺追加
13 | * 2017-01-07 Unity 5.5/5.4サポート(Unity 5.5.0f3)、_Object2World、varyingについて補遺追加
14 | * 2015-12-18 著者講演資料追加
15 | * 2015-12-18 Unity 5.3サポート(Unity 5.3.0f4)
16 | * 2015-12-18 Unity 5.2向けブランチ追加(Unity_5.2)(Unity 5.2.4f1)
17 | * 2015-09-29 補遺追加
18 | * 2015-09-26 補遺追加
19 | * 2015-09-22 補遺追加
20 | * 2015-09-19 初版
21 |
22 | ## 動作環境
23 |
24 | * **Unity 5.6.0** 以降
25 | - Unity 5.5.x以前でサンプルを実行したい場合は[Unity_5.5ブランチ](https://github.com/ryukbk/mobile_game_math_unity/tree/Unity_5.5)を取得して下さい。
26 | - Unity 5.3.4以前でサンプルを実行したい場合は[Unity_5.3.4ブランチ](https://github.com/ryukbk/mobile_game_math_unity/tree/Unity_5.3.4)を取得して下さい。
27 | - Unity 5.2.x以前でサンプルを実行したい場合は[Unity_5.2ブランチ](https://github.com/ryukbk/mobile_game_math_unity/tree/Unity_5.2)を取得してください。
28 | - Microsoft Windows 7 以降
29 | - Mac OS X 10.10 以降
30 | * Unityは、Unity Technologies社のwebサイトから無料のPersonal Editionを選択してダウンロードし、インストールしてください。
31 | - [最新バージョン](https://unity3d.com/jp/get-unity/download)
32 | - [過去のバージョン](https://unity3d.com/jp/get-unity/download/archive)
33 | - [最新バージョン以降のパッチリリース](https://unity3d.com/jp/unity/qa/patch-releases)
34 | * 本サンプルコードは上記バージョンのUnityでの実行を前提としているため、それ以前のバージョンのUnityを同一マシン上で利用しなければならない場合は、[異なるバージョンの同時インストール](http://docs.unity3d.com/ja/current/Manual/InstallingUnity.html)の項目に従いUnity複数バージョンの共存環境を作成してください。
35 |
36 | ## ダウンロード
37 |
38 | 最新のサンプルコードは本gitレポジトリーのmasterブランチに収録されています。
39 |
40 | 以下のいずれかの方法でサンプルコードを取得してください。
41 |
42 | * 本レポジトリーのメニュー内の"Download ZIP"ボタンから一括ダウンロード
43 | * gitクライアントでローカルPCへ本レポジトリーをclone
44 | * githubアカウント所持者であれば、本レポジトリーを自己レポジトリーへfork
45 |
46 | ## ファイル構成
47 |
48 | * sampleフォルダー内にサンプルコードのUnityプロジェクトが存在し、中のAssetsフォルダーにプロジェクトを構成するファイル群が含まれます。
49 | - Editor: Unity Editor拡張
50 | - Meshes: インポート元3Dメッシュ
51 | - Resources: マテリアル
52 | - Scenes: Unityシーン
53 | - Scripts: C#スクリプトコンポーネント
54 | - Shader: GLSLシェーダープログラム
55 |
56 | ## 実行方法
57 |
58 | Unityで、Unityプロジェクトとしてsampleフォルダーを開き、シーン再生ボタンを押下してください。
59 |
60 | ## 正誤表
61 |
62 | 書籍出版後に判明した本文中の誤記とその訂正は、SBクリエイティブ社[サポートページ正誤情報](http://www.sbcr.jp/support/12645.html)に掲載しておりますので、お問い合わせ前にご確認ください。
63 |
64 | ## 補遺
65 |
66 | * 前書き
67 | - 代表的なDCCツールとしてAutodesk Mayaを挙げていますが、他に、無料でオープンソースの3Dモデリングツールとして[Blender](https://www.blender.org/)が有名です。
68 | * 第5章
69 | - サンプルコードのプロジェクトでは、Unity EditorメニューのFile | Build Settings | Player Settings | Graphics API for Windowsの設定は、デフォルトではOpenGL系レンダラーであるOpenGLES3が最上位で最優先と設定されているため、Windows上でもOpenGL系のプロジェクション変換行列となります。Direct3D9レンダラーを最上位に設定すると、本文133ページのプロジェクション変換行列となります。
70 | - Unity 5.5からの[変更点(Shaders: Z-buffer float inverted)](https://docs.unity3d.com/550/Documentation/Manual/UpgradeGuide55.html)として、Graphics API for Windows設定でDirect3D11レンダラーを最上位に設定した場合、従来のDirect3D9レンダラーと異なり、プロジェクション変換行列Pのz軸範囲が[1, 0]に写像されるようになります。これに伴い、本文133ページのWindows上でのプロジェクション変換行列の3行3列は、3行4列はとなります。同様に、144ページでのDirect3D向けのz軸範囲の写像しなおしも、最新サンプルコードはDirect3D11レンダラー上では[1, 0]になるよう処理を行います。
71 |
72 | ```
73 | for (int i = 0; i < 4; i++) {
74 | pm[2, i] = pm[2, i] * -0.5f + pm[3, i] * 0.5f;
75 | }
76 | ```
77 |
78 | Unity 5.5でのDirect3D11レンダラーの変更は、本文234ページで触れているデプス(深度)バッファー/Zバッファーの精度を、(Direct3D 9では利用できなかった)浮動小数点精度を用いて向上させるとともに、[reverse-Z](https://developer.nvidia.com/content/depth-precision-visualized)として知られる[1, 0]への写像により遠景部分で精度を向上させるものです。精度向上のためのテクニックとして、他に[対数デプスバッファー(Logarithmic Depth Buffers)](http://qpp.bitbucket.org/translation/maximizing_depth_buffer_range_and/)があります。
79 | * 第6章
80 | - クォータニオンは`w`、`x`、`y`、`z`の4つの数値の組として表現されますが、回転のために用いる正規化されたクォータニオンであれば、大きさが1でありが成立することを利用して3つの数値があれば残り1つの数値を求められるため、精度を落として`w`の符号をいずれかの数値内のビットに保存するなどの処理を入れれば3つの数値の組としてさらにコンパクトな形式で保存できます。
81 | - 正規化されたクォータニオンの逆数を与えて回転すると、元のクォータニオンによる回転の逆回転となります。サンプルコード中の`Quaternion.Inverse`は、引数として与えた正規化されたクォータニオンの逆数を返します。
82 | * 第7章
83 | - 本文181ページの曲線当てはめは、本文168ページで紹介しているスケルタルアニメーションを実現するために、キーフレームアニメーションの元データを[Catmull-Romスプラインのような曲線アルゴリズムで近似することによりデータ量を圧縮する](https://engineering.riotgames.com/news/compressing-skeletal-animation-data)のに利用されることがあります。
84 | * 第8章
85 | - TBDRのメリット/デメリットについては、同じ章で後に存在するグラフィックスパイプライン解説の読後に再度読んでみてください。
86 | - 遅延シェーディングは、第9章で触れているマルチパスレンダリングを行っています。Gバッファーの作成までがpass 1、Gバッファーを用いて行われる(pass 1ではあえて行わずに次のpassまで遅延された)照明計算がpass 2です。
87 | * 第9章
88 | - 4次元ベクトルを表す型`vec4`は`x`、`y`、`z`、`w`の4つのメンバー変数を持つ構造体であり、`packednormal`はビットマップの1ピクセルを表す`vec4`で、RGBA各チャンネルを各メンバー変数に格納しています。つまり`packednormal.w`にA(アルファ)が、`packednormal.y`にG(緑)が入っているので、スウィズル演算子`wy`を使い、`w`と`y`を`vec2`として抜き出して展開します。
89 | - サンプルコードのChapter09シーンに以下2点の仕様を追加
90 | 1. シーン再生時に光源を回転
91 | 1. [有名な3Dモデル](https://en.wikipedia.org/wiki/List_of_common_3D_test_models)である、[Utar teapot](https://ja.wikipedia.org/wiki/Utah_teapot)と、スタンフォード大学の[Happy Buddha](http://graphics.stanford.edu/data/3Dscanrep/)を、Blenderにインポート。Blender上で以下改変を適用して[Wavefront objフォーマット](https://en.wikipedia.org/wiki/Wavefront_.obj_file)でエクスポートし、Unityのシーン内に配置
92 | - オリジナルのマテリアルを削除
93 | - サブメッシュをjoin
94 | - メッシュ内の三角形の数が16ビットで表現できない数値(65535)以上であるとUnityでのインポート時にサブメッシュに分割されるため、Decimate ModifierでFace Countを65534以下に削減
95 | - Unity 5.3.5以降では、シェーダープログラム内でのモデル変換行列`_Object2World`の定義が、UnityCG.glslinc内では廃止されていますので、シェーダープログラムを書く際には、代わりに新しく定義された`unity_ObjectToWorld`を使用して下さい。(本レポジトリー内でのサンプルコードでは、`_Object2World`が定義されていない場合は`unity_ObjectToWorld`を用い`_Object2World`を別名として定義するようにしています。)
96 | - Unity 5.5では、MacでのグラフィックスAPIとしてはPlayer Settingsでの設定ではOpenGLCoreのみ選択できOpenGL2が廃止されています。従って、Mac向けにGLSLシェーダープログラムを動作させるためにはOpenGLCoreがサポートするGLSL 1.30に従って書く必要があります。GLSL 1.30では`varying`変数は廃止されており、代わりに、バーテックスシェーダーで出力する変数は`out`指定してバーテックスシェーダー内に定義し、同名の変数を`in`指定してフラグメントシェーダー内に定義しフラグメントシェーダーへの入力とします。
97 |
98 | ## FAQ
99 |
100 | * 随時更新
101 |
102 | ## 著者講演資料
103 |
104 | * [ゲームアプリの数学@Unity Rendering Wizardの集い](http://www.slideshare.net/ryukbk/unity-rendering-wizard)
105 | - 2015年10月22日渋谷dots.で開催された[Unity Rendering Wizardの集い](http://eventdots.jp/event/571325)でのLT資料です。
106 | * [ゲームアプリの数学@プログラマのための数学勉強会](http://www.slideshare.net/ryukbk/ss-55366793)
107 | - 2015年11月21日渋谷dots.で開催された[第5回 プログラマのための数学勉強会](http://eventdots.jp/event/571642) [#maths4pg](https://twitter.com/hashtag/maths4pg?src=hash)でのLT資料です。
108 | * [ゲームアプリの数学@GREE GameDevelopers' Meetup](http://www.slideshare.net/ryukbk/gree-gamedevelopers-meetup)
109 | - 2015年12月16日六本木ヒルズのグリー株式会社で開催された[GREE GameDevelopers' Meetup 02](http://greegdm02.peatix.com/) [#greegdm02](https://twitter.com/hashtag/greegdm02?src=hash)での講演資料です。書籍『ゲームアプリの数学 Unityで学ぶ基礎からシェーダーまで』の紹介、番外編(レイトレーシング/レイマーチング/SDFなど、ラスタライズを行わない非ポリゴンベースの3Dグラフィックスの紹介)、ゲーム開発の未来展望(手続き生成、機械学習/ディープラーニング、モバイルVRなど)から成ります。
110 |
111 | ## 著作権表示/ライセンス
112 |
113 | (C) 2015-2018 Ryuichi KUBUKI (久富木 隆一)
114 |
115 | 本サンプルコードは[CC BY-NC-SA/Creative Commons Attribution Non-Commercial Share-Alike 4.0](https://creativecommons.org/licenses/by-nc-sa/4.0/legalcode.ja)でライセンスされています。
116 |
117 | The contents of this repository are licensed under [CC BY-NC-SA/Creative Commons Attribution Non-Commercial Share-Alike 4.0](https://creativecommons.org/licenses/by-nc-sa/4.0/legalcode).
118 |
119 | ## 著者連絡先
120 |
121 | * [Twitter](https://twitter.com/ryukbk)
122 | * [blog](http://ryukbk.blogspot.jp/)
123 |
124 |
125 |
--------------------------------------------------------------------------------
/sample/.gitignore:
--------------------------------------------------------------------------------
1 | /Temp
2 | /Library/metadata
3 | /Library/ShaderCache
4 | /Library/*.log
5 | /Library/ScriptAssemblies
6 | /Library/assetDatabase3
7 | /Library/ShaderCache.db
8 | /Library/CrashedAssetImports.txt
9 | /Library/ScriptMapper
10 | /Library/AssetServerCacheV3
11 | /Library/guidmapper
12 | /Library/AssetImportState
13 | /Library/AssetVersioning.db
14 |
15 | /obj
16 |
17 | *.csproj
18 | *.sln
19 | *.suo
20 |
21 | /*.userprefs
22 |
23 | .DS_Store
24 |
--------------------------------------------------------------------------------
/sample/Assembly-UnityScript-vs.unityproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Debug
5 | AnyCPU
6 | 10.0.20506
7 | 2.0
8 | {BF78F8D2-EE94-5B1A-6FF5-F20F819533A7}
9 | Library
10 | Properties
11 |
12 | Assembly-UnityScript
13 | v3.5
14 | 512
15 | Assets
16 |
17 |
18 | true
19 | full
20 | false
21 | Temp\bin\Debug\
22 | DEBUG;TRACE;UNITY_5_1_1;UNITY_5_1;UNITY_5;ENABLE_NEW_BUGREPORTER;ENABLE_2D_PHYSICS;ENABLE_4_6_FEATURES;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_DUCK_TYPING;ENABLE_FRAME_DEBUGGER;ENABLE_GENERICS;ENABLE_HOME_SCREEN;ENABLE_IMAGEEFFECTS;ENABLE_LIGHT_PROBES_LEGACY;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_PHYSICS_PHYSX3;ENABLE_PLUGIN_INSPECTOR;ENABLE_SHADOWS;ENABLE_SINGLE_INSTANCE_BUILD_SETTING;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_UNET;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_UNET;ENABLE_CLOUD_LICENSE;ENABLE_AUDIOMIXER_SUSPEND;ENABLE_EDITOR_METRICS;INCLUDE_DYNAMIC_GI;INCLUDE_GI;INCLUDE_IL2CPP;INCLUDE_DIRECTX12;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_LOCALIZATION;UNITY_STANDALONE_WIN;UNITY_STANDALONE;ENABLE_SUBSTANCE;ENABLE_TEXTUREID_MAP;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_WEBSOCKET_HOST;ENABLE_MONO;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN
23 | prompt
24 | 4
25 | 0169
26 |
27 |
28 | pdbonly
29 | true
30 | Temp\bin\Release\
31 | TRACE
32 | prompt
33 | 4
34 | 0169
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 | C:/Program Files/Unity/Editor/Data/Managed/UnityEngine.dll
43 |
44 |
45 | C:/Program Files/Unity/Editor/Data/Managed/UnityEditor.dll
46 |
47 |
48 |
49 |
50 |
51 | C:/Program Files/Unity/Editor/Data/UnityExtensions/Unity/GUISystem/UnityEngine.UI.dll
52 |
53 |
54 | C:/Program Files/Unity/Editor/Data/UnityExtensions/Unity/Networking/UnityEngine.Networking.dll
55 |
56 |
57 | C:/Program Files/Unity/Editor/Data/UnityExtensions/Unity/UnityAnalytics/UnityEngine.Analytics.dll
58 |
59 |
60 | C:/Program Files/Unity/Editor/Data/PlaybackEngines/iOSSupport/UnityEditor.iOS.Extensions.Xcode.dll
61 |
62 |
63 |
64 |
71 |
72 |
73 |
--------------------------------------------------------------------------------
/sample/Assembly-UnityScript.unityproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Debug
5 | AnyCPU
6 | 10.0.20506
7 | 2.0
8 | {BF78F8D2-EE94-5B1A-6FF5-F20F819533A7}
9 | Library
10 | Properties
11 |
12 | Assembly-UnityScript
13 | v3.5
14 | 512
15 | Assets
16 |
17 |
18 | true
19 | full
20 | false
21 | Temp\bin\Debug\
22 | DEBUG;TRACE;UNITY_5_1_1;UNITY_5_1;UNITY_5;ENABLE_NEW_BUGREPORTER;ENABLE_2D_PHYSICS;ENABLE_4_6_FEATURES;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_DUCK_TYPING;ENABLE_FRAME_DEBUGGER;ENABLE_GENERICS;ENABLE_HOME_SCREEN;ENABLE_IMAGEEFFECTS;ENABLE_LIGHT_PROBES_LEGACY;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_PHYSICS_PHYSX3;ENABLE_PLUGIN_INSPECTOR;ENABLE_SHADOWS;ENABLE_SINGLE_INSTANCE_BUILD_SETTING;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_UNET;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_UNET;ENABLE_CLOUD_LICENSE;ENABLE_AUDIOMIXER_SUSPEND;ENABLE_EDITOR_METRICS;INCLUDE_DYNAMIC_GI;INCLUDE_GI;INCLUDE_IL2CPP;INCLUDE_DIRECTX12;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_LOCALIZATION;UNITY_STANDALONE_WIN;UNITY_STANDALONE;ENABLE_SUBSTANCE;ENABLE_TEXTUREID_MAP;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_WEBSOCKET_HOST;ENABLE_MONO;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN
23 | prompt
24 | 4
25 | 0169
26 |
27 |
28 | pdbonly
29 | true
30 | Temp\bin\Release\
31 | TRACE
32 | prompt
33 | 4
34 | 0169
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 | C:/Program Files/Unity/Editor/Data/Managed/UnityEngine.dll
43 |
44 |
45 | C:/Program Files/Unity/Editor/Data/Managed/UnityEditor.dll
46 |
47 |
48 |
49 |
50 |
51 | C:/Program Files/Unity/Editor/Data/UnityExtensions/Unity/GUISystem/UnityEngine.UI.dll
52 |
53 |
54 | C:/Program Files/Unity/Editor/Data/UnityExtensions/Unity/Networking/UnityEngine.Networking.dll
55 |
56 |
57 | C:/Program Files/Unity/Editor/Data/UnityExtensions/Unity/UnityAnalytics/UnityEngine.Analytics.dll
58 |
59 |
60 | C:/Program Files/Unity/Editor/Data/PlaybackEngines/iOSSupport/UnityEditor.iOS.Extensions.Xcode.dll
61 |
62 |
63 |
64 |
71 |
72 |
73 |
--------------------------------------------------------------------------------
/sample/Assets/Editor.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 13e89e39fcc48ec4a86a4536f77b5d99
3 | folderAsset: yes
4 | timeCreated: 1433755726
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Editor/Chapter04Editor.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using UnityEditor;
4 |
5 | [CustomEditor( typeof(Chapter04) )]
6 | public class Chapter04Editor : Editor {
7 |
8 | Matrix4x4 matrix = new Matrix4x4();
9 |
10 | float determinant3x3;
11 | float determinant4x4;
12 |
13 | Vector4 rhs;
14 | Vector4 result;
15 |
16 | public override void OnInspectorGUI() {
17 | // base.OnInspectorGUI ();
18 |
19 | // Hide Script property
20 | serializedObject.Update();
21 | DrawPropertiesExcluding(serializedObject, new string[]{"m_Script"});
22 | serializedObject.ApplyModifiedProperties();
23 |
24 | //Chapter04 obj = target as Chapter04;
25 |
26 | EditorGUI.BeginChangeCheck();
27 |
28 | EditorGUILayout.BeginVertical( GUI.skin.box );
29 |
30 | EditorGUILayout.LabelField(new GUIContent("Matrix4x4"));
31 |
32 | matrix.SetRow(0, RowVector4Field(matrix.GetRow(0)));
33 | matrix.SetRow(1, RowVector4Field(matrix.GetRow(1)));
34 | matrix.SetRow(2, RowVector4Field(matrix.GetRow(2)));
35 | matrix.SetRow(3, RowVector4Field(matrix.GetRow(3)));
36 |
37 | EditorGUILayout.EndVertical();
38 |
39 | EditorGUILayout.BeginVertical( GUI.skin.box );
40 |
41 | determinant3x3 = EditorGUILayout.FloatField("Determinant (3x3)", determinant3x3);
42 | determinant4x4 = EditorGUILayout.FloatField("Determinant (4x4)", determinant4x4);
43 |
44 | EditorGUILayout.EndVertical();
45 |
46 | EditorGUILayout.Space();
47 |
48 | EditorGUILayout.BeginVertical( GUI.skin.box );
49 |
50 | rhs = EditorGUILayout.Vector4Field( "RHS", rhs );
51 |
52 | EditorGUILayout.EndVertical();
53 |
54 | EditorGUILayout.Space();
55 |
56 | if ( GUILayout.Button("operator *" ) ) {
57 | result = matrix * rhs;
58 | }
59 |
60 | if ( GUILayout.Button("MultiplyPoint" ) ) {
61 | result = matrix.MultiplyPoint(rhs);
62 | }
63 |
64 | if ( GUILayout.Button("MultiplyPoint3x4" ) ) {
65 | result = matrix.MultiplyPoint3x4(rhs);
66 | }
67 |
68 | if ( GUILayout.Button("MultiplyVector" ) ) {
69 | result = matrix.MultiplyVector(rhs);
70 | }
71 |
72 | EditorGUILayout.BeginVertical( GUI.skin.box );
73 | EditorGUILayout.Vector4Field( "Result", result );
74 | EditorGUILayout.EndVertical();
75 |
76 | if (EditorGUI.EndChangeCheck()) {
77 | determinant3x3 = getDeterminant3x3(matrix);
78 | determinant4x4 = getDeterminant4x4(matrix);
79 |
80 | Undo.RecordObject(target, "Chapter04EditorUndo");
81 | EditorUtility.SetDirty(target);
82 | }
83 | }
84 |
85 | public float getDeterminant3x3(Matrix4x4 m) {
86 | return m.m00 * m.m11 * m.m22 - m.m00 * m.m12 * m.m21 - m.m01 * m.m10 * m.m22
87 | + m.m01 * m.m12 * m.m20 + m.m02 * m.m10 * m.m21 - m.m02 * m.m11 * m.m20
88 | ;
89 | }
90 |
91 | public float getDeterminant4x4(Matrix4x4 m) {
92 | return m.m03 * m.m12 * m.m21 * m.m30 - m.m02 * m.m13 * m.m21 * m.m30 - m.m03 * m.m11 * m.m22 * m.m30
93 | + m.m01 * m.m13 * m.m22 * m.m30 + m.m02 * m.m11 * m.m23 * m.m30 - m.m01 * m.m12 * m.m23 * m.m30
94 | - m.m03 * m.m12 * m.m20 * m.m31 + m.m02 * m.m13 * m.m20 * m.m31 + m.m03 * m.m10 * m.m22 * m.m31
95 | - m.m00 * m.m13 * m.m22 * m.m31 - m.m02 * m.m10 * m.m23 * m.m31 + m.m00 * m.m12 * m.m23 * m.m31
96 | + m.m03 * m.m11 * m.m20 * m.m32 - m.m01 * m.m13 * m.m20 * m.m32 - m.m03 * m.m10 * m.m21 * m.m32
97 | + m.m00 * m.m13 * m.m21 * m.m32 + m.m01 * m.m10 * m.m23 * m.m32 - m.m00 * m.m11 * m.m23 * m.m32
98 | - m.m02 * m.m11 * m.m20 * m.m33 + m.m01 * m.m12 * m.m20 * m.m33 + m.m02 * m.m10 * m.m21 * m.m33
99 | - m.m00 * m.m12 * m.m21 * m.m33 - m.m01 * m.m10 * m.m22 * m.m33 + m.m00 * m.m11 * m.m22 * m.m33
100 | ;
101 | }
102 |
103 | public static Vector4 RowVector4Field(Vector4 value, params GUILayoutOption[] options)
104 | {
105 | Rect position = EditorGUILayout.GetControlRect(true, 16f, EditorStyles.numberField, options);
106 | float[] values = new float[]{value.x, value.y, value.z, value.w};
107 |
108 | EditorGUI.BeginChangeCheck();
109 |
110 | EditorGUI.MultiFloatField(
111 | position,
112 | new GUIContent[]{new GUIContent(), new GUIContent(), new GUIContent(), new GUIContent()},
113 | values
114 | );
115 |
116 | if (EditorGUI.EndChangeCheck()) {
117 | value.Set(values[0], values[1], values[2], values[3]);
118 | }
119 |
120 | return value;
121 | }
122 | }
123 |
--------------------------------------------------------------------------------
/sample/Assets/Editor/Chapter04Editor.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: fad55750676053f4ba333f30d02939ea
3 | timeCreated: 1433755841
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Editor/Chapter05Editor.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using UnityEditor;
4 |
5 | [CustomEditor( typeof(Chapter05) )]
6 | public class Chapter05Editor : Editor {
7 |
8 | Matrix4x4 matrix = Matrix4x4.identity;
9 | Matrix4x4 projectionMatrix = Matrix4x4.identity;
10 |
11 | float determinant3x3;
12 | float determinant4x4;
13 |
14 | Vector4 rhs;
15 | Vector4 result;
16 |
17 | Vector3 translation;
18 | Vector3 rotation;
19 | Vector3 scale = Vector3.one;
20 |
21 | private MeshFilter mf;
22 | private Vector3[] origVerts;
23 | private Vector3[] newVerts;
24 |
25 | public override void OnInspectorGUI() {
26 | // base.OnInspectorGUI ();
27 |
28 | // Hide Script property
29 | serializedObject.Update();
30 | DrawPropertiesExcluding(serializedObject, new string[]{"m_Script"});
31 | serializedObject.ApplyModifiedProperties();
32 |
33 | Chapter05 obj = target as Chapter05;
34 |
35 | EditorGUI.BeginChangeCheck();
36 |
37 | EditorGUILayout.BeginVertical( GUI.skin.box );
38 |
39 | EditorGUILayout.LabelField(new GUIContent("Model Transform"));
40 |
41 | matrix.SetRow(0, RowVector4Field(matrix.GetRow(0)));
42 | matrix.SetRow(1, RowVector4Field(matrix.GetRow(1)));
43 | matrix.SetRow(2, RowVector4Field(matrix.GetRow(2)));
44 | matrix.SetRow(3, RowVector4Field(matrix.GetRow(3)));
45 |
46 | if ( GUILayout.Button("Reset" ) ) {
47 | matrix = Matrix4x4.identity;
48 | }
49 |
50 | if ( GUILayout.Button("Apply" ) ) {
51 | mf = obj.cube.GetComponent();
52 | origVerts = mf.mesh.vertices;
53 | newVerts = new Vector3[origVerts.Length];
54 |
55 | int i = 0;
56 | while (i < origVerts.Length) {
57 | newVerts[i] = matrix.MultiplyPoint3x4(origVerts[i]);
58 | i++;
59 | }
60 |
61 | mf.mesh.vertices = newVerts;
62 | }
63 |
64 | EditorGUILayout.EndVertical();
65 |
66 | EditorGUILayout.BeginVertical( GUI.skin.box );
67 |
68 | determinant3x3 = EditorGUILayout.FloatField("Determinant (3x3)", determinant3x3);
69 | determinant4x4 = EditorGUILayout.FloatField("Determinant (4x4)", determinant4x4);
70 |
71 | EditorGUILayout.EndVertical();
72 |
73 | EditorGUILayout.Space();
74 |
75 | EditorGUILayout.Space();
76 |
77 | EditorGUILayout.BeginVertical( GUI.skin.box );
78 |
79 | translation = EditorGUILayout.Vector3Field( "Translation", translation);
80 |
81 | if ( GUILayout.Button("Apply" ) ) {
82 | Matrix4x4 m = Matrix4x4.identity;
83 | m.SetTRS(translation, Quaternion.identity, Vector3.one);
84 | matrix = m * matrix;
85 | }
86 |
87 | EditorGUILayout.EndVertical();
88 |
89 | EditorGUILayout.BeginVertical( GUI.skin.box );
90 |
91 | rotation = EditorGUILayout.Vector3Field( "Rotation", rotation);
92 |
93 | if ( GUILayout.Button("Apply" ) ) {
94 | Matrix4x4 m = Matrix4x4.identity;
95 | m.SetTRS(Vector3.zero, Quaternion.Euler(rotation.x, rotation.y, rotation.z), Vector3.one);
96 | matrix = m * matrix;
97 | }
98 |
99 | EditorGUILayout.EndVertical();
100 |
101 | EditorGUILayout.BeginVertical( GUI.skin.box );
102 |
103 | scale = EditorGUILayout.Vector3Field( "Scale", scale);
104 |
105 | if ( GUILayout.Button("Apply" ) ) {
106 | Matrix4x4 m = Matrix4x4.identity;
107 | m.SetTRS(Vector3.zero, Quaternion.identity, scale);
108 | matrix = m * matrix;
109 | }
110 |
111 | EditorGUILayout.EndVertical();
112 |
113 | EditorGUILayout.BeginVertical( GUI.skin.box );
114 |
115 | EditorGUILayout.LabelField(new GUIContent("Projection Transform"));
116 |
117 | if ( GUILayout.Button("Perspective" ) ) {
118 | Camera.main.orthographic = false;
119 | }
120 |
121 | if ( GUILayout.Button("Orthographic" ) ) {
122 | Camera.main.orthographic = true;
123 | }
124 |
125 | projectionMatrix.SetRow(0, RowVector4Field(projectionMatrix.GetRow(0)));
126 | projectionMatrix.SetRow(1, RowVector4Field(projectionMatrix.GetRow(1)));
127 | projectionMatrix.SetRow(2, RowVector4Field(projectionMatrix.GetRow(2)));
128 | projectionMatrix.SetRow(3, RowVector4Field(projectionMatrix.GetRow(3)));
129 |
130 | if ( GUILayout.Button("Camera.main.projectionMatrix" ) ) {
131 | string graphicsDeviceType = SystemInfo.graphicsDeviceType.ToString();
132 | Debug.Log(graphicsDeviceType);
133 |
134 | bool dx = graphicsDeviceType.IndexOf("Direct3D") == 0;
135 |
136 | int dxVersion = 11;
137 | if (dx) {
138 | System.Int32.TryParse(graphicsDeviceType.Substring("Direct3D".Length), out dxVersion);
139 | Debug.Log("Direct3D version: " + dxVersion);
140 | }
141 |
142 | Matrix4x4 pm = Camera.main.projectionMatrix;
143 |
144 | if (dx) {
145 | if (dxVersion < 11) {
146 | for (int i = 0; i < 4; i++) {
147 | pm [1, i] = -pm [1, i];
148 | }
149 |
150 | for (int i = 0; i < 4; i++) {
151 | pm [2, i] = pm [2, i] * 0.5f + pm [3, i] * 0.5f;
152 | }
153 | } else {
154 | for (int i = 0; i < 4; i++) {
155 | pm[1, i] = -pm[1, i];
156 | }
157 |
158 | for (int i = 0; i < 4; i++) {
159 | pm[2, i] = pm[2, i] * -0.5f + pm[3, i] * 0.5f;
160 | }
161 | }
162 | }
163 |
164 | projectionMatrix = pm;
165 |
166 | Matrix4x4 gpuProjectionMatrix = GL.GetGPUProjectionMatrix(Camera.main.projectionMatrix, true);
167 | if (pm == gpuProjectionMatrix) {
168 | Debug.Log("Camera.main.projectionMatrix matches with GL.GetGPUProjectionMatrix");
169 | } else {
170 | Debug.LogWarning("Camera.main.projectionMatrix doesn't match with GL.GetGPUProjectionMatrix");
171 | }
172 | }
173 |
174 | if ( GUILayout.Button("GL.GetGPUProjectionMatrix" ) ) {
175 | projectionMatrix = GL.GetGPUProjectionMatrix(Camera.main.projectionMatrix, true);
176 | }
177 |
178 | if ( GUILayout.Button("Reset" ) ) {
179 | projectionMatrix = Matrix4x4.identity;
180 | Camera.main.ResetProjectionMatrix();
181 | }
182 |
183 | if ( GUILayout.Button("Set" ) ) {
184 | Camera.main.projectionMatrix = projectionMatrix;
185 | }
186 |
187 | EditorGUILayout.EndVertical();
188 |
189 | if (EditorGUI.EndChangeCheck()) {
190 | determinant3x3 = getDeterminant3x3(matrix);
191 | determinant4x4 = getDeterminant4x4(matrix);
192 |
193 | Undo.RecordObject(target, "Chapter05EditorUndo");
194 | EditorUtility.SetDirty(target);
195 | }
196 | }
197 |
198 | public float getDeterminant3x3(Matrix4x4 m) {
199 | return m.m00 * m.m11 * m.m22 - m.m00 * m.m12 * m.m21 - m.m01 * m.m10 * m.m22
200 | + m.m01 * m.m12 * m.m20 + m.m02 * m.m10 * m.m21 - m.m02 * m.m11 * m.m20
201 | ;
202 | }
203 |
204 | public float getDeterminant4x4(Matrix4x4 m) {
205 | return m.m03 * m.m12 * m.m21 * m.m30 - m.m02 * m.m13 * m.m21 * m.m30 - m.m03 * m.m11 * m.m22 * m.m30
206 | + m.m01 * m.m13 * m.m22 * m.m30 + m.m02 * m.m11 * m.m23 * m.m30 - m.m01 * m.m12 * m.m23 * m.m30
207 | - m.m03 * m.m12 * m.m20 * m.m31 + m.m02 * m.m13 * m.m20 * m.m31 + m.m03 * m.m10 * m.m22 * m.m31
208 | - m.m00 * m.m13 * m.m22 * m.m31 - m.m02 * m.m10 * m.m23 * m.m31 + m.m00 * m.m12 * m.m23 * m.m31
209 | + m.m03 * m.m11 * m.m20 * m.m32 - m.m01 * m.m13 * m.m20 * m.m32 - m.m03 * m.m10 * m.m21 * m.m32
210 | + m.m00 * m.m13 * m.m21 * m.m32 + m.m01 * m.m10 * m.m23 * m.m32 - m.m00 * m.m11 * m.m23 * m.m32
211 | - m.m02 * m.m11 * m.m20 * m.m33 + m.m01 * m.m12 * m.m20 * m.m33 + m.m02 * m.m10 * m.m21 * m.m33
212 | - m.m00 * m.m12 * m.m21 * m.m33 - m.m01 * m.m10 * m.m22 * m.m33 + m.m00 * m.m11 * m.m22 * m.m33
213 | ;
214 | }
215 |
216 | public static Vector4 RowVector4Field(Vector4 value, params GUILayoutOption[] options)
217 | {
218 | Rect position = EditorGUILayout.GetControlRect(true, 16f, EditorStyles.numberField, options);
219 | float[] values = new float[]{value.x, value.y, value.z, value.w};
220 |
221 | EditorGUI.BeginChangeCheck();
222 |
223 | EditorGUI.MultiFloatField(
224 | position,
225 | new GUIContent[]{new GUIContent(), new GUIContent(), new GUIContent(), new GUIContent()},
226 | values
227 | );
228 |
229 | if (EditorGUI.EndChangeCheck()) {
230 | value.Set(values[0], values[1], values[2], values[3]);
231 | }
232 |
233 | return value;
234 | }
235 | }
236 |
--------------------------------------------------------------------------------
/sample/Assets/Editor/Chapter05Editor.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: cad7102c3cae1cb42bbf1e18b682d749
3 | timeCreated: 1435126056
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 0f4c51e93ffa94a3d99c9b1159fe3552
3 | folderAsset: yes
4 | timeCreated: 1442407153
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 3acdf4ce9ea8b49edacc95750fb8de09
3 | folderAsset: yes
4 | timeCreated: 1442407172
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/BaseMat.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: BaseMat
10 | m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: .800000012, g: .800000012, b: .800000012, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/BaseMat.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: f6a3466108ad649c9a0f169bb0894e11
3 | timeCreated: 1442407172
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/Clear Coat Plastic.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: Clear Coat Plastic
10 | m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: .727574944, g: .727574944, b: .727574944, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/Clear Coat Plastic.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: a86e880c31ff346839e2eba81c160702
3 | timeCreated: 1442409640
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/No Name.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: No Name
10 | m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: 1, g: 1, b: 1, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/No Name.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 5aa57f8d3163445ab908a1c1e0f7d945
3 | timeCreated: 1442410162
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/TopMat.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: TopMat
10 | m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: .800000012, g: .800000012, b: .800000012, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/TopMat.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: bbb995342a98f4572a3d86244fb08e2f
3 | timeCreated: 1442407172
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/buddhaMat.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: buddhaMat
10 | m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: .800000012, g: .800000012, b: .800000012, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/buddhaMat.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 5dc2942fd46d34704951a397238dbb71
3 | timeCreated: 1442408563
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/defaultMat.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: defaultMat
10 | m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: .800000012, g: .800000012, b: .800000012, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/Materials/defaultMat.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 316fd6bbdf9ee4944af4c33755a12fcd
3 | timeCreated: 1442408104
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/StanfordHappyBuddha.obj.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 4a3ca6c87ffa8405da55c4c1549666ab
3 | timeCreated: 1442499222
4 | licenseType: Free
5 | ModelImporter:
6 | serializedVersion: 18
7 | fileIDToRecycleName:
8 | 100000: default
9 | 100002: //RootNode
10 | 400000: default
11 | 400002: //RootNode
12 | 2300000: default
13 | 3300000: default
14 | 4300000: default
15 | materials:
16 | importMaterials: 1
17 | materialName: 0
18 | materialSearch: 1
19 | animations:
20 | legacyGenerateAnimations: 4
21 | bakeSimulation: 0
22 | optimizeGameObjects: 0
23 | motionNodeName:
24 | animationImportErrors:
25 | animationImportWarnings:
26 | animationRetargetingWarnings:
27 | animationDoRetargetingWarnings: 0
28 | animationCompression: 1
29 | animationRotationError: .5
30 | animationPositionError: .5
31 | animationScaleError: .5
32 | animationWrapMode: 0
33 | extraExposedTransformPaths: []
34 | clipAnimations: []
35 | isReadable: 1
36 | meshes:
37 | lODScreenPercentages: []
38 | globalScale: .800000012
39 | meshCompression: 0
40 | addColliders: 0
41 | importBlendShapes: 1
42 | swapUVChannels: 0
43 | generateSecondaryUV: 0
44 | useFileUnits: 1
45 | optimizeMeshForGPU: 1
46 | keepQuads: 0
47 | weldVertices: 1
48 | secondaryUVAngleDistortion: 8
49 | secondaryUVAreaDistortion: 15.000001
50 | secondaryUVHardAngle: 88
51 | secondaryUVPackMargin: 4
52 | useFileScale: 1
53 | tangentSpace:
54 | normalSmoothAngle: 60
55 | splitTangentsAcrossUV: 1
56 | normalImportMode: 0
57 | tangentImportMode: 1
58 | importAnimation: 1
59 | copyAvatar: 0
60 | humanDescription:
61 | human: []
62 | skeleton: []
63 | armTwist: .5
64 | foreArmTwist: .5
65 | upperLegTwist: .5
66 | legTwist: .5
67 | armStretch: .0500000007
68 | legStretch: .0500000007
69 | feetSpacing: 0
70 | rootMotionBoneName:
71 | hasTranslationDoF: 0
72 | lastHumanDescriptionAvatarSource: {instanceID: 0}
73 | animationType: 0
74 | humanoidOversampling: 1
75 | additionalBone: 0
76 | userData:
77 | assetBundleName:
78 | assetBundleVariant:
79 |
--------------------------------------------------------------------------------
/sample/Assets/Meshes/UtahTeapot.obj.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: c9eeb775d7c4045c999e9c94c710f4dc
3 | timeCreated: 1442502251
4 | licenseType: Free
5 | ModelImporter:
6 | serializedVersion: 18
7 | fileIDToRecycleName:
8 | 100000: default
9 | 100002: //RootNode
10 | 400000: default
11 | 400002: //RootNode
12 | 2300000: default
13 | 3300000: default
14 | 4300000: default
15 | materials:
16 | importMaterials: 1
17 | materialName: 0
18 | materialSearch: 1
19 | animations:
20 | legacyGenerateAnimations: 4
21 | bakeSimulation: 0
22 | optimizeGameObjects: 0
23 | motionNodeName:
24 | animationImportErrors:
25 | animationImportWarnings:
26 | animationRetargetingWarnings:
27 | animationDoRetargetingWarnings: 0
28 | animationCompression: 1
29 | animationRotationError: .5
30 | animationPositionError: .5
31 | animationScaleError: .5
32 | animationWrapMode: 0
33 | extraExposedTransformPaths: []
34 | clipAnimations: []
35 | isReadable: 1
36 | meshes:
37 | lODScreenPercentages: []
38 | globalScale: .100000001
39 | meshCompression: 0
40 | addColliders: 0
41 | importBlendShapes: 1
42 | swapUVChannels: 0
43 | generateSecondaryUV: 0
44 | useFileUnits: 1
45 | optimizeMeshForGPU: 1
46 | keepQuads: 0
47 | weldVertices: 1
48 | secondaryUVAngleDistortion: 8
49 | secondaryUVAreaDistortion: 15.000001
50 | secondaryUVHardAngle: 88
51 | secondaryUVPackMargin: 4
52 | useFileScale: 1
53 | tangentSpace:
54 | normalSmoothAngle: 60
55 | splitTangentsAcrossUV: 1
56 | normalImportMode: 0
57 | tangentImportMode: 1
58 | importAnimation: 1
59 | copyAvatar: 0
60 | humanDescription:
61 | human: []
62 | skeleton: []
63 | armTwist: .5
64 | foreArmTwist: .5
65 | upperLegTwist: .5
66 | legTwist: .5
67 | armStretch: .0500000007
68 | legStretch: .0500000007
69 | feetSpacing: 0
70 | rootMotionBoneName:
71 | hasTranslationDoF: 0
72 | lastHumanDescriptionAvatarSource: {instanceID: 0}
73 | animationType: 0
74 | humanoidOversampling: 1
75 | additionalBone: 0
76 | userData:
77 | assetBundleName:
78 | assetBundleVariant:
79 |
--------------------------------------------------------------------------------
/sample/Assets/Prefabs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: d591a96f19fb369438f79a7a73e6af3c
3 | folderAsset: yes
4 | timeCreated: 1435680239
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Resources.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 5f35e4b8533aae144a9534587a64589e
3 | folderAsset: yes
4 | timeCreated: 1436805982
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 1e727bf800f5a074b81aa1c06faa9d5d
3 | folderAsset: yes
4 | timeCreated: 1436805982
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/CookTorrance.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: CookTorrance
10 | m_Shader: {fileID: 4800000, guid: 5dc534f9006a65b40bc3bd71ac004e5f, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | data:
131 | first:
132 | name: _SpecularExponent
133 | second: 3
134 | data:
135 | first:
136 | name: _Roughness
137 | second: .5
138 | data:
139 | first:
140 | name: _FresnelReflectance
141 | second: .5
142 | m_Colors:
143 | data:
144 | first:
145 | name: _EmissionColor
146 | second: {r: 0, g: 0, b: 0, a: 1}
147 | data:
148 | first:
149 | name: _Color
150 | second: {r: 1, g: 1, b: 1, a: 1}
151 | data:
152 | first:
153 | name: _SpecularColor
154 | second: {r: 1, g: 1, b: 1, a: 1}
155 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/CookTorrance.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 100269d440fc4cd4e88a7cfeb4838e48
3 | timeCreated: 1438258797
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/DiffuseMaterial.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: DiffuseMaterial
10 | m_Shader: {fileID: 4800000, guid: 090d660bb8ad39b48a24e7fa19990f6c, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: 1, g: 1, b: 1, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/DiffuseMaterial.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: d4ec70e39f65e6841bd1e0f8341d30a7
3 | timeCreated: 1438031879
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/Gouraud.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: Gouraud
10 | m_Shader: {fileID: 4800000, guid: 7ee4731ba0154724f9025e0883b0597a, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: 2000
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | data:
131 | first:
132 | name: _SpecularExponent
133 | second: 3
134 | m_Colors:
135 | data:
136 | first:
137 | name: _EmissionColor
138 | second: {r: 0, g: 0, b: 0, a: 1}
139 | data:
140 | first:
141 | name: _Color
142 | second: {r: 1, g: 1, b: 1, a: 1}
143 | data:
144 | first:
145 | name: _SpecularColor
146 | second: {r: 1, g: 1, b: 1, a: 1}
147 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/Gouraud.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: d7eee7ddf0fbb7c46bd883387bd1744a
3 | timeCreated: 1438089307
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/HalfLambertMaterial.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: HalfLambertMaterial
10 | m_Shader: {fileID: 4800000, guid: 761c206b5d6c2439da90ead865ccc711, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: 1, g: 1, b: 1, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/HalfLambertMaterial.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: c5117eca7d1ec411681c1ae318fb484a
3 | timeCreated: 1438073738
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/NormalMap.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: NormalMap
10 | m_Shader: {fileID: 4800000, guid: 8e3276c2ba3616b44b058875921d68c4, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 2800000, guid: c68b34fac93424d41803bd0c03b3802b, type: 3}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _NormalMap
35 | second:
36 | m_Texture: {fileID: 2800000, guid: c68b34fac93424d41803bd0c03b3802b, type: 3}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _DetailNormalMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _Texture
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _ParallaxMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _OcclusionMap
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _EmissionMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _DetailMask
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | data:
82 | first:
83 | name: _DetailAlbedoMap
84 | second:
85 | m_Texture: {fileID: 0}
86 | m_Scale: {x: 1, y: 1}
87 | m_Offset: {x: 0, y: 0}
88 | data:
89 | first:
90 | name: _MetallicGlossMap
91 | second:
92 | m_Texture: {fileID: 0}
93 | m_Scale: {x: 1, y: 1}
94 | m_Offset: {x: 0, y: 0}
95 | m_Floats:
96 | data:
97 | first:
98 | name: _SrcBlend
99 | second: 1
100 | data:
101 | first:
102 | name: _DstBlend
103 | second: 0
104 | data:
105 | first:
106 | name: _Cutoff
107 | second: .5
108 | data:
109 | first:
110 | name: _SpecularExponent
111 | second: 10
112 | data:
113 | first:
114 | name: _Parallax
115 | second: .0199999996
116 | data:
117 | first:
118 | name: _ZWrite
119 | second: 1
120 | data:
121 | first:
122 | name: _Glossiness
123 | second: .5
124 | data:
125 | first:
126 | name: _BumpScale
127 | second: 1
128 | data:
129 | first:
130 | name: _OcclusionStrength
131 | second: 1
132 | data:
133 | first:
134 | name: _DetailNormalMapScale
135 | second: 1
136 | data:
137 | first:
138 | name: _UVSec
139 | second: 0
140 | data:
141 | first:
142 | name: _Mode
143 | second: 0
144 | data:
145 | first:
146 | name: _Metallic
147 | second: 0
148 | m_Colors:
149 | data:
150 | first:
151 | name: _EmissionColor
152 | second: {r: 0, g: 0, b: 0, a: 1}
153 | data:
154 | first:
155 | name: _Color
156 | second: {r: 1, g: 1, b: 1, a: 1}
157 | data:
158 | first:
159 | name: _SpecularColor
160 | second: {r: 1, g: 1, b: 1, a: 1}
161 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/NormalMap.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 900675b4ff12f1344adfcab0e3d7d113
3 | timeCreated: 1438108413
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/Phong.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: Phong
10 | m_Shader: {fileID: 4800000, guid: 6c9747299252e3c48a9008b240155024, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: 2000
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | data:
131 | first:
132 | name: _SpecularExponent
133 | second: 3
134 | m_Colors:
135 | data:
136 | first:
137 | name: _EmissionColor
138 | second: {r: 0, g: 0, b: 0, a: 1}
139 | data:
140 | first:
141 | name: _Color
142 | second: {r: 1, g: 1, b: 1, a: 1}
143 | data:
144 | first:
145 | name: _SpecularColor
146 | second: {r: 1, g: 1, b: 1, a: 1}
147 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/Phong.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: a3fdb0cbf07c5c546864c3f32b2322e3
3 | timeCreated: 1438095106
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/Rim.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: Rim
10 | m_Shader: {fileID: 4800000, guid: 841d3a48e5f682e4a9349b185142dea2, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | data:
131 | first:
132 | name: _SpecularExponent
133 | second: 3
134 | m_Colors:
135 | data:
136 | first:
137 | name: _EmissionColor
138 | second: {r: 0, g: 0, b: 0, a: 1}
139 | data:
140 | first:
141 | name: _Color
142 | second: {r: 1, g: 1, b: 1, a: 1}
143 | data:
144 | first:
145 | name: _SpecularColor
146 | second: {r: 1, g: 1, b: 1, a: 1}
147 | data:
148 | first:
149 | name: _RimColor
150 | second: {r: 0, g: 1, b: 0, a: 1}
151 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/Rim.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 6d50e8a41dde1fa4f9535587f54238c5
3 | timeCreated: 1438102114
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/TestMaterial.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: TestMaterial
10 | m_Shader: {fileID: 4800000, guid: 14104973823c4e942bb09a50556ffa4d, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: 2000
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | m_Floats:
82 | data:
83 | first:
84 | name: _SrcBlend
85 | second: 1
86 | data:
87 | first:
88 | name: _DstBlend
89 | second: 0
90 | data:
91 | first:
92 | name: _Cutoff
93 | second: .5
94 | data:
95 | first:
96 | name: _Parallax
97 | second: .0199999996
98 | data:
99 | first:
100 | name: _ZWrite
101 | second: 1
102 | data:
103 | first:
104 | name: _Glossiness
105 | second: .5
106 | data:
107 | first:
108 | name: _BumpScale
109 | second: 1
110 | data:
111 | first:
112 | name: _OcclusionStrength
113 | second: 1
114 | data:
115 | first:
116 | name: _DetailNormalMapScale
117 | second: 1
118 | data:
119 | first:
120 | name: _UVSec
121 | second: 0
122 | data:
123 | first:
124 | name: _Mode
125 | second: 0
126 | data:
127 | first:
128 | name: _Metallic
129 | second: 0
130 | m_Colors:
131 | data:
132 | first:
133 | name: _EmissionColor
134 | second: {r: 0, g: 0, b: 0, a: 1}
135 | data:
136 | first:
137 | name: _Color
138 | second: {r: 1, g: 1, b: 1, a: 1}
139 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/TestMaterial.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 0fe52a14ec05afb44852e197f85a5104
3 | timeCreated: 1436806011
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/TextureMap.mat:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!21 &2100000
4 | Material:
5 | serializedVersion: 6
6 | m_ObjectHideFlags: 0
7 | m_PrefabParentObject: {fileID: 0}
8 | m_PrefabInternal: {fileID: 0}
9 | m_Name: TextureMap
10 | m_Shader: {fileID: 4800000, guid: d0aa727737c7f8245a835d0681677f9c, type: 3}
11 | m_ShaderKeywords:
12 | m_LightmapFlags: 5
13 | m_CustomRenderQueue: -1
14 | stringTagMap: {}
15 | m_SavedProperties:
16 | serializedVersion: 2
17 | m_TexEnvs:
18 | data:
19 | first:
20 | name: _MainTex
21 | second:
22 | m_Texture: {fileID: 0}
23 | m_Scale: {x: 1, y: 1}
24 | m_Offset: {x: 0, y: 0}
25 | data:
26 | first:
27 | name: _BumpMap
28 | second:
29 | m_Texture: {fileID: 0}
30 | m_Scale: {x: 1, y: 1}
31 | m_Offset: {x: 0, y: 0}
32 | data:
33 | first:
34 | name: _DetailNormalMap
35 | second:
36 | m_Texture: {fileID: 0}
37 | m_Scale: {x: 1, y: 1}
38 | m_Offset: {x: 0, y: 0}
39 | data:
40 | first:
41 | name: _ParallaxMap
42 | second:
43 | m_Texture: {fileID: 0}
44 | m_Scale: {x: 1, y: 1}
45 | m_Offset: {x: 0, y: 0}
46 | data:
47 | first:
48 | name: _OcclusionMap
49 | second:
50 | m_Texture: {fileID: 0}
51 | m_Scale: {x: 1, y: 1}
52 | m_Offset: {x: 0, y: 0}
53 | data:
54 | first:
55 | name: _EmissionMap
56 | second:
57 | m_Texture: {fileID: 0}
58 | m_Scale: {x: 1, y: 1}
59 | m_Offset: {x: 0, y: 0}
60 | data:
61 | first:
62 | name: _DetailMask
63 | second:
64 | m_Texture: {fileID: 0}
65 | m_Scale: {x: 1, y: 1}
66 | m_Offset: {x: 0, y: 0}
67 | data:
68 | first:
69 | name: _DetailAlbedoMap
70 | second:
71 | m_Texture: {fileID: 0}
72 | m_Scale: {x: 1, y: 1}
73 | m_Offset: {x: 0, y: 0}
74 | data:
75 | first:
76 | name: _MetallicGlossMap
77 | second:
78 | m_Texture: {fileID: 0}
79 | m_Scale: {x: 1, y: 1}
80 | m_Offset: {x: 0, y: 0}
81 | data:
82 | first:
83 | name: _Texture
84 | second:
85 | m_Texture: {fileID: 2800000, guid: 09c4d94a908903a438e003134d673324, type: 3}
86 | m_Scale: {x: 1, y: 1}
87 | m_Offset: {x: 0, y: 0}
88 | m_Floats:
89 | data:
90 | first:
91 | name: _SrcBlend
92 | second: 1
93 | data:
94 | first:
95 | name: _DstBlend
96 | second: 0
97 | data:
98 | first:
99 | name: _Cutoff
100 | second: .5
101 | data:
102 | first:
103 | name: _Parallax
104 | second: .0199999996
105 | data:
106 | first:
107 | name: _ZWrite
108 | second: 1
109 | data:
110 | first:
111 | name: _Glossiness
112 | second: .5
113 | data:
114 | first:
115 | name: _BumpScale
116 | second: 1
117 | data:
118 | first:
119 | name: _OcclusionStrength
120 | second: 1
121 | data:
122 | first:
123 | name: _DetailNormalMapScale
124 | second: 1
125 | data:
126 | first:
127 | name: _UVSec
128 | second: 0
129 | data:
130 | first:
131 | name: _Mode
132 | second: 0
133 | data:
134 | first:
135 | name: _Metallic
136 | second: 0
137 | data:
138 | first:
139 | name: _SpecularExponent
140 | second: 10
141 | m_Colors:
142 | data:
143 | first:
144 | name: _EmissionColor
145 | second: {r: 0, g: 0, b: 0, a: 1}
146 | data:
147 | first:
148 | name: _Color
149 | second: {r: 1, g: 1, b: 1, a: 1}
150 | data:
151 | first:
152 | name: _SpecularColor
153 | second: {r: 1, g: 1, b: 1, a: 1}
154 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/TextureMap.mat.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 56014f05ed9dc284182e3c36ecde713c
3 | timeCreated: 1438106067
4 | licenseType: Free
5 | NativeFormatImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/image_normal.JPG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Assets/Resources/Materials/image_normal.JPG
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/image_normal.JPG.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: c68b34fac93424d41803bd0c03b3802b
3 | timeCreated: 1438109821
4 | licenseType: Free
5 | TextureImporter:
6 | fileIDToRecycleName: {}
7 | serializedVersion: 2
8 | mipmaps:
9 | mipMapMode: 0
10 | enableMipMap: 1
11 | linearTexture: 1
12 | correctGamma: 0
13 | fadeOut: 0
14 | borderMipMap: 0
15 | mipMapFadeDistanceStart: 1
16 | mipMapFadeDistanceEnd: 3
17 | bumpmap:
18 | convertToNormalMap: 0
19 | externalNormalMap: 1
20 | heightScale: .25
21 | normalMapFilter: 0
22 | isReadable: 0
23 | grayScaleToAlpha: 0
24 | generateCubemap: 0
25 | cubemapConvolution: 0
26 | cubemapConvolutionSteps: 8
27 | cubemapConvolutionExponent: 1.5
28 | seamlessCubemap: 0
29 | textureFormat: -1
30 | maxTextureSize: 2048
31 | textureSettings:
32 | filterMode: -1
33 | aniso: -1
34 | mipBias: -1
35 | wrapMode: -1
36 | nPOTScale: 1
37 | lightmap: 0
38 | rGBM: 0
39 | compressionQuality: 50
40 | spriteMode: 0
41 | spriteExtrude: 1
42 | spriteMeshType: 1
43 | alignment: 0
44 | spritePivot: {x: .5, y: .5}
45 | spriteBorder: {x: 0, y: 0, z: 0, w: 0}
46 | spritePixelsToUnits: 100
47 | alphaIsTransparency: 0
48 | textureType: 1
49 | buildTargetSettings: []
50 | spriteSheet:
51 | sprites: []
52 | spritePackingTag:
53 | userData:
54 | assetBundleName:
55 | assetBundleVariant:
56 |
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/image_texture.JPG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Assets/Resources/Materials/image_texture.JPG
--------------------------------------------------------------------------------
/sample/Assets/Resources/Materials/image_texture.JPG.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 09c4d94a908903a438e003134d673324
3 | timeCreated: 1438107725
4 | licenseType: Free
5 | TextureImporter:
6 | fileIDToRecycleName: {}
7 | serializedVersion: 2
8 | mipmaps:
9 | mipMapMode: 0
10 | enableMipMap: 1
11 | linearTexture: 0
12 | correctGamma: 0
13 | fadeOut: 0
14 | borderMipMap: 0
15 | mipMapFadeDistanceStart: 1
16 | mipMapFadeDistanceEnd: 3
17 | bumpmap:
18 | convertToNormalMap: 0
19 | externalNormalMap: 0
20 | heightScale: .25
21 | normalMapFilter: 0
22 | isReadable: 0
23 | grayScaleToAlpha: 0
24 | generateCubemap: 0
25 | cubemapConvolution: 0
26 | cubemapConvolutionSteps: 8
27 | cubemapConvolutionExponent: 1.5
28 | seamlessCubemap: 0
29 | textureFormat: -1
30 | maxTextureSize: 2048
31 | textureSettings:
32 | filterMode: -1
33 | aniso: -1
34 | mipBias: -1
35 | wrapMode: -1
36 | nPOTScale: 1
37 | lightmap: 0
38 | rGBM: 0
39 | compressionQuality: 50
40 | spriteMode: 0
41 | spriteExtrude: 1
42 | spriteMeshType: 1
43 | alignment: 0
44 | spritePivot: {x: .5, y: .5}
45 | spriteBorder: {x: 0, y: 0, z: 0, w: 0}
46 | spritePixelsToUnits: 100
47 | alphaIsTransparency: 0
48 | textureType: -1
49 | buildTargetSettings: []
50 | spriteSheet:
51 | sprites: []
52 | spritePackingTag:
53 | userData:
54 | assetBundleName:
55 | assetBundleVariant:
56 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 2e1c0fdb26a493644b255927a8c009c1
3 | folderAsset: yes
4 | timeCreated: 1430737728
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Chapter01.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 299fa2b04374f02419d18a851cec755f
3 | timeCreated: 1430899405
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Chapter02.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: c086f7199682d9843ab4711af1091706
3 | timeCreated: 1431745593
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Chapter03.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: ce5a16b158295504887656e4d08eb7c3
3 | timeCreated: 1432848390
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Chapter04.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: c41b05a9e4340bb41a783915d3d22a28
3 | timeCreated: 1433747980
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Chapter05.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: e9d48f997f71e89478c2b58712d2473c
3 | timeCreated: 1435126053
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Chapter06.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: e87d0acca1a07124fbe561f0e008381c
3 | timeCreated: 1435627204
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Chapter07.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 012e624af6e34224f95e7a936e21cec9
3 | timeCreated: 1435743236
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Chapter09.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: b77890214d1593049abb95e2439e782f
3 | timeCreated: 1436713489
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scenes/Main.unity.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: ecbfa275baa625246b3a07c6a84e21a7
3 | timeCreated: 1430738762
4 | licenseType: Free
5 | DefaultImporter:
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 7d087c6610aeef34f8103da78770c792
3 | folderAsset: yes
4 | timeCreated: 1430737728
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter01.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using UnityEngine.UI;
4 | using UnityEngine.EventSystems;
5 |
6 | public class Chapter01 : MonoBehaviour {
7 |
8 | private GameObject capsule;
9 |
10 | private float targetAngle = 0f;
11 | public float capsuleRotationSpeed = 4f;
12 |
13 | private GameObject sphere;
14 | private float buttonDownTime;
15 |
16 | public float sphereMagnitudeX = 2.0f;
17 | public float sphereMagnitudeY = 3.0f;
18 | public float sphereFrequency = 1.0f;
19 |
20 | // Use this for initialization
21 | void Start () {
22 | capsule = GameObject.Find("Capsule");
23 | }
24 |
25 | // Update is called once per frame
26 | void Update () {
27 | if (Input.GetMouseButtonDown(0) && !EventSystem.current.IsPointerOverGameObject()) {
28 | Debug.Log (string.Format("mousePosition ({0:f}, {1:f})", Input.mousePosition.x, Input.mousePosition.y));
29 |
30 | targetAngle = GetRotationAngleByTargetPosition(Input.mousePosition);
31 |
32 | if (sphere != null) {
33 | Destroy(sphere);
34 | sphere = null;
35 | }
36 |
37 | sphere = SpawnSphereAt(Input.mousePosition);
38 | buttonDownTime = Time.time;
39 | }
40 |
41 | capsule.transform.eulerAngles
42 | = new Vector3(0, 0, Mathf.LerpAngle(capsule.transform.eulerAngles.z, targetAngle, Time.deltaTime * capsuleRotationSpeed));
43 |
44 | if (sphere != null) {
45 | sphere.transform.position = new Vector3(sphere.transform.position.x + (capsule.transform.position.x - sphere.transform.position.x) * Time.deltaTime * sphereMagnitudeX,
46 | Mathf.Abs(Mathf.Sin ((Time.time - buttonDownTime) * (Mathf.PI * 2) * sphereFrequency) * sphereMagnitudeY),
47 | 0
48 | );
49 | }
50 | }
51 |
52 | float GetRotationAngleByTargetPosition(Vector3 mousePosition) {
53 | Vector3 selfScreenPoint = Camera.main.WorldToScreenPoint(capsule.transform.position);
54 | Vector3 diff = mousePosition - selfScreenPoint;
55 |
56 | float angle = Mathf.Atan2(diff.y, diff.x) * Mathf.Rad2Deg;
57 |
58 | Debug.Log (string.Format("angle: {0:f}", angle));
59 |
60 | float finalAngle = angle - 90f;
61 |
62 | Debug.Log (string.Format("finalAngle: {0:f}", finalAngle));
63 |
64 | return finalAngle;
65 | }
66 |
67 | GameObject SpawnSphereAt(Vector3 mousePosition) {
68 | GameObject sp = GameObject.CreatePrimitive(PrimitiveType.Sphere);
69 | Vector3 selfScreenPoint = Camera.main.WorldToScreenPoint(capsule.transform.position);
70 | Vector3 position = Camera.main.ScreenToWorldPoint(new Vector3(mousePosition.x, mousePosition.y, selfScreenPoint.z));
71 | sp.transform.position = new Vector3(position.x, position.y, 0);
72 | return sp;
73 | }
74 | }
75 |
76 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter01.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 8820ead8f4572744190f1cf91bceab80
3 | timeCreated: 1430993489
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter02.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using UnityEngine.UI;
4 | using UnityEngine.EventSystems;
5 |
6 | // Based on the code at http://wiki.unity3d.com/index.php/SphericalCoordinates with minor refactoring changes.
7 | // This code is under Creative Commons Attribution Share Alike http://creativecommons.org/licenses/by-sa/3.0/
8 |
9 | public class Chapter02 : MonoBehaviour {
10 |
11 | public float rotateSpeed = 1f;
12 | public float scrollSpeed = 200f;
13 |
14 | public Transform pivot;
15 |
16 | [System.Serializable]
17 | public class SphericalCoordinates
18 | {
19 | public float _radius, _azimuth, _elevation;
20 |
21 | public float radius
22 | {
23 | get { return _radius; }
24 | private set
25 | {
26 | _radius = Mathf.Clamp( value, _minRadius, _maxRadius );
27 | }
28 | }
29 |
30 | public float azimuth
31 | {
32 | get { return _azimuth; }
33 | private set
34 | {
35 | _azimuth = Mathf.Repeat( value, _maxAzimuth - _minAzimuth );
36 | }
37 | }
38 |
39 | public float elevation
40 | {
41 | get{ return _elevation; }
42 | private set
43 | {
44 | _elevation = Mathf.Clamp( value, _minElevation, _maxElevation );
45 | }
46 | }
47 |
48 | public float _minRadius = 3f;
49 | public float _maxRadius = 20f;
50 |
51 | public float minAzimuth = 0f;
52 | private float _minAzimuth;
53 |
54 | public float maxAzimuth = 360f;
55 | private float _maxAzimuth;
56 |
57 | public float minElevation = 0f;
58 | private float _minElevation;
59 |
60 | public float maxElevation = 90f;
61 | private float _maxElevation;
62 |
63 | public SphericalCoordinates(){}
64 |
65 | public SphericalCoordinates(Vector3 cartesianCoordinate)
66 | {
67 | _minAzimuth = Mathf.Deg2Rad * minAzimuth;
68 | _maxAzimuth = Mathf.Deg2Rad * maxAzimuth;
69 |
70 | _minElevation = Mathf.Deg2Rad * minElevation;
71 | _maxElevation = Mathf.Deg2Rad * maxElevation;
72 |
73 | radius = cartesianCoordinate.magnitude;
74 | azimuth = Mathf.Atan2(cartesianCoordinate.z, cartesianCoordinate.x);
75 | elevation = Mathf.Asin(cartesianCoordinate.y / radius);
76 | }
77 |
78 | public Vector3 toCartesian
79 | {
80 | get
81 | {
82 | float t = radius * Mathf.Cos(elevation);
83 | return new Vector3(t * Mathf.Cos(azimuth), radius * Mathf.Sin(elevation), t * Mathf.Sin(azimuth));
84 | }
85 | }
86 |
87 | public SphericalCoordinates Rotate(float newAzimuth, float newElevation){
88 | azimuth += newAzimuth;
89 | elevation += newElevation;
90 | return this;
91 | }
92 |
93 | public SphericalCoordinates TranslateRadius(float x) {
94 | radius += x;
95 | return this;
96 | }
97 | }
98 |
99 | public SphericalCoordinates sphericalCoordinates;
100 |
101 | // Use this for initialization
102 | void Start () {
103 | sphericalCoordinates = new SphericalCoordinates(transform.position);
104 | transform.position = sphericalCoordinates.toCartesian + pivot.position;
105 | }
106 |
107 | // Update is called once per frame
108 | void Update () {
109 | float kh, kv, mh, mv, h, v;
110 | kh = Input.GetAxis( "Horizontal" );
111 | kv = Input.GetAxis( "Vertical" );
112 |
113 | bool anyMouseButton = Input.GetMouseButton(0) | Input.GetMouseButton(1) | Input.GetMouseButton(2);
114 | mh = anyMouseButton ? Input.GetAxis( "Mouse X" ) : 0f;
115 | mv = anyMouseButton ? Input.GetAxis( "Mouse Y" ) : 0f;
116 |
117 | h = kh * kh > mh * mh ? kh : mh;
118 | v = kv * kv > mv * mv ? kv : mv;
119 |
120 | if (h * h > Mathf.Epsilon || v * v > Mathf.Epsilon) {
121 | transform.position
122 | = sphericalCoordinates.Rotate(h * rotateSpeed * Time.deltaTime, v * rotateSpeed * Time.deltaTime).toCartesian + pivot.position;
123 | }
124 |
125 | float sw = -Input.GetAxis("Mouse ScrollWheel");
126 | if (sw * sw > Mathf.Epsilon) {
127 | transform.position = sphericalCoordinates.TranslateRadius(sw * Time.deltaTime * scrollSpeed).toCartesian + pivot.position;
128 | }
129 |
130 | transform.LookAt(pivot.position);
131 | }
132 | }
133 |
134 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter02.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: e9700d71a9ccbc547873f0c1a9537d67
3 | timeCreated: 1431745997
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter03.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using System.Collections.Generic;
4 | using UnityEngine.UI;
5 | using UnityEngine.EventSystems;
6 |
7 | // Based on the code at http://wiki.unity3d.com/index.php/SphericalCoordinates
8 | // This code is under Creative Commons Attribution Share Alike http://creativecommons.org/licenses/by-sa/3.0/
9 |
10 | public class Chapter03 : MonoBehaviour {
11 |
12 | public float rotateSpeed = 1f;
13 | public float scrollSpeed = 200f;
14 |
15 | public Transform pivot;
16 |
17 | [System.Serializable]
18 | public class SphericalCoordinates
19 | {
20 | public float _radius, _azimuth, _elevation;
21 |
22 | public float radius
23 | {
24 | get { return _radius; }
25 | private set
26 | {
27 | _radius = Mathf.Clamp( value, _minRadius, _maxRadius );
28 | }
29 | }
30 |
31 | public float azimuth
32 | {
33 | get { return _azimuth; }
34 | private set
35 | {
36 | _azimuth = Mathf.Repeat( value, _maxAzimuth - _minAzimuth );
37 | }
38 | }
39 |
40 | public float elevation
41 | {
42 | get{ return _elevation; }
43 | private set
44 | {
45 | _elevation = Mathf.Clamp( value, _minElevation, _maxElevation );
46 | }
47 | }
48 |
49 | public float _minRadius = 3f;
50 | public float _maxRadius = 20f;
51 |
52 | public float minAzimuth = 0f;
53 | private float _minAzimuth;
54 |
55 | public float maxAzimuth = 360f;
56 | private float _maxAzimuth;
57 |
58 | public float minElevation = 0f;
59 | private float _minElevation;
60 |
61 | public float maxElevation = 90f;
62 | private float _maxElevation;
63 |
64 | public SphericalCoordinates(){}
65 |
66 | public SphericalCoordinates(Vector3 cartesianCoordinate)
67 | {
68 | _minAzimuth = Mathf.Deg2Rad * minAzimuth;
69 | _maxAzimuth = Mathf.Deg2Rad * maxAzimuth;
70 |
71 | _minElevation = Mathf.Deg2Rad * minElevation;
72 | _maxElevation = Mathf.Deg2Rad * maxElevation;
73 |
74 | radius = cartesianCoordinate.magnitude;
75 | azimuth = Mathf.Atan2(cartesianCoordinate.z, cartesianCoordinate.x);
76 | elevation = Mathf.Asin(cartesianCoordinate.y / radius);
77 | }
78 |
79 | public Vector3 toCartesian
80 | {
81 | get
82 | {
83 | float t = radius * Mathf.Cos(elevation);
84 | return new Vector3(t * Mathf.Cos(azimuth), radius * Mathf.Sin(elevation), t * Mathf.Sin(azimuth));
85 | }
86 | }
87 |
88 | public SphericalCoordinates Rotate(float newAzimuth, float newElevation){
89 | azimuth += newAzimuth;
90 | elevation += newElevation;
91 | return this;
92 | }
93 |
94 | public SphericalCoordinates TranslateRadius(float x) {
95 | radius += x;
96 | return this;
97 | }
98 | }
99 |
100 | public SphericalCoordinates sphericalCoordinates;
101 |
102 | private List triangleVertices = new List();
103 |
104 | // Use this for initialization
105 | void Start () {
106 | sphericalCoordinates = new SphericalCoordinates(transform.position);
107 | transform.position = sphericalCoordinates.toCartesian + pivot.position;
108 |
109 | Mesh mesh = pivot.gameObject.GetComponent().mesh;
110 | for (int i = 0; i < mesh.vertices.Length; i++)
111 | {
112 | if (triangleVertices.Count < 3) {
113 | triangleVertices.Add(mesh.vertices[i]);
114 | }
115 | }
116 | }
117 |
118 | // Update is called once per frame
119 | void Update () {
120 | DrawCameraLine ();
121 |
122 | float kh, kv, mh, mv, h, v;
123 | kh = Input.GetAxis( "Horizontal" );
124 | kv = Input.GetAxis( "Vertical" );
125 |
126 | bool anyMouseButton = Input.GetMouseButton(0) | Input.GetMouseButton(1) | Input.GetMouseButton(2);
127 | mh = anyMouseButton ? Input.GetAxis( "Mouse X" ) : 0f;
128 | mv = anyMouseButton ? Input.GetAxis( "Mouse Y" ) : 0f;
129 |
130 | h = kh * kh > mh * mh ? kh : mh;
131 | v = kv * kv > mv * mv ? kv : mv;
132 |
133 | if (h * h > Mathf.Epsilon || v * v > Mathf.Epsilon) {
134 | transform.position
135 | = sphericalCoordinates.Rotate(h * rotateSpeed * Time.deltaTime, v * rotateSpeed * Time.deltaTime).toCartesian + pivot.position;
136 | }
137 |
138 | float sw = -Input.GetAxis("Mouse ScrollWheel");
139 | if (sw * sw > Mathf.Epsilon) {
140 | transform.position = sphericalCoordinates.TranslateRadius(sw * Time.deltaTime * scrollSpeed).toCartesian + pivot.position;
141 | }
142 |
143 | transform.LookAt(pivot.position);
144 | }
145 |
146 | void DrawCameraLine() {
147 | Debug.DrawLine(pivot.position, pivot.transform.forward * 2, Color.blue);
148 |
149 | Vector3 cameraPoint = transform.position + transform.forward * 5;
150 |
151 | Vector3 edge1 = triangleVertices [1] - triangleVertices [0];
152 | Vector3 edge2 = cameraPoint - triangleVertices [1];
153 |
154 | Vector3 edge3 = triangleVertices [2] - triangleVertices [1];
155 | Vector3 edge4 = cameraPoint - triangleVertices [2];
156 |
157 | Vector3 edge5 = triangleVertices [0] - triangleVertices [2];
158 | Vector3 edge6 = cameraPoint - triangleVertices [0];
159 |
160 | Vector3 cp1 = Vector3.Cross (edge1, edge2);
161 | Vector3 cp2 = Vector3.Cross (edge3, edge4);
162 | Vector3 cp3 = Vector3.Cross (edge5, edge6);
163 |
164 | if (Vector3.Dot (cp1, cp2) > 0 && Vector3.Dot (cp1, cp3) > 0) {
165 | Debug.DrawLine (transform.position, cameraPoint, Color.red);
166 | } else {
167 | Debug.DrawLine (transform.position, cameraPoint, Color.green);
168 | }
169 | }
170 | }
171 |
172 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter03.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 59371daceb36f3045a0454b09b7844b4
3 | timeCreated: 1432848578
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter04.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using System.Collections.Generic;
4 | using UnityEngine.UI;
5 | using UnityEngine.EventSystems;
6 |
7 | public class Chapter04 : MonoBehaviour {
8 |
9 | // Use this for initialization
10 | void Start () {
11 |
12 | }
13 |
14 | // Update is called once per frame
15 | void Update () {
16 |
17 | }
18 | }
19 |
20 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter04.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 39f82d046882aa24f9392c44b00c7917
3 | timeCreated: 1433748037
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter05.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using System.Collections.Generic;
4 | using UnityEngine.UI;
5 | using UnityEngine.EventSystems;
6 |
7 | public class Chapter05 : MonoBehaviour {
8 |
9 | public GameObject cube;
10 |
11 | // Use this for initialization
12 | void Start () {
13 | cube = GameObject.Find("Cube");
14 | }
15 |
16 | // Update is called once per frame
17 | void Update () {
18 |
19 | }
20 | }
21 |
22 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter05.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 984a33d276b554f488ff64e4688eccd6
3 | timeCreated: 1434176293
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter06.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using System.Collections.Generic;
4 | using UnityEngine.UI;
5 | using UnityEngine.EventSystems;
6 | using System;
7 | using UnityEngine.Assertions;
8 |
9 | public class Chapter06 : MonoBehaviour {
10 |
11 | private GameObject cube;
12 |
13 | private float cubeRotationTime;
14 |
15 | private Quaternion cubeRotationFrom;
16 | private Quaternion cubeRotationTo;
17 |
18 | private bool spinning = true;
19 | private bool rotating;
20 |
21 | // Use this for initialization
22 | void Start () {
23 | cube = GameObject.Find("Cube");
24 | }
25 |
26 | // Update is called once per frame
27 | void Update () {
28 | if (spinning) {
29 | Quaternion cubeSpinRotation = Quaternion.AngleAxis (-180.0f, Vector3.up);
30 | cube.transform.rotation = Quaternion.Slerp (cube.transform.rotation, cubeSpinRotation, 0.05f);
31 | }
32 |
33 | Quaternion cameraRotation = Quaternion.LookRotation(cube.transform.position + new Vector3(0, 0.5f, 0) - transform.position);
34 | transform.rotation = Quaternion.Slerp(transform.rotation, cameraRotation, Time.deltaTime);
35 | transform.Translate(0.02f, 0.005f, 0.5f * Time.deltaTime);
36 |
37 | if (rotating) {
38 | cubeRotationTime += Time.deltaTime / 0.5f;
39 | cube.transform.rotation = Quaternion.Slerp(cubeRotationFrom, cubeRotationTo, cubeRotationTime);
40 |
41 | if (cubeRotationTime >= 1.0f) {
42 | rotating = false;
43 | cubeRotationTime = 0;
44 | }
45 | } else {
46 | if (Input.GetKeyDown (KeyCode.UpArrow)) {
47 | ResetCubeRotation (Vector3.right);
48 | rotating = true;
49 | } else if (Input.GetKeyDown (KeyCode.DownArrow)) {
50 | ResetCubeRotation (Vector3.left);
51 | rotating = true;
52 | } else if (Input.GetKeyDown (KeyCode.RightArrow)) {
53 | ResetCubeRotation (Vector3.forward);
54 | rotating = true;
55 | } else if (Input.GetKeyDown (KeyCode.LeftArrow)) {
56 | ResetCubeRotation (Vector3.back);
57 | rotating = true;
58 | }
59 | }
60 | }
61 |
62 | public class QuaternionComparer : IEqualityComparer
63 | {
64 | public bool Equals(Quaternion lhs, Quaternion rhs) {
65 | return lhs == rhs;
66 | }
67 |
68 | public int GetHashCode(Quaternion obj) {
69 | return obj.GetHashCode();
70 | }
71 | }
72 |
73 | void ResetCubeRotation (Vector3 axis) {
74 | spinning = false;
75 | cubeRotationFrom = cube.transform.rotation;
76 |
77 | Quaternion q = Quaternion.AngleAxis(90.0f, Quaternion.Inverse(cubeRotationFrom) * axis);
78 | cubeRotationTo = cubeRotationFrom * q;
79 |
80 | Assert.IsTrue(Quaternion.Inverse(cubeRotationFrom) * axis == cube.transform.InverseTransformVector(axis));
81 | Assert.AreEqual(cubeRotationFrom * q, Quaternion.AngleAxis(90.0f, axis) * cubeRotationFrom, null, new QuaternionComparer());
82 | }
83 | }
84 |
85 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter06.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 494fa98142933154b8270c52b41371e3
3 | timeCreated: 1435627206
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter07.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using System.Collections.Generic;
4 | using UnityEngine.UI;
5 | using UnityEngine.EventSystems;
6 | using System;
7 | using UnityEngine.Assertions;
8 |
9 | [ExecuteInEditMode]
10 | public class Chapter07 : MonoBehaviour {
11 | private LineRenderer lineRenderer;
12 |
13 | public GameObject[] controlPoints = new GameObject[3];
14 | public Color color = Color.red;
15 | public float width = 0.1f;
16 | public int numberOfPoints = 20;
17 |
18 | public enum CurveType {
19 | Bezier,
20 | CatmullRom,
21 | BSpline,
22 | }
23 |
24 | public CurveType curveType = CurveType.Bezier;
25 |
26 | private CurveType oldCurveType = CurveType.Bezier;
27 |
28 | private int vertexCountDiff = 0;
29 |
30 | private Func CheckBoundary = null;
31 | private Action SetupPoints = null;
32 | private Func ParametricTransformWithGeometryMatrix = null;
33 |
34 | // Use this for initialization
35 | void Start () {
36 | lineRenderer = GetComponent();
37 | lineRenderer.useWorldSpace = true;
38 | }
39 |
40 | // Update is called once per frame
41 | void Update () {
42 | if (controlPoints == null || controlPoints.Length < 3) {
43 | Debug.LogError("Control Points are not found");
44 | return;
45 | }
46 |
47 | if (numberOfPoints < 2) {
48 | numberOfPoints = 2;
49 | }
50 |
51 | if (oldCurveType != curveType) {
52 | CheckBoundary = null;
53 | SetupPoints = null;
54 | ParametricTransformWithGeometryMatrix = null;
55 |
56 | oldCurveType = curveType;
57 | }
58 |
59 | if (CheckBoundary == null) {
60 | Matrix4x4 matrix = new Matrix4x4();
61 |
62 | if (curveType == CurveType.Bezier) {
63 | vertexCountDiff = 2;
64 |
65 | CheckBoundary = (i) => {
66 | return !(controlPoints [i] == null
67 | || controlPoints [i + 1] == null
68 | || controlPoints [i + 2] == null);
69 | };
70 |
71 | Matrix4x4 m = new Matrix4x4 ();
72 | m.SetRow (0, new Vector3 (1f, -2f, 1f));
73 | m.SetRow (1, new Vector3 (-2f, 2f, 0f));
74 | m.SetRow (2, new Vector3 (1f, 0f, 0f));
75 | m = m.transpose;
76 |
77 | SetupPoints = (i) => {
78 | matrix.SetColumn (0, 0.5f * (controlPoints [i].transform.position + controlPoints [i + 1].transform.position));
79 | matrix.SetColumn (1, controlPoints [i + 1].transform.position);
80 | matrix.SetColumn (2, 0.5f * (controlPoints [i + 1].transform.position + controlPoints [i + 2].transform.position));
81 | matrix *= m;
82 | };
83 |
84 | ParametricTransformWithGeometryMatrix = (t) => {
85 | return matrix * new Vector3 (t * t, t, 1);
86 | };
87 | } else if (curveType == CurveType.CatmullRom) {
88 | vertexCountDiff = 1;
89 |
90 | CheckBoundary = (i) => {
91 | return !(controlPoints [i] == null
92 | || controlPoints [i + 1] == null
93 | || (i > 0 && controlPoints [i - 1] == null)
94 | || (i < controlPoints.Length - 2 && controlPoints [i + 2] == null));
95 | };
96 |
97 | Matrix4x4 m = new Matrix4x4 ();
98 | m.SetRow (0, new Vector4 (1f, 0f, 0f, 0f));
99 | m.SetRow (1, new Vector4 (0f, 0f, 1f, 0f));
100 | m.SetRow (2, new Vector4 (-3f, 3f, -2f, -1f));
101 | m.SetRow (3, new Vector4 (2f, -2f, 1f, 1f));
102 | m = m.transpose;
103 |
104 | SetupPoints = (i) => {
105 | matrix.SetColumn (0, controlPoints [i].transform.position);
106 | matrix.SetColumn (1, controlPoints [i + 1].transform.position);
107 |
108 | if (i > 0) {
109 | matrix.SetColumn (2, 0.5f * (controlPoints [i + 1].transform.position - controlPoints [i - 1].transform.position));
110 | } else {
111 | matrix.SetColumn (2, controlPoints [i + 1].transform.position - controlPoints [i].transform.position);
112 | }
113 |
114 | if (i < controlPoints.Length - 2) {
115 | matrix.SetColumn (3, 0.5f * (controlPoints [i + 2].transform.position - controlPoints [i].transform.position));
116 | } else {
117 | matrix.SetColumn (3, controlPoints [i + 1].transform.position - controlPoints [i].transform.position);
118 | }
119 |
120 | matrix *= m;
121 | };
122 |
123 | ParametricTransformWithGeometryMatrix = (t) => {
124 | return matrix * new Vector4 (1, t, t * t, t * t * t);
125 | };
126 | } else if (curveType == CurveType.BSpline) {
127 | vertexCountDiff = 3;
128 |
129 | CheckBoundary = (i) => {
130 | return !(controlPoints [i] == null
131 | || controlPoints [i + 1] == null
132 | || controlPoints [i + 2] == null
133 | || controlPoints [i + 3] == null);
134 | };
135 |
136 | Matrix4x4 m = new Matrix4x4 ();
137 | m.SetRow (0, new Vector4 (-1f, 3f, -3f, 1f) * 1 / 6);
138 | m.SetRow (1, new Vector4 (3f, -6f, 3f, 0f) * 1 / 6);
139 | m.SetRow (2, new Vector4 (-3f, 0f, 3f, 0f) * 1 / 6);
140 | m.SetRow (3, new Vector4 (1f, 4f, 1f, 0f) * 1 / 6);
141 | m = m.transpose;
142 |
143 | SetupPoints = (i) => {
144 | matrix.SetColumn (0, controlPoints [i].transform.position);
145 | matrix.SetColumn (1, controlPoints [i + 1].transform.position);
146 | matrix.SetColumn (2, controlPoints [i + 2].transform.position);
147 | matrix.SetColumn (3, controlPoints [i + 3].transform.position);
148 | matrix *= m;
149 | };
150 |
151 | ParametricTransformWithGeometryMatrix = (t) => {
152 | return matrix * new Vector4 (t * t * t, t * t, t, 1);
153 | };
154 | }
155 | }
156 |
157 | lineRenderer.startColor = color;
158 | lineRenderer.endColor = color;
159 | lineRenderer.startWidth = width;
160 | lineRenderer.endWidth = width;
161 | lineRenderer.positionCount = numberOfPoints * (controlPoints.Length - vertexCountDiff);
162 |
163 | for (int j = 0; j < controlPoints.Length - vertexCountDiff; j++) {
164 | if (!CheckBoundary(j)) {
165 | return;
166 | }
167 |
168 | SetupPoints(j);
169 |
170 | float pointStep = j == controlPoints.Length - (vertexCountDiff + 1)
171 | ? 1.0f / (numberOfPoints - 1.0f): 1.0f / numberOfPoints;
172 |
173 | for (int i = 0; i < numberOfPoints; i++) {
174 | Vector3 position = ParametricTransformWithGeometryMatrix(i * pointStep);
175 | lineRenderer.SetPosition (i + j * numberOfPoints, position);
176 | }
177 | }
178 |
179 | if (Input.GetMouseButtonDown (0) && !EventSystem.current.IsPointerOverGameObject()) {
180 | Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
181 | RaycastHit hit;
182 | List controlPointsNew = new List();
183 | if (Physics.Raycast(ray, out hit)) {
184 | GameObject hitObj = hit.transform.gameObject;
185 | foreach (GameObject obj in controlPoints) {
186 | bool used = true;
187 | if (controlPoints.Length > 4 && obj.Equals(hitObj)) {
188 | if (obj.Equals(controlPoints[controlPoints.Length - 1])) {
189 | if (controlPointsNew.Count > 0) {
190 | controlPointsNew.Add(controlPointsNew[controlPointsNew.Count - 1]);
191 | Destroy(obj);
192 | }
193 |
194 | break;
195 | }
196 |
197 | if (!obj.Equals(controlPoints[0])) {
198 | used = false;
199 | Destroy(obj);
200 | }
201 | }
202 |
203 | if (used) {
204 | controlPointsNew.Add(obj);
205 | }
206 | }
207 |
208 | if (controlPointsNew.Count != 0 && controlPointsNew.Count != controlPoints.Length) {
209 | controlPoints = controlPointsNew.ToArray();
210 | }
211 | } else {
212 | GameObject sp = SpawnSphereAt(Input.mousePosition);
213 | foreach (GameObject obj in controlPoints) {
214 | controlPointsNew.Add(obj);
215 | if (controlPointsNew.Count == controlPoints.Length - 2) {
216 | controlPointsNew.Add(sp);
217 | }
218 | }
219 |
220 | controlPoints = controlPointsNew.ToArray();
221 | }
222 | }
223 | }
224 |
225 | GameObject SpawnSphereAt(Vector3 mousePosition) {
226 | GameObject sp = GameObject.CreatePrimitive(PrimitiveType.Sphere);
227 | Vector3 position = Camera.main.ScreenToWorldPoint(new Vector3(mousePosition.x, mousePosition.y, 0));
228 | sp.transform.position = new Vector3(position.x, position.y, 0);
229 | sp.name += sp.GetInstanceID ().ToString ();
230 | return sp;
231 | }
232 | }
233 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter07.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 8bf418e9600597c4a95286dd9e8c9464
3 | timeCreated: 1435743237
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter09.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using System.Collections;
3 | using System.Collections.Generic;
4 | using UnityEngine.UI;
5 | using UnityEngine.EventSystems;
6 | using System;
7 | using UnityEngine.Assertions;
8 | using System.Runtime.InteropServices;
9 |
10 |
11 | public class Chapter09 : MonoBehaviour {
12 | private GameObject target;
13 |
14 | // Use this for initialization
15 | void Start () {
16 | target = GameObject.Find("Phong");
17 | }
18 |
19 | // Update is called once per frame
20 | void Update () {
21 | Quaternion targetRotation = Quaternion.LookRotation(
22 | target.transform.position + new Vector3(0, 0.5f, 0) - transform.position);
23 | transform.rotation = Quaternion.Slerp(transform.rotation, targetRotation, Time.deltaTime);
24 | transform.Translate(0.02f, 0.005f, 0.5f * Time.deltaTime);
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/Chapter09.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: b3c9983976586ee4eba3b39b8f4a5324
3 | timeCreated: 1436713489
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/SceneLoader.cs:
--------------------------------------------------------------------------------
1 | using UnityEngine;
2 | using UnityEngine.SceneManagement;
3 | using System.Collections;
4 |
5 | public class SceneLoader : MonoBehaviour {
6 |
7 | void Awake () {
8 | float ratio = Mathf.Clamp((float)1024 / Screen.height, 0, 1);
9 | Screen.SetResolution((int)(Screen.width * ratio), (int)(Screen.height * ratio), true, 60);
10 | }
11 |
12 | // Use this for initialization
13 | void Start () {
14 |
15 | }
16 |
17 | // Update is called once per frame
18 | void Update () {
19 |
20 | }
21 |
22 | public void Load(string name) {
23 | StartCoroutine(DoLoad(name));
24 | }
25 |
26 | IEnumerator DoLoad(string name) {
27 | AsyncOperation async = SceneManager.LoadSceneAsync(name);
28 | yield return async;
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/sample/Assets/Scripts/SceneLoader.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 4def5e54cb7adeb4ca2869e93f30240c
3 | timeCreated: 1430899307
4 | licenseType: Free
5 | MonoImporter:
6 | serializedVersion: 2
7 | defaultReferences: []
8 | executionOrder: 0
9 | icon: {instanceID: 0}
10 | userData:
11 | assetBundleName:
12 | assetBundleVariant:
13 |
--------------------------------------------------------------------------------
/sample/Assets/Shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: ed4c4626499462441b92536b78638ed5
3 | folderAsset: yes
4 | timeCreated: 1436805568
5 | licenseType: Free
6 | DefaultImporter:
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/CookTorrance.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/CookTorrance" {
2 | Properties {
3 | _Color ("Diffuse Color", Color) = (1,1,1,1)
4 | _Roughness ("Roughness", Float) = 0.5
5 | _FresnelReflectance ("Fresnel Reflectance", Float) = 0.5
6 | }
7 | SubShader {
8 | Pass {
9 | Tags { "LightMode" = "ForwardBase" }
10 |
11 | GLSLPROGRAM
12 | #include "UnityCG.glslinc"
13 | #if !defined _Object2World
14 | #define _Object2World unity_ObjectToWorld
15 | #endif
16 |
17 | uniform vec4 _LightColor0;
18 |
19 | uniform vec4 _Color;
20 | uniform float _Roughness;
21 | uniform float _FresnelReflectance;
22 |
23 | #ifdef VERTEX
24 | out vec4 glVertexWorld;
25 | out vec3 surfaceNormal;
26 |
27 | void main() {
28 | surfaceNormal = normalize((_Object2World * vec4(gl_Normal, 0.0)).xyz);
29 | glVertexWorld = _Object2World * gl_Vertex;
30 |
31 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
32 | }
33 | #endif
34 |
35 | #ifdef FRAGMENT
36 | in vec4 glVertexWorld;
37 | in vec3 surfaceNormal;
38 |
39 | void main() {
40 | vec3 ambientLight = gl_LightModel.ambient.xyz * vec3(_Color);
41 |
42 | vec3 lightDirectionNormal = normalize(_WorldSpaceLightPos0.xyz);
43 | float NdotL = saturate(dot(surfaceNormal, lightDirectionNormal));
44 |
45 | vec3 viewDirectionNormal = normalize((vec4(_WorldSpaceCameraPos, 1.0) - glVertexWorld).xyz);
46 | float NdotV = saturate(dot(surfaceNormal, viewDirectionNormal));
47 |
48 | vec3 halfVector = normalize(lightDirectionNormal + viewDirectionNormal);
49 | float NdotH = saturate(dot(surfaceNormal, halfVector));
50 | float VdotH = saturate(dot(viewDirectionNormal, halfVector));
51 |
52 | float roughness = saturate(_Roughness);
53 | float alpha = roughness * roughness;
54 | float alpha2 = alpha * alpha;
55 | float t = ((NdotH * NdotH) * (alpha2 - 1.0) + 1.0);
56 | float PI = 3.1415926535897;
57 | float D = alpha2 / (PI * t * t);
58 |
59 | float F0 = saturate(_FresnelReflectance);
60 | float F = pow(1.0 - VdotH, 5.0);
61 | F *= (1.0 - F0);
62 | F += F0;
63 |
64 | float NH2 = 2.0 * NdotH;
65 | float g1 = (NH2 * NdotV) / VdotH;
66 | float g2 = (NH2 * NdotL) / VdotH;
67 | float G = min(1.0, min(g1, g2));
68 |
69 | float specularReflection = (D * F * G) / (4.0 * NdotV * NdotL + 0.000001);
70 | vec3 diffuseReflection = _LightColor0.xyz * _Color.xyz * NdotL;
71 |
72 | gl_FragColor = vec4(ambientLight + diffuseReflection + specularReflection, 1.0);
73 | }
74 | #endif
75 |
76 | ENDGLSL
77 | }
78 | }
79 | //FallBack "Diffuse"
80 | }
81 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/CookTorrance.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 5dc534f9006a65b40bc3bd71ac004e5f
3 | timeCreated: 1438258815
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Diffuse.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/Diffuse" {
2 | Properties {
3 | _Color ("Color", Color) = (1,1,1,1)
4 | }
5 | SubShader {
6 | Pass {
7 | Tags { "LightMode" = "ForwardBase" }
8 |
9 | GLSLPROGRAM
10 | #include "UnityCG.glslinc"
11 | #if !defined _Object2World
12 | #define _Object2World unity_ObjectToWorld
13 | #endif
14 |
15 | uniform vec4 _LightColor0;
16 |
17 | uniform vec4 _Color;
18 |
19 | #ifdef VERTEX
20 | out vec4 color;
21 |
22 | void main() {
23 | vec3 surfaceNormal = normalize(vec3(_Object2World * vec4(gl_Normal, 0.0)));
24 | vec3 lightDirectionNormal = normalize(vec3(_WorldSpaceLightPos0));
25 | vec3 diffuseReflection = vec3(_LightColor0) * vec3(_Color) * max(0.0, dot(surfaceNormal, lightDirectionNormal));
26 | color = vec4(diffuseReflection, 1.0);
27 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
28 | }
29 | #endif
30 |
31 | #ifdef FRAGMENT
32 | in vec4 color;
33 |
34 | void main() {
35 | gl_FragColor = color;
36 | }
37 | #endif
38 |
39 | ENDGLSL
40 | }
41 | }
42 | //FallBack "Diffuse"
43 | }
44 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Diffuse.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 090d660bb8ad39b48a24e7fa19990f6c
3 | timeCreated: 1438031894
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Gouraud.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/Gouraud" {
2 | Properties {
3 | _Color ("Diffuse Color", Color) = (1,1,1,1)
4 | _SpecularColor ("Specular Color", Color) = (1,1,1,1)
5 | _SpecularExponent ("Specular Exponent", Float) = 3
6 | }
7 | SubShader {
8 | Pass {
9 | Tags { "LightMode" = "ForwardBase" }
10 |
11 | GLSLPROGRAM
12 | #include "UnityCG.glslinc"
13 | #if !defined _Object2World
14 | #define _Object2World unity_ObjectToWorld
15 | #endif
16 |
17 | uniform vec4 _LightColor0;
18 |
19 | uniform vec4 _Color;
20 | uniform vec4 _SpecularColor;
21 | uniform float _SpecularExponent;
22 |
23 | #ifdef VERTEX
24 | out vec4 color;
25 |
26 | void main() {
27 | vec3 ambientLight = gl_LightModel.ambient.xyz * vec3(_Color);
28 |
29 | vec3 surfaceNormal = normalize((_Object2World * vec4(gl_Normal, 0.0)).xyz);
30 | vec3 lightDirectionNormal = normalize(_WorldSpaceLightPos0.xyz);
31 | vec3 diffuseReflection = _LightColor0.xyz * _Color.xyz * max(0.0, dot(surfaceNormal, lightDirectionNormal));
32 |
33 | vec3 viewDirectionNormal = normalize((vec4(_WorldSpaceCameraPos, 1.0) - _Object2World * gl_Vertex).xyz);
34 | vec3 specularReflection = _LightColor0.xyz * _SpecularColor.xyz
35 | * pow(max(0.0, dot(reflect(-lightDirectionNormal, surfaceNormal), viewDirectionNormal)), _SpecularExponent);
36 |
37 | color = vec4(ambientLight + diffuseReflection + specularReflection, 1.0);
38 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
39 | }
40 | #endif
41 |
42 | #ifdef FRAGMENT
43 | in vec4 color;
44 |
45 | void main() {
46 | gl_FragColor = color;
47 | }
48 | #endif
49 |
50 | ENDGLSL
51 | }
52 | }
53 | //FallBack "Diffuse"
54 | }
55 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Gouraud.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 7ee4731ba0154724f9025e0883b0597a
3 | timeCreated: 1438089307
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/HalfLambert.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/Half Lambert" {
2 | Properties {
3 | _Color ("Color", Color) = (1,1,1,1)
4 | }
5 | SubShader {
6 | Pass {
7 | Tags { "LightMode" = "ForwardBase" }
8 |
9 | GLSLPROGRAM
10 | #include "UnityCG.glslinc"
11 | #if !defined _Object2World
12 | #define _Object2World unity_ObjectToWorld
13 | #endif
14 |
15 | uniform vec4 _LightColor0;
16 |
17 | uniform vec4 _Color;
18 |
19 | #ifdef VERTEX
20 | out vec4 color;
21 |
22 | void main() {
23 | vec3 surfaceNormal = normalize(vec3(_Object2World * vec4(gl_Normal, 0.0)));
24 | vec3 lightDirectionNormal = normalize(vec3(_WorldSpaceLightPos0));
25 | float halfLambert = max(0.0, dot(surfaceNormal, lightDirectionNormal)) * 0.5 + 0.5;
26 | vec3 diffuseReflection = vec3(_LightColor0) * vec3(_Color) * halfLambert * halfLambert;
27 | color = vec4(diffuseReflection, 1.0);
28 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
29 | }
30 | #endif
31 |
32 | #ifdef FRAGMENT
33 | in vec4 color;
34 |
35 | void main() {
36 | gl_FragColor = color;
37 | }
38 | #endif
39 |
40 | ENDGLSL
41 | }
42 | }
43 | //FallBack "Diffuse"
44 | }
45 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/HalfLambert.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 761c206b5d6c2439da90ead865ccc711
3 | timeCreated: 1438073852
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/NormalMap.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/NormalMap" {
2 | Properties {
3 | _Color ("Diffuse Color", Color) = (1,1,1,1)
4 | _SpecularColor ("Specular Color", Color) = (1,1,1,1)
5 | _SpecularExponent ("Specular Exponent", Float) = 10
6 | _NormalMap ("Normal Map", 2D) = "bump" {}
7 | }
8 | SubShader {
9 | Pass {
10 | Tags { "LightMode" = "ForwardBase" }
11 |
12 | GLSLPROGRAM
13 | #include "UnityCG.glslinc"
14 | #if !defined _Object2World
15 | #define _Object2World unity_ObjectToWorld
16 | #endif
17 |
18 | uniform vec4 _LightColor0;
19 |
20 | uniform vec4 _Color;
21 | uniform vec4 _SpecularColor;
22 | uniform float _SpecularExponent;
23 |
24 | uniform sampler2D _NormalMap;
25 | uniform vec4 _NormalMap_ST;
26 |
27 | #ifdef VERTEX
28 | out vec4 normalMapCoord;
29 | out vec4 glVertexWorld;
30 | out mat3 tbn;
31 |
32 | attribute vec4 Tangent;
33 |
34 | void main() {
35 | glVertexWorld = _Object2World * gl_Vertex;
36 |
37 | vec3 n = normalize((_Object2World * vec4(gl_Normal, 0.0)).xyz);
38 | vec3 t = normalize((_Object2World * vec4(Tangent.xyz, 0.0)).xyz);
39 | vec3 b = normalize(cross(n, t) * Tangent.w);
40 | tbn = mat3(t, b, n);
41 |
42 | normalMapCoord = gl_MultiTexCoord0;
43 |
44 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
45 | }
46 | #endif
47 |
48 | #ifdef FRAGMENT
49 | in vec4 normalMapCoord;
50 | in vec4 glVertexWorld;
51 | in mat3 tbn;
52 |
53 | vec3 unpackNormalDXT5nm(vec4 packednormal) {
54 | vec3 normal;
55 | normal.xy = packednormal.wy * 2.0 - 1.0;
56 | normal.z = sqrt(1.0 - saturate(dot(normal.xy, normal.xy)));
57 | return normal;
58 | }
59 |
60 | vec3 unpackNormal(vec4 packednormal) {
61 | #if defined(UNITY_NO_DXT5nm)
62 | return packednormal.xyz * 2.0 - 1.0;
63 | #else
64 | return unpackNormalDXT5nm(packednormal);
65 | #endif
66 | }
67 |
68 | void main() {
69 | vec4 packedNormal = texture2D(_NormalMap, _NormalMap_ST.xy * normalMapCoord.xy + _NormalMap_ST.zw);
70 | vec3 tangentSpaceVector = unpackNormal(packedNormal);
71 | vec3 surfaceNormal = normalize(tbn * tangentSpaceVector);
72 |
73 | vec3 ambientLight = gl_LightModel.ambient.xyz * vec3(_Color);
74 |
75 | vec3 lightDirectionNormal = normalize(_WorldSpaceLightPos0.xyz);
76 | vec3 diffuseReflection = _LightColor0.xyz * _Color.xyz * max(0.0, dot(surfaceNormal, lightDirectionNormal));
77 |
78 | vec3 viewDirectionNormal = normalize((vec4(_WorldSpaceCameraPos, 1.0) - glVertexWorld).xyz);
79 | vec3 specularReflection = _LightColor0.xyz * _SpecularColor.xyz
80 | * pow(max(0.0, dot(reflect(-lightDirectionNormal, surfaceNormal), viewDirectionNormal)), _SpecularExponent);
81 |
82 | gl_FragColor = vec4(ambientLight + diffuseReflection + specularReflection, 1.0);
83 | }
84 | #endif
85 |
86 | ENDGLSL
87 | }
88 | }
89 | //FallBack "Diffuse"
90 | }
91 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/NormalMap.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 8e3276c2ba3616b44b058875921d68c4
3 | timeCreated: 1438108450
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Phong.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/Phong" {
2 | Properties {
3 | _Color ("Diffuse Color", Color) = (1,1,1,1)
4 | _SpecularColor ("Specular Color", Color) = (1,1,1,1)
5 | _SpecularExponent ("Specular Exponent", Float) = 3
6 | }
7 | SubShader {
8 | Pass {
9 | Tags { "LightMode" = "ForwardBase" }
10 |
11 | GLSLPROGRAM
12 | #include "UnityCG.glslinc"
13 | #if !defined _Object2World
14 | #define _Object2World unity_ObjectToWorld
15 | #endif
16 |
17 | uniform vec4 _LightColor0;
18 |
19 | uniform vec4 _Color;
20 | uniform vec4 _SpecularColor;
21 | uniform float _SpecularExponent;
22 |
23 | #ifdef VERTEX
24 | out vec4 glVertexWorld;
25 | out vec3 surfaceNormal;
26 |
27 | void main() {
28 | surfaceNormal = normalize((_Object2World * vec4(gl_Normal, 0.0)).xyz);
29 | glVertexWorld = _Object2World * gl_Vertex;
30 |
31 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
32 | }
33 | #endif
34 |
35 | #ifdef FRAGMENT
36 | in vec4 glVertexWorld;
37 | in vec3 surfaceNormal;
38 |
39 | void main() {
40 | vec3 ambientLight = gl_LightModel.ambient.xyz * vec3(_Color);
41 |
42 | vec3 lightDirectionNormal = normalize(_WorldSpaceLightPos0.xyz);
43 | vec3 diffuseReflection = _LightColor0.xyz * _Color.xyz * max(0.0, dot(surfaceNormal, lightDirectionNormal));
44 |
45 | vec3 viewDirectionNormal = normalize((vec4(_WorldSpaceCameraPos, 1.0) - glVertexWorld).xyz);
46 | vec3 specularReflection = _LightColor0.xyz * _SpecularColor.xyz
47 | * pow(max(0.0, dot(reflect(-lightDirectionNormal, surfaceNormal), viewDirectionNormal)), _SpecularExponent);
48 |
49 | gl_FragColor = vec4(ambientLight + diffuseReflection + specularReflection, 1.0);
50 | }
51 | #endif
52 |
53 | ENDGLSL
54 | }
55 | }
56 | //FallBack "Diffuse"
57 | }
58 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Phong.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 6c9747299252e3c48a9008b240155024
3 | timeCreated: 1438095106
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Rim.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/Rim" {
2 | Properties {
3 | _Color ("Diffuse Color", Color) = (1,1,1,1)
4 | _SpecularColor ("Specular Color", Color) = (1,1,1,1)
5 | _SpecularExponent ("Specular Exponent", Float) = 3
6 | _RimColor ("Rim Color", Color) = (0,1,0,1)
7 | }
8 | SubShader {
9 | Pass {
10 | Tags { "LightMode" = "ForwardBase" }
11 |
12 | GLSLPROGRAM
13 | #include "UnityCG.glslinc"
14 | #if !defined _Object2World
15 | #define _Object2World unity_ObjectToWorld
16 | #endif
17 |
18 | uniform vec4 _LightColor0;
19 |
20 | uniform vec4 _Color;
21 | uniform vec4 _SpecularColor;
22 | uniform float _SpecularExponent;
23 | uniform vec4 _RimColor;
24 |
25 | #ifdef VERTEX
26 | out vec4 glVertexWorld;
27 | out vec3 surfaceNormal;
28 |
29 | void main() {
30 | surfaceNormal = normalize((_Object2World * vec4(gl_Normal, 0.0)).xyz);
31 | glVertexWorld = _Object2World * gl_Vertex;
32 |
33 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
34 | }
35 | #endif
36 |
37 | #ifdef FRAGMENT
38 | in vec4 glVertexWorld;
39 | in vec3 surfaceNormal;
40 |
41 | void main() {
42 | vec3 ambientLight = gl_LightModel.ambient.xyz * vec3(_Color);
43 |
44 | vec3 lightDirectionNormal = normalize(_WorldSpaceLightPos0.xyz);
45 | vec3 diffuseReflection = _LightColor0.xyz * _Color.xyz * max(0.0, dot(surfaceNormal, lightDirectionNormal));
46 |
47 | vec3 viewDirectionNormal = normalize((vec4(_WorldSpaceCameraPos, 1.0) - glVertexWorld).xyz);
48 | vec3 specularReflection = _LightColor0.xyz * _SpecularColor.xyz
49 | * pow(max(0.0, dot(reflect(-lightDirectionNormal, surfaceNormal), viewDirectionNormal)), _SpecularExponent);
50 |
51 | float rim = 1.0 - saturate(dot(viewDirectionNormal, surfaceNormal));
52 | gl_FragColor.xyz = ambientLight + diffuseReflection + specularReflection + vec3(smoothstep(0.5, 1.0, rim)) * _RimColor.xyz;
53 | gl_FragColor.w = 1.0;
54 | }
55 | #endif
56 |
57 | ENDGLSL
58 | }
59 | }
60 | //FallBack "Diffuse"
61 | }
62 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Rim.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 841d3a48e5f682e4a9349b185142dea2
3 | timeCreated: 1438102149
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Test.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/Test" {
2 | Properties {
3 | _Color ("Color", Color) = (1,1,1,1)
4 | }
5 | SubShader {
6 | Pass {
7 | GLSLPROGRAM
8 | #include "UnityCG.glslinc"
9 |
10 | #ifdef VERTEX
11 | void main() {
12 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
13 | }
14 | #endif
15 |
16 | #ifdef FRAGMENT
17 | void main() {
18 | gl_FragColor = vec4(1.0, 0.0, 0.0, 1.0);
19 | }
20 | #endif
21 | ENDGLSL
22 | }
23 | }
24 | FallBack "Diffuse"
25 | }
26 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/Test.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 14104973823c4e942bb09a50556ffa4d
3 | timeCreated: 1436805580
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/TextureMap.shader:
--------------------------------------------------------------------------------
1 | Shader "Custom/TextureMap" {
2 | Properties {
3 | _Color ("Diffuse Color", Color) = (1,1,1,1)
4 | _SpecularColor ("Specular Color", Color) = (1,1,1,1)
5 | _SpecularExponent ("Specular Exponent", Float) = 10
6 | _Texture ("Texture", 2D) = "white" {}
7 | }
8 | SubShader {
9 | Pass {
10 | Tags { "LightMode" = "ForwardBase" }
11 |
12 | GLSLPROGRAM
13 | #include "UnityCG.glslinc"
14 | #if !defined _Object2World
15 | #define _Object2World unity_ObjectToWorld
16 | #endif
17 |
18 | uniform vec4 _LightColor0;
19 |
20 | uniform vec4 _Color;
21 | uniform vec4 _SpecularColor;
22 | uniform float _SpecularExponent;
23 |
24 | uniform sampler2D _Texture;
25 |
26 | #ifdef VERTEX
27 | out vec4 textureCoord;
28 | out vec4 glVertexWorld;
29 | out vec3 surfaceNormal;
30 |
31 | void main() {
32 | surfaceNormal = normalize((_Object2World * vec4(gl_Normal, 0.0)).xyz);
33 | glVertexWorld = _Object2World * gl_Vertex;
34 |
35 | textureCoord = gl_MultiTexCoord0;
36 |
37 | gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
38 | }
39 | #endif
40 |
41 | #ifdef FRAGMENT
42 | in vec4 textureCoord;
43 | in vec4 glVertexWorld;
44 | in vec3 surfaceNormal;
45 |
46 | void main() {
47 | vec3 ambientLight = gl_LightModel.ambient.xyz * vec3(_Color);
48 |
49 | vec3 lightDirectionNormal = normalize(_WorldSpaceLightPos0.xyz);
50 | vec3 diffuseReflection = _LightColor0.xyz * _Color.xyz * max(0.0, dot(surfaceNormal, lightDirectionNormal));
51 |
52 | vec3 viewDirectionNormal = normalize((vec4(_WorldSpaceCameraPos, 1.0) - glVertexWorld).xyz);
53 | vec3 specularReflection = _LightColor0.xyz * _SpecularColor.xyz
54 | * pow(max(0.0, dot(reflect(-lightDirectionNormal, surfaceNormal), viewDirectionNormal)), _SpecularExponent);
55 |
56 | gl_FragColor = texture2D(_Texture, vec2(textureCoord)) * vec4(ambientLight + diffuseReflection + specularReflection, 1.0);
57 | }
58 | #endif
59 |
60 | ENDGLSL
61 | }
62 | }
63 | //FallBack "Diffuse"
64 | }
65 |
--------------------------------------------------------------------------------
/sample/Assets/Shader/TextureMap.shader.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: d0aa727737c7f8245a835d0681677f9c
3 | timeCreated: 1438107224
4 | licenseType: Free
5 | ShaderImporter:
6 | defaultTextures: []
7 | userData:
8 | assetBundleName:
9 | assetBundleVariant:
10 |
--------------------------------------------------------------------------------
/sample/Library/AnnotationManager:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/AnnotationManager
--------------------------------------------------------------------------------
/sample/Library/BuildPlayer.prefs:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/BuildPlayer.prefs
--------------------------------------------------------------------------------
/sample/Library/BuildSettings.asset:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/BuildSettings.asset
--------------------------------------------------------------------------------
/sample/Library/CurrentLayout.dwlt:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!114 &1
4 | MonoBehaviour:
5 | m_ObjectHideFlags: 52
6 | m_PrefabParentObject: {fileID: 0}
7 | m_PrefabInternal: {fileID: 0}
8 | m_GameObject: {fileID: 0}
9 | m_Enabled: 1
10 | m_EditorHideFlags: 1
11 | m_Script: {fileID: 12004, guid: 0000000000000000e000000000000000, type: 0}
12 | m_Name:
13 | m_EditorClassIdentifier:
14 | m_PixelRect:
15 | serializedVersion: 2
16 | x: 388
17 | y: 164
18 | width: 1991
19 | height: 1243
20 | m_ShowMode: 4
21 | m_Title:
22 | m_RootView: {fileID: 4}
23 | m_MinSize: {x: 950, y: 300}
24 | m_MaxSize: {x: 10000, y: 10000}
25 | --- !u!114 &2
26 | MonoBehaviour:
27 | m_ObjectHideFlags: 52
28 | m_PrefabParentObject: {fileID: 0}
29 | m_PrefabInternal: {fileID: 0}
30 | m_GameObject: {fileID: 0}
31 | m_Enabled: 1
32 | m_EditorHideFlags: 1
33 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0}
34 | m_Name:
35 | m_EditorClassIdentifier:
36 | m_Children: []
37 | m_Position:
38 | serializedVersion: 2
39 | x: 0
40 | y: 0
41 | width: 231
42 | height: 1193
43 | m_MinSize: {x: 202, y: 221}
44 | m_MaxSize: {x: 4002, y: 4021}
45 | m_ActualView: {fileID: 14}
46 | m_Panes:
47 | - {fileID: 14}
48 | m_Selected: 0
49 | m_LastSelected: 0
50 | --- !u!114 &3
51 | MonoBehaviour:
52 | m_ObjectHideFlags: 52
53 | m_PrefabParentObject: {fileID: 0}
54 | m_PrefabInternal: {fileID: 0}
55 | m_GameObject: {fileID: 0}
56 | m_Enabled: 1
57 | m_EditorHideFlags: 1
58 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0}
59 | m_Name:
60 | m_EditorClassIdentifier:
61 | m_Children: []
62 | m_Position:
63 | serializedVersion: 2
64 | x: 0
65 | y: 943
66 | width: 844
67 | height: 250
68 | m_MinSize: {x: 104, y: 121}
69 | m_MaxSize: {x: 4004, y: 4021}
70 | m_ActualView: {fileID: 13}
71 | m_Panes:
72 | - {fileID: 13}
73 | m_Selected: 0
74 | m_LastSelected: 0
75 | --- !u!114 &4
76 | MonoBehaviour:
77 | m_ObjectHideFlags: 52
78 | m_PrefabParentObject: {fileID: 0}
79 | m_PrefabInternal: {fileID: 0}
80 | m_GameObject: {fileID: 0}
81 | m_Enabled: 1
82 | m_EditorHideFlags: 1
83 | m_Script: {fileID: 12008, guid: 0000000000000000e000000000000000, type: 0}
84 | m_Name:
85 | m_EditorClassIdentifier:
86 | m_Children:
87 | - {fileID: 5}
88 | - {fileID: 6}
89 | - {fileID: 7}
90 | m_Position:
91 | serializedVersion: 2
92 | x: 0
93 | y: 0
94 | width: 1991
95 | height: 1243
96 | m_MinSize: {x: 950, y: 300}
97 | m_MaxSize: {x: 10000, y: 10000}
98 | --- !u!114 &5
99 | MonoBehaviour:
100 | m_ObjectHideFlags: 52
101 | m_PrefabParentObject: {fileID: 0}
102 | m_PrefabInternal: {fileID: 0}
103 | m_GameObject: {fileID: 0}
104 | m_Enabled: 1
105 | m_EditorHideFlags: 1
106 | m_Script: {fileID: 12011, guid: 0000000000000000e000000000000000, type: 0}
107 | m_Name:
108 | m_EditorClassIdentifier:
109 | m_Children: []
110 | m_Position:
111 | serializedVersion: 2
112 | x: 0
113 | y: 0
114 | width: 1991
115 | height: 30
116 | m_MinSize: {x: 0, y: 0}
117 | m_MaxSize: {x: 0, y: 0}
118 | m_LastLoadedLayoutName:
119 | --- !u!114 &6
120 | MonoBehaviour:
121 | m_ObjectHideFlags: 52
122 | m_PrefabParentObject: {fileID: 0}
123 | m_PrefabInternal: {fileID: 0}
124 | m_GameObject: {fileID: 0}
125 | m_Enabled: 1
126 | m_EditorHideFlags: 1
127 | m_Script: {fileID: 12010, guid: 0000000000000000e000000000000000, type: 0}
128 | m_Name:
129 | m_EditorClassIdentifier:
130 | m_Children:
131 | - {fileID: 2}
132 | - {fileID: 8}
133 | - {fileID: 9}
134 | - {fileID: 10}
135 | m_Position:
136 | serializedVersion: 2
137 | x: 0
138 | y: 30
139 | width: 1991
140 | height: 1193
141 | m_MinSize: {x: 917, y: 563}
142 | m_MaxSize: {x: 22012, y: 12063}
143 | vertical: 0
144 | controlID: 144
145 | --- !u!114 &7
146 | MonoBehaviour:
147 | m_ObjectHideFlags: 52
148 | m_PrefabParentObject: {fileID: 0}
149 | m_PrefabInternal: {fileID: 0}
150 | m_GameObject: {fileID: 0}
151 | m_Enabled: 1
152 | m_EditorHideFlags: 1
153 | m_Script: {fileID: 12042, guid: 0000000000000000e000000000000000, type: 0}
154 | m_Name:
155 | m_EditorClassIdentifier:
156 | m_Children: []
157 | m_Position:
158 | serializedVersion: 2
159 | x: 0
160 | y: 1223
161 | width: 1991
162 | height: 20
163 | m_MinSize: {x: 0, y: 0}
164 | m_MaxSize: {x: 0, y: 0}
165 | --- !u!114 &8
166 | MonoBehaviour:
167 | m_ObjectHideFlags: 52
168 | m_PrefabParentObject: {fileID: 0}
169 | m_PrefabInternal: {fileID: 0}
170 | m_GameObject: {fileID: 0}
171 | m_Enabled: 1
172 | m_EditorHideFlags: 1
173 | m_Script: {fileID: 12010, guid: 0000000000000000e000000000000000, type: 0}
174 | m_Name:
175 | m_EditorClassIdentifier:
176 | m_Children:
177 | - {fileID: 11}
178 | - {fileID: 12}
179 | - {fileID: 3}
180 | m_Position:
181 | serializedVersion: 2
182 | x: 231
183 | y: 0
184 | width: 844
185 | height: 1193
186 | m_MinSize: {x: 204, y: 563}
187 | m_MaxSize: {x: 4004, y: 12063}
188 | vertical: 1
189 | controlID: 145
190 | --- !u!114 &9
191 | MonoBehaviour:
192 | m_ObjectHideFlags: 52
193 | m_PrefabParentObject: {fileID: 0}
194 | m_PrefabInternal: {fileID: 0}
195 | m_GameObject: {fileID: 0}
196 | m_Enabled: 1
197 | m_EditorHideFlags: 1
198 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0}
199 | m_Name:
200 | m_EditorClassIdentifier:
201 | m_Children: []
202 | m_Position:
203 | serializedVersion: 2
204 | x: 1075
205 | y: 0
206 | width: 471
207 | height: 1193
208 | m_MinSize: {x: 234, y: 271}
209 | m_MaxSize: {x: 10004, y: 10021}
210 | m_ActualView: {fileID: 16}
211 | m_Panes:
212 | - {fileID: 16}
213 | m_Selected: 0
214 | m_LastSelected: 0
215 | --- !u!114 &10
216 | MonoBehaviour:
217 | m_ObjectHideFlags: 52
218 | m_PrefabParentObject: {fileID: 0}
219 | m_PrefabInternal: {fileID: 0}
220 | m_GameObject: {fileID: 0}
221 | m_Enabled: 1
222 | m_EditorHideFlags: 1
223 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0}
224 | m_Name:
225 | m_EditorClassIdentifier:
226 | m_Children: []
227 | m_Position:
228 | serializedVersion: 2
229 | x: 1546
230 | y: 0
231 | width: 445
232 | height: 1193
233 | m_MinSize: {x: 277, y: 71}
234 | m_MaxSize: {x: 4002, y: 4021}
235 | m_ActualView: {fileID: 15}
236 | m_Panes:
237 | - {fileID: 15}
238 | m_Selected: 0
239 | m_LastSelected: 0
240 | --- !u!114 &11
241 | MonoBehaviour:
242 | m_ObjectHideFlags: 52
243 | m_PrefabParentObject: {fileID: 0}
244 | m_PrefabInternal: {fileID: 0}
245 | m_GameObject: {fileID: 0}
246 | m_Enabled: 1
247 | m_EditorHideFlags: 1
248 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0}
249 | m_Name:
250 | m_EditorClassIdentifier:
251 | m_Children: []
252 | m_Position:
253 | serializedVersion: 2
254 | x: 0
255 | y: 0
256 | width: 844
257 | height: 514
258 | m_MinSize: {x: 204, y: 221}
259 | m_MaxSize: {x: 4004, y: 4021}
260 | m_ActualView: {fileID: 18}
261 | m_Panes:
262 | - {fileID: 18}
263 | m_Selected: 0
264 | m_LastSelected: 0
265 | --- !u!114 &12
266 | MonoBehaviour:
267 | m_ObjectHideFlags: 52
268 | m_PrefabParentObject: {fileID: 0}
269 | m_PrefabInternal: {fileID: 0}
270 | m_GameObject: {fileID: 0}
271 | m_Enabled: 1
272 | m_EditorHideFlags: 1
273 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0}
274 | m_Name:
275 | m_EditorClassIdentifier:
276 | m_Children: []
277 | m_Position:
278 | serializedVersion: 2
279 | x: 0
280 | y: 514
281 | width: 844
282 | height: 429
283 | m_MinSize: {x: 204, y: 221}
284 | m_MaxSize: {x: 4004, y: 4021}
285 | m_ActualView: {fileID: 17}
286 | m_Panes:
287 | - {fileID: 17}
288 | m_Selected: 0
289 | m_LastSelected: 0
290 | --- !u!114 &13
291 | MonoBehaviour:
292 | m_ObjectHideFlags: 52
293 | m_PrefabParentObject: {fileID: 0}
294 | m_PrefabInternal: {fileID: 0}
295 | m_GameObject: {fileID: 0}
296 | m_Enabled: 1
297 | m_EditorHideFlags: 1
298 | m_Script: {fileID: 12003, guid: 0000000000000000e000000000000000, type: 0}
299 | m_Name:
300 | m_EditorClassIdentifier:
301 | m_AutoRepaintOnSceneChange: 0
302 | m_MinSize: {x: 100, y: 100}
303 | m_MaxSize: {x: 4000, y: 4000}
304 | m_TitleContent:
305 | m_Text: Console
306 | m_Image: {fileID: 111653112392082826, guid: 0000000000000000d000000000000000,
307 | type: 0}
308 | m_Tooltip:
309 | m_DepthBufferBits: 0
310 | m_Pos:
311 | serializedVersion: 2
312 | x: 621
313 | y: 1156
314 | width: 840
315 | height: 229
316 | m_PersistentViewDataDictionary: {fileID: 0}
317 | --- !u!114 &14
318 | MonoBehaviour:
319 | m_ObjectHideFlags: 52
320 | m_PrefabParentObject: {fileID: 0}
321 | m_PrefabInternal: {fileID: 0}
322 | m_GameObject: {fileID: 0}
323 | m_Enabled: 1
324 | m_EditorHideFlags: 1
325 | m_Script: {fileID: 12061, guid: 0000000000000000e000000000000000, type: 0}
326 | m_Name:
327 | m_EditorClassIdentifier:
328 | m_AutoRepaintOnSceneChange: 0
329 | m_MinSize: {x: 200, y: 200}
330 | m_MaxSize: {x: 4000, y: 4000}
331 | m_TitleContent:
332 | m_Text: Hierarchy
333 | m_Image: {fileID: -590624980919486359, guid: 0000000000000000d000000000000000,
334 | type: 0}
335 | m_Tooltip:
336 | m_DepthBufferBits: 0
337 | m_Pos:
338 | serializedVersion: 2
339 | x: 388
340 | y: 213
341 | width: 229
342 | height: 1172
343 | m_PersistentViewDataDictionary: {fileID: 0}
344 | m_TreeViewState:
345 | scrollPos: {x: 0, y: 0}
346 | m_SelectedIDs: 644c0000
347 | m_LastClickedID: 19556
348 | m_ExpandedIDs: 5c1affff1a37ffff863cffff6443fffffc47ffffec52ffff4262ffff82baffff38e3ffff0ee7ffffd2f6ffff000000008c2b0000e6330000f03300000a350000523700005c370000ee4b0000fa4b0000
349 | m_RenameOverlay:
350 | m_UserAcceptedRename: 0
351 | m_Name:
352 | m_OriginalName:
353 | m_EditFieldRect:
354 | serializedVersion: 2
355 | x: 0
356 | y: 0
357 | width: 0
358 | height: 0
359 | m_UserData: 0
360 | m_IsWaitingForDelay: 0
361 | m_IsRenaming: 0
362 | m_OriginalEventType: 11
363 | m_IsRenamingFilename: 0
364 | m_ClientGUIView: {fileID: 2}
365 | m_SearchString:
366 | m_ExpandedScenes:
367 | - Chapter07
368 | m_CurrenRootInstanceID: 0
369 | m_Locked: 0
370 | m_CurrentSortingName: TransformSorting
371 | --- !u!114 &15
372 | MonoBehaviour:
373 | m_ObjectHideFlags: 52
374 | m_PrefabParentObject: {fileID: 0}
375 | m_PrefabInternal: {fileID: 0}
376 | m_GameObject: {fileID: 0}
377 | m_Enabled: 1
378 | m_EditorHideFlags: 1
379 | m_Script: {fileID: 12019, guid: 0000000000000000e000000000000000, type: 0}
380 | m_Name:
381 | m_EditorClassIdentifier:
382 | m_AutoRepaintOnSceneChange: 0
383 | m_MinSize: {x: 275, y: 50}
384 | m_MaxSize: {x: 4000, y: 4000}
385 | m_TitleContent:
386 | m_Text: Inspector
387 | m_Image: {fileID: -6905738622615590433, guid: 0000000000000000d000000000000000,
388 | type: 0}
389 | m_Tooltip:
390 | m_DepthBufferBits: 0
391 | m_Pos:
392 | serializedVersion: 2
393 | x: 1936
394 | y: 213
395 | width: 443
396 | height: 1172
397 | m_PersistentViewDataDictionary: {fileID: 0}
398 | m_ScrollPosition: {x: 0, y: 0}
399 | m_InspectorMode: 0
400 | m_PreviewResizer:
401 | m_CachedPref: 317
402 | m_ControlHash: -371814159
403 | m_PrefName: Preview_InspectorPreview
404 | m_PreviewWindow: {fileID: 0}
405 | --- !u!114 &16
406 | MonoBehaviour:
407 | m_ObjectHideFlags: 52
408 | m_PrefabParentObject: {fileID: 0}
409 | m_PrefabInternal: {fileID: 0}
410 | m_GameObject: {fileID: 0}
411 | m_Enabled: 1
412 | m_EditorHideFlags: 1
413 | m_Script: {fileID: 12014, guid: 0000000000000000e000000000000000, type: 0}
414 | m_Name:
415 | m_EditorClassIdentifier:
416 | m_AutoRepaintOnSceneChange: 0
417 | m_MinSize: {x: 230, y: 250}
418 | m_MaxSize: {x: 10000, y: 10000}
419 | m_TitleContent:
420 | m_Text: Project
421 | m_Image: {fileID: -7501376956915960154, guid: 0000000000000000d000000000000000,
422 | type: 0}
423 | m_Tooltip:
424 | m_DepthBufferBits: 0
425 | m_Pos:
426 | serializedVersion: 2
427 | x: 1465
428 | y: 213
429 | width: 467
430 | height: 1172
431 | m_PersistentViewDataDictionary: {fileID: 0}
432 | m_SearchFilter:
433 | m_NameFilter:
434 | m_ClassNames: []
435 | m_AssetLabels: []
436 | m_AssetBundleNames: []
437 | m_VersionControlStates: []
438 | m_SoftLockControlStates: []
439 | m_ReferencingInstanceIDs:
440 | m_ScenePaths: []
441 | m_ShowAllHits: 0
442 | m_SearchArea: 0
443 | m_Folders:
444 | - Assets/Scripts
445 | m_ViewMode: 1
446 | m_StartGridSize: 64
447 | m_LastFolders:
448 | - Assets/Scripts
449 | m_LastFoldersGridSize: -1
450 | m_LastProjectPath: E:\program\src\mobile_game_math_unity\sample
451 | m_IsLocked: 0
452 | m_FolderTreeState:
453 | scrollPos: {x: 0, y: 0}
454 | m_SelectedIDs: 6e2a0000
455 | m_LastClickedID: 10862
456 | m_ExpandedIDs: 000000003c2a000000ca9a3bffffff7f
457 | m_RenameOverlay:
458 | m_UserAcceptedRename: 0
459 | m_Name:
460 | m_OriginalName:
461 | m_EditFieldRect:
462 | serializedVersion: 2
463 | x: 0
464 | y: 0
465 | width: 0
466 | height: 0
467 | m_UserData: 0
468 | m_IsWaitingForDelay: 0
469 | m_IsRenaming: 0
470 | m_OriginalEventType: 11
471 | m_IsRenamingFilename: 1
472 | m_ClientGUIView: {fileID: 0}
473 | m_SearchString:
474 | m_CreateAssetUtility:
475 | m_EndAction: {fileID: 0}
476 | m_InstanceID: 0
477 | m_Path:
478 | m_Icon: {fileID: 0}
479 | m_ResourceFile:
480 | m_AssetTreeState:
481 | scrollPos: {x: 0, y: 0}
482 | m_SelectedIDs:
483 | m_LastClickedID: 0
484 | m_ExpandedIDs: 000000003c2a0000
485 | m_RenameOverlay:
486 | m_UserAcceptedRename: 0
487 | m_Name:
488 | m_OriginalName:
489 | m_EditFieldRect:
490 | serializedVersion: 2
491 | x: 0
492 | y: 0
493 | width: 0
494 | height: 0
495 | m_UserData: 0
496 | m_IsWaitingForDelay: 0
497 | m_IsRenaming: 0
498 | m_OriginalEventType: 11
499 | m_IsRenamingFilename: 1
500 | m_ClientGUIView: {fileID: 0}
501 | m_SearchString:
502 | m_CreateAssetUtility:
503 | m_EndAction: {fileID: 0}
504 | m_InstanceID: 0
505 | m_Path:
506 | m_Icon: {fileID: 0}
507 | m_ResourceFile:
508 | m_ListAreaState:
509 | m_SelectedInstanceIDs:
510 | m_LastClickedInstanceID: 0
511 | m_HadKeyboardFocusLastEvent: 1
512 | m_ExpandedInstanceIDs: 54250000
513 | m_RenameOverlay:
514 | m_UserAcceptedRename: 0
515 | m_Name:
516 | m_OriginalName:
517 | m_EditFieldRect:
518 | serializedVersion: 2
519 | x: 0
520 | y: 0
521 | width: 0
522 | height: 0
523 | m_UserData: 0
524 | m_IsWaitingForDelay: 0
525 | m_IsRenaming: 0
526 | m_OriginalEventType: 11
527 | m_IsRenamingFilename: 1
528 | m_ClientGUIView: {fileID: 0}
529 | m_CreateAssetUtility:
530 | m_EndAction: {fileID: 0}
531 | m_InstanceID: 0
532 | m_Path:
533 | m_Icon: {fileID: 0}
534 | m_ResourceFile:
535 | m_NewAssetIndexInList: -1
536 | m_ScrollPosition: {x: 0, y: 0}
537 | m_GridSize: 64
538 | m_DirectoriesAreaWidth: 115
539 | --- !u!114 &17
540 | MonoBehaviour:
541 | m_ObjectHideFlags: 52
542 | m_PrefabParentObject: {fileID: 0}
543 | m_PrefabInternal: {fileID: 0}
544 | m_GameObject: {fileID: 0}
545 | m_Enabled: 1
546 | m_EditorHideFlags: 1
547 | m_Script: {fileID: 12015, guid: 0000000000000000e000000000000000, type: 0}
548 | m_Name:
549 | m_EditorClassIdentifier:
550 | m_AutoRepaintOnSceneChange: 1
551 | m_MinSize: {x: 200, y: 200}
552 | m_MaxSize: {x: 4000, y: 4000}
553 | m_TitleContent:
554 | m_Text: Game
555 | m_Image: {fileID: -2087823869225018852, guid: 0000000000000000d000000000000000,
556 | type: 0}
557 | m_Tooltip:
558 | m_DepthBufferBits: 32
559 | m_Pos:
560 | serializedVersion: 2
561 | x: 621
562 | y: 727
563 | width: 840
564 | height: 408
565 | m_PersistentViewDataDictionary: {fileID: 0}
566 | m_MaximizeOnPlay: 0
567 | m_Gizmos: 0
568 | m_Stats: 0
569 | m_SelectedSizes: 00000000000000000000000000000000000000000000000000000000000000000000000000000000
570 | m_TargetDisplay: 0
571 | m_ZoomArea:
572 | m_HRangeLocked: 0
573 | m_VRangeLocked: 0
574 | m_HBaseRangeMin: -420
575 | m_HBaseRangeMax: 420
576 | m_VBaseRangeMin: -195.5
577 | m_VBaseRangeMax: 195.5
578 | m_HAllowExceedBaseRangeMin: 1
579 | m_HAllowExceedBaseRangeMax: 1
580 | m_VAllowExceedBaseRangeMin: 1
581 | m_VAllowExceedBaseRangeMax: 1
582 | m_ScaleWithWindow: 0
583 | m_HSlider: 0
584 | m_VSlider: 0
585 | m_IgnoreScrollWheelUntilClicked: 0
586 | m_EnableMouseInput: 0
587 | m_EnableSliderZoom: 0
588 | m_UniformScale: 1
589 | m_UpDirection: 1
590 | m_DrawArea:
591 | serializedVersion: 2
592 | x: 0
593 | y: 17
594 | width: 840
595 | height: 391
596 | m_Scale: {x: 1, y: 1}
597 | m_Translation: {x: 420, y: 195.5}
598 | m_MarginLeft: 0
599 | m_MarginRight: 0
600 | m_MarginTop: 0
601 | m_MarginBottom: 0
602 | m_LastShownAreaInsideMargins:
603 | serializedVersion: 2
604 | x: -420
605 | y: -195.5
606 | width: 840
607 | height: 391
608 | m_MinimalGUI: 1
609 | m_defaultScale: 1
610 | m_TargetTexture: {fileID: 0}
611 | m_CurrentColorSpace: 0
612 | m_LastWindowPixelSize: {x: 840, y: 408}
613 | m_ClearInEditMode: 1
614 | m_NoCameraWarning: 1
615 | m_LowResolutionForAspectRatios: 01000000000100000100
616 | --- !u!114 &18
617 | MonoBehaviour:
618 | m_ObjectHideFlags: 52
619 | m_PrefabParentObject: {fileID: 0}
620 | m_PrefabInternal: {fileID: 0}
621 | m_GameObject: {fileID: 0}
622 | m_Enabled: 1
623 | m_EditorHideFlags: 1
624 | m_Script: {fileID: 12013, guid: 0000000000000000e000000000000000, type: 0}
625 | m_Name:
626 | m_EditorClassIdentifier:
627 | m_AutoRepaintOnSceneChange: 1
628 | m_MinSize: {x: 200, y: 200}
629 | m_MaxSize: {x: 4000, y: 4000}
630 | m_TitleContent:
631 | m_Text: Scene
632 | m_Image: {fileID: 2318424515335265636, guid: 0000000000000000d000000000000000,
633 | type: 0}
634 | m_Tooltip:
635 | m_DepthBufferBits: 32
636 | m_Pos:
637 | serializedVersion: 2
638 | x: 621
639 | y: 213
640 | width: 840
641 | height: 493
642 | m_PersistentViewDataDictionary: {fileID: 0}
643 | m_SceneLighting: 1
644 | lastFramingTime: 0
645 | m_2DMode: 0
646 | m_isRotationLocked: 0
647 | m_AudioPlay: 0
648 | m_Position:
649 | m_Target: {x: 2.7484393, y: 7.008835, z: -5.5089884}
650 | speed: 2
651 | m_Value: {x: 2.7484393, y: 7.008835, z: -5.5089884}
652 | m_RenderMode: 0
653 | m_ValidateTrueMetals: 0
654 | m_SceneViewState:
655 | showFog: 1
656 | showMaterialUpdate: 0
657 | showSkybox: 1
658 | showFlares: 1
659 | showImageEffects: 1
660 | showParticleSystems: 1
661 | grid:
662 | xGrid:
663 | m_Target: 0
664 | speed: 2
665 | m_Value: 0
666 | yGrid:
667 | m_Target: 1
668 | speed: 2
669 | m_Value: 1
670 | zGrid:
671 | m_Target: 0
672 | speed: 2
673 | m_Value: 0
674 | m_Rotation:
675 | m_Target: {x: -0.19092011, y: 0.26285782, z: -0.053147145, w: -0.944262}
676 | speed: 2
677 | m_Value: {x: -0.19092011, y: 0.26285782, z: -0.053147145, w: -0.944262}
678 | m_Size:
679 | m_Target: 4.9759026
680 | speed: 2
681 | m_Value: 4.9759026
682 | m_Ortho:
683 | m_Target: 0
684 | speed: 2
685 | m_Value: 0
686 | m_ShowGlobalGrid: 1
687 | m_LastSceneViewRotation: {x: 0, y: 0, z: 0, w: -0.99999994}
688 | m_LastSceneViewOrtho: 0
689 | m_ReplacementShader: {fileID: 0}
690 | m_ReplacementString:
691 | m_LastLockedObject: {fileID: 0}
692 | m_ViewIsLockedToObject: 0
693 |
--------------------------------------------------------------------------------
/sample/Library/CurrentMaximizeLayout.dwlt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/CurrentMaximizeLayout.dwlt
--------------------------------------------------------------------------------
/sample/Library/EditorUserBuildSettings.asset:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/EditorUserBuildSettings.asset
--------------------------------------------------------------------------------
/sample/Library/EditorUserSettings.asset:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/EditorUserSettings.asset
--------------------------------------------------------------------------------
/sample/Library/InspectorExpandedItems.asset:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/InspectorExpandedItems.asset
--------------------------------------------------------------------------------
/sample/Library/LastSceneManagerSetup.txt:
--------------------------------------------------------------------------------
1 | sceneSetups:
2 | - path: Assets/Scenes/Main.unity
3 | isLoaded: 1
4 | isActive: 1
5 |
--------------------------------------------------------------------------------
/sample/Library/LibraryFormatVersion.txt:
--------------------------------------------------------------------------------
1 | unityRebuildLibraryVersion: 11
2 | unityForwardCompatibleVersion: 40
3 |
--------------------------------------------------------------------------------
/sample/Library/MonoManager.asset:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/MonoManager.asset
--------------------------------------------------------------------------------
/sample/Library/SpriteAtlasDatabase.asset:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/SpriteAtlasDatabase.asset
--------------------------------------------------------------------------------
/sample/Library/TilemapEditorUserSettings.asset:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/TilemapEditorUserSettings.asset
--------------------------------------------------------------------------------
/sample/Library/expandedItems:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ryukbk/mobile_game_math_unity/7d461cee79ab3a141a887047723af1e4e8ced9cd/sample/Library/expandedItems
--------------------------------------------------------------------------------
/sample/ProjectSettings/AudioManager.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!11 &1
4 | AudioManager:
5 | m_ObjectHideFlags: 0
6 | m_Volume: 1
7 | Rolloff Scale: 1
8 | Doppler Factor: 1
9 | Default Speaker Mode: 2
10 | m_SampleRate: 0
11 | m_DSPBufferSize: 0
12 | m_VirtualVoiceCount: 512
13 | m_RealVoiceCount: 32
14 | m_DisableAudio: 0
15 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/ClusterInputManager.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!236 &1
4 | ClusterInputManager:
5 | m_ObjectHideFlags: 0
6 | m_Inputs: []
7 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/DynamicsManager.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!55 &1
4 | PhysicsManager:
5 | m_ObjectHideFlags: 0
6 | m_Gravity: {x: 0, y: -9.81000042, z: 0}
7 | m_DefaultMaterial: {fileID: 0}
8 | m_BounceThreshold: 2
9 | m_SleepThreshold: .00499999989
10 | m_DefaultContactOffset: .00999999978
11 | m_SolverIterationCount: 6
12 | m_RaycastsHitTriggers: 1
13 | m_EnableAdaptiveForce: 0
14 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
15 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/EditorBuildSettings.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!1045 &1
4 | EditorBuildSettings:
5 | m_ObjectHideFlags: 0
6 | serializedVersion: 2
7 | m_Scenes:
8 | - enabled: 1
9 | path: Assets/Scenes/Main.unity
10 | - enabled: 1
11 | path: Assets/Scenes/Chapter01.unity
12 | - enabled: 1
13 | path: Assets/Scenes/Chapter02.unity
14 | - enabled: 1
15 | path: Assets/Scenes/Chapter03.unity
16 | - enabled: 1
17 | path: Assets/Scenes/Chapter04.unity
18 | - enabled: 1
19 | path: Assets/Scenes/Chapter05.unity
20 | - enabled: 1
21 | path: Assets/Scenes/Chapter06.unity
22 | - enabled: 1
23 | path: Assets/Scenes/Chapter07.unity
24 | - enabled: 1
25 | path: Assets/Scenes/Chapter09.unity
26 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/EditorSettings.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!159 &1
4 | EditorSettings:
5 | m_ObjectHideFlags: 0
6 | serializedVersion: 3
7 | m_ExternalVersionControlSupport: Visible Meta Files
8 | m_SerializationMode: 2
9 | m_WebSecurityEmulationEnabled: 0
10 | m_WebSecurityEmulationHostUrl: http://www.mydomain.com/mygame.unity3d
11 | m_DefaultBehaviorMode: 0
12 | m_SpritePackerMode: 2
13 | m_SpritePackerPaddingPower: 1
14 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/GraphicsSettings.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!30 &1
4 | GraphicsSettings:
5 | m_ObjectHideFlags: 0
6 | serializedVersion: 9
7 | m_Deferred:
8 | m_Mode: 1
9 | m_Shader: {fileID: 69, guid: 0000000000000000f000000000000000, type: 0}
10 | m_DeferredReflections:
11 | m_Mode: 1
12 | m_Shader: {fileID: 74, guid: 0000000000000000f000000000000000, type: 0}
13 | m_ScreenSpaceShadows:
14 | m_Mode: 1
15 | m_Shader: {fileID: 64, guid: 0000000000000000f000000000000000, type: 0}
16 | m_LegacyDeferred:
17 | m_Mode: 1
18 | m_Shader: {fileID: 63, guid: 0000000000000000f000000000000000, type: 0}
19 | m_DepthNormals:
20 | m_Mode: 1
21 | m_Shader: {fileID: 62, guid: 0000000000000000f000000000000000, type: 0}
22 | m_MotionVectors:
23 | m_Mode: 1
24 | m_Shader: {fileID: 75, guid: 0000000000000000f000000000000000, type: 0}
25 | m_LightHalo:
26 | m_Mode: 1
27 | m_Shader: {fileID: 105, guid: 0000000000000000f000000000000000, type: 0}
28 | m_LensFlare:
29 | m_Mode: 1
30 | m_Shader: {fileID: 102, guid: 0000000000000000f000000000000000, type: 0}
31 | m_AlwaysIncludedShaders:
32 | - {fileID: 7, guid: 0000000000000000f000000000000000, type: 0}
33 | - {fileID: 15104, guid: 0000000000000000f000000000000000, type: 0}
34 | - {fileID: 15105, guid: 0000000000000000f000000000000000, type: 0}
35 | - {fileID: 15106, guid: 0000000000000000f000000000000000, type: 0}
36 | - {fileID: 10770, guid: 0000000000000000f000000000000000, type: 0}
37 | - {fileID: 10782, guid: 0000000000000000f000000000000000, type: 0}
38 | m_PreloadedShaders: []
39 | m_SpritesDefaultMaterial: {fileID: 10754, guid: 0000000000000000f000000000000000,
40 | type: 0}
41 | m_TierSettings_Tier1:
42 | renderingPath: 1
43 | useCascadedShadowMaps: 1
44 | m_TierSettings_Tier2:
45 | renderingPath: 1
46 | useCascadedShadowMaps: 1
47 | m_TierSettings_Tier3:
48 | renderingPath: 1
49 | useCascadedShadowMaps: 1
50 | m_DefaultRenderingPath: 1
51 | m_DefaultMobileRenderingPath: 1
52 | m_TierSettings: []
53 | m_LightmapStripping: 0
54 | m_FogStripping: 0
55 | m_LightmapKeepPlain: 1
56 | m_LightmapKeepDirCombined: 1
57 | m_LightmapKeepDirSeparate: 1
58 | m_LightmapKeepDynamicPlain: 1
59 | m_LightmapKeepDynamicDirCombined: 1
60 | m_LightmapKeepDynamicDirSeparate: 1
61 | m_FogKeepLinear: 1
62 | m_FogKeepExp: 1
63 | m_FogKeepExp2: 1
64 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/InputManager.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!13 &1
4 | InputManager:
5 | m_ObjectHideFlags: 0
6 | serializedVersion: 2
7 | m_Axes:
8 | - serializedVersion: 3
9 | m_Name: Horizontal
10 | descriptiveName:
11 | descriptiveNegativeName:
12 | negativeButton: left
13 | positiveButton: right
14 | altNegativeButton: a
15 | altPositiveButton: d
16 | gravity: 3
17 | dead: .00100000005
18 | sensitivity: 3
19 | snap: 1
20 | invert: 0
21 | type: 0
22 | axis: 0
23 | joyNum: 0
24 | - serializedVersion: 3
25 | m_Name: Vertical
26 | descriptiveName:
27 | descriptiveNegativeName:
28 | negativeButton: down
29 | positiveButton: up
30 | altNegativeButton: s
31 | altPositiveButton: w
32 | gravity: 3
33 | dead: .00100000005
34 | sensitivity: 3
35 | snap: 1
36 | invert: 0
37 | type: 0
38 | axis: 0
39 | joyNum: 0
40 | - serializedVersion: 3
41 | m_Name: Fire1
42 | descriptiveName:
43 | descriptiveNegativeName:
44 | negativeButton:
45 | positiveButton: left ctrl
46 | altNegativeButton:
47 | altPositiveButton: mouse 0
48 | gravity: 1000
49 | dead: .00100000005
50 | sensitivity: 1000
51 | snap: 0
52 | invert: 0
53 | type: 0
54 | axis: 0
55 | joyNum: 0
56 | - serializedVersion: 3
57 | m_Name: Fire2
58 | descriptiveName:
59 | descriptiveNegativeName:
60 | negativeButton:
61 | positiveButton: left alt
62 | altNegativeButton:
63 | altPositiveButton: mouse 1
64 | gravity: 1000
65 | dead: .00100000005
66 | sensitivity: 1000
67 | snap: 0
68 | invert: 0
69 | type: 0
70 | axis: 0
71 | joyNum: 0
72 | - serializedVersion: 3
73 | m_Name: Fire3
74 | descriptiveName:
75 | descriptiveNegativeName:
76 | negativeButton:
77 | positiveButton: left cmd
78 | altNegativeButton:
79 | altPositiveButton: mouse 2
80 | gravity: 1000
81 | dead: .00100000005
82 | sensitivity: 1000
83 | snap: 0
84 | invert: 0
85 | type: 0
86 | axis: 0
87 | joyNum: 0
88 | - serializedVersion: 3
89 | m_Name: Jump
90 | descriptiveName:
91 | descriptiveNegativeName:
92 | negativeButton:
93 | positiveButton: space
94 | altNegativeButton:
95 | altPositiveButton:
96 | gravity: 1000
97 | dead: .00100000005
98 | sensitivity: 1000
99 | snap: 0
100 | invert: 0
101 | type: 0
102 | axis: 0
103 | joyNum: 0
104 | - serializedVersion: 3
105 | m_Name: Mouse X
106 | descriptiveName:
107 | descriptiveNegativeName:
108 | negativeButton:
109 | positiveButton:
110 | altNegativeButton:
111 | altPositiveButton:
112 | gravity: 0
113 | dead: 0
114 | sensitivity: .100000001
115 | snap: 0
116 | invert: 0
117 | type: 1
118 | axis: 0
119 | joyNum: 0
120 | - serializedVersion: 3
121 | m_Name: Mouse Y
122 | descriptiveName:
123 | descriptiveNegativeName:
124 | negativeButton:
125 | positiveButton:
126 | altNegativeButton:
127 | altPositiveButton:
128 | gravity: 0
129 | dead: 0
130 | sensitivity: .100000001
131 | snap: 0
132 | invert: 0
133 | type: 1
134 | axis: 1
135 | joyNum: 0
136 | - serializedVersion: 3
137 | m_Name: Mouse ScrollWheel
138 | descriptiveName:
139 | descriptiveNegativeName:
140 | negativeButton:
141 | positiveButton:
142 | altNegativeButton:
143 | altPositiveButton:
144 | gravity: 0
145 | dead: 0
146 | sensitivity: .100000001
147 | snap: 0
148 | invert: 0
149 | type: 1
150 | axis: 2
151 | joyNum: 0
152 | - serializedVersion: 3
153 | m_Name: Horizontal
154 | descriptiveName:
155 | descriptiveNegativeName:
156 | negativeButton:
157 | positiveButton:
158 | altNegativeButton:
159 | altPositiveButton:
160 | gravity: 0
161 | dead: .189999998
162 | sensitivity: 1
163 | snap: 0
164 | invert: 0
165 | type: 2
166 | axis: 0
167 | joyNum: 0
168 | - serializedVersion: 3
169 | m_Name: Vertical
170 | descriptiveName:
171 | descriptiveNegativeName:
172 | negativeButton:
173 | positiveButton:
174 | altNegativeButton:
175 | altPositiveButton:
176 | gravity: 0
177 | dead: .189999998
178 | sensitivity: 1
179 | snap: 0
180 | invert: 1
181 | type: 2
182 | axis: 1
183 | joyNum: 0
184 | - serializedVersion: 3
185 | m_Name: Fire1
186 | descriptiveName:
187 | descriptiveNegativeName:
188 | negativeButton:
189 | positiveButton: joystick button 0
190 | altNegativeButton:
191 | altPositiveButton:
192 | gravity: 1000
193 | dead: .00100000005
194 | sensitivity: 1000
195 | snap: 0
196 | invert: 0
197 | type: 0
198 | axis: 0
199 | joyNum: 0
200 | - serializedVersion: 3
201 | m_Name: Fire2
202 | descriptiveName:
203 | descriptiveNegativeName:
204 | negativeButton:
205 | positiveButton: joystick button 1
206 | altNegativeButton:
207 | altPositiveButton:
208 | gravity: 1000
209 | dead: .00100000005
210 | sensitivity: 1000
211 | snap: 0
212 | invert: 0
213 | type: 0
214 | axis: 0
215 | joyNum: 0
216 | - serializedVersion: 3
217 | m_Name: Fire3
218 | descriptiveName:
219 | descriptiveNegativeName:
220 | negativeButton:
221 | positiveButton: joystick button 2
222 | altNegativeButton:
223 | altPositiveButton:
224 | gravity: 1000
225 | dead: .00100000005
226 | sensitivity: 1000
227 | snap: 0
228 | invert: 0
229 | type: 0
230 | axis: 0
231 | joyNum: 0
232 | - serializedVersion: 3
233 | m_Name: Jump
234 | descriptiveName:
235 | descriptiveNegativeName:
236 | negativeButton:
237 | positiveButton: joystick button 3
238 | altNegativeButton:
239 | altPositiveButton:
240 | gravity: 1000
241 | dead: .00100000005
242 | sensitivity: 1000
243 | snap: 0
244 | invert: 0
245 | type: 0
246 | axis: 0
247 | joyNum: 0
248 | - serializedVersion: 3
249 | m_Name: Submit
250 | descriptiveName:
251 | descriptiveNegativeName:
252 | negativeButton:
253 | positiveButton: return
254 | altNegativeButton:
255 | altPositiveButton: joystick button 0
256 | gravity: 1000
257 | dead: .00100000005
258 | sensitivity: 1000
259 | snap: 0
260 | invert: 0
261 | type: 0
262 | axis: 0
263 | joyNum: 0
264 | - serializedVersion: 3
265 | m_Name: Submit
266 | descriptiveName:
267 | descriptiveNegativeName:
268 | negativeButton:
269 | positiveButton: enter
270 | altNegativeButton:
271 | altPositiveButton: space
272 | gravity: 1000
273 | dead: .00100000005
274 | sensitivity: 1000
275 | snap: 0
276 | invert: 0
277 | type: 0
278 | axis: 0
279 | joyNum: 0
280 | - serializedVersion: 3
281 | m_Name: Cancel
282 | descriptiveName:
283 | descriptiveNegativeName:
284 | negativeButton:
285 | positiveButton: escape
286 | altNegativeButton:
287 | altPositiveButton: joystick button 1
288 | gravity: 1000
289 | dead: .00100000005
290 | sensitivity: 1000
291 | snap: 0
292 | invert: 0
293 | type: 0
294 | axis: 0
295 | joyNum: 0
296 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/NavMeshAreas.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!126 &1
4 | NavMeshAreas:
5 | m_ObjectHideFlags: 0
6 | serializedVersion: 2
7 | areas:
8 | - name: Walkable
9 | cost: 1
10 | - name: Not Walkable
11 | cost: 1
12 | - name: Jump
13 | cost: 2
14 | - name:
15 | cost: 1
16 | - name:
17 | cost: 1
18 | - name:
19 | cost: 1
20 | - name:
21 | cost: 1
22 | - name:
23 | cost: 1
24 | - name:
25 | cost: 1
26 | - name:
27 | cost: 1
28 | - name:
29 | cost: 1
30 | - name:
31 | cost: 1
32 | - name:
33 | cost: 1
34 | - name:
35 | cost: 1
36 | - name:
37 | cost: 1
38 | - name:
39 | cost: 1
40 | - name:
41 | cost: 1
42 | - name:
43 | cost: 1
44 | - name:
45 | cost: 1
46 | - name:
47 | cost: 1
48 | - name:
49 | cost: 1
50 | - name:
51 | cost: 1
52 | - name:
53 | cost: 1
54 | - name:
55 | cost: 1
56 | - name:
57 | cost: 1
58 | - name:
59 | cost: 1
60 | - name:
61 | cost: 1
62 | - name:
63 | cost: 1
64 | - name:
65 | cost: 1
66 | - name:
67 | cost: 1
68 | - name:
69 | cost: 1
70 | - name:
71 | cost: 1
72 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/NetworkManager.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!149 &1
4 | NetworkManager:
5 | m_ObjectHideFlags: 0
6 | m_DebugLevel: 0
7 | m_Sendrate: 15
8 | m_AssetToPrefab: {}
9 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/Physics2DSettings.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!19 &1
4 | Physics2DSettings:
5 | m_ObjectHideFlags: 0
6 | m_Gravity: {x: 0, y: -9.81000042}
7 | m_DefaultMaterial: {fileID: 0}
8 | m_VelocityIterations: 8
9 | m_PositionIterations: 3
10 | m_VelocityThreshold: 1
11 | m_MaxLinearCorrection: .200000003
12 | m_MaxAngularCorrection: 8
13 | m_MaxTranslationSpeed: 100
14 | m_MaxRotationSpeed: 360
15 | m_MinPenetrationForPenalty: .00999999978
16 | m_BaumgarteScale: .200000003
17 | m_BaumgarteTimeOfImpactScale: .75
18 | m_TimeToSleep: .5
19 | m_LinearSleepTolerance: .00999999978
20 | m_AngularSleepTolerance: 2
21 | m_RaycastsHitTriggers: 1
22 | m_RaycastsStartInColliders: 1
23 | m_ChangeStopsCallbacks: 0
24 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
25 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/ProjectVersion.txt:
--------------------------------------------------------------------------------
1 | m_EditorVersion: 2017.3.1f1
2 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/QualitySettings.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!47 &1
4 | QualitySettings:
5 | m_ObjectHideFlags: 0
6 | serializedVersion: 5
7 | m_CurrentQuality: 5
8 | m_QualitySettings:
9 | - serializedVersion: 2
10 | name: Fastest
11 | pixelLightCount: 0
12 | shadows: 0
13 | shadowResolution: 0
14 | shadowProjection: 1
15 | shadowCascades: 1
16 | shadowDistance: 15
17 | shadowNearPlaneOffset: 2
18 | shadowCascade2Split: .333333343
19 | shadowCascade4Split: {x: .0666666701, y: .200000003, z: .466666669}
20 | blendWeights: 1
21 | textureQuality: 1
22 | anisotropicTextures: 0
23 | antiAliasing: 0
24 | softParticles: 0
25 | softVegetation: 0
26 | realtimeReflectionProbes: 0
27 | billboardsFaceCameraPosition: 0
28 | vSyncCount: 0
29 | lodBias: .300000012
30 | maximumLODLevel: 0
31 | particleRaycastBudget: 4
32 | excludedTargetPlatforms: []
33 | - serializedVersion: 2
34 | name: Fast
35 | pixelLightCount: 0
36 | shadows: 0
37 | shadowResolution: 0
38 | shadowProjection: 1
39 | shadowCascades: 1
40 | shadowDistance: 20
41 | shadowNearPlaneOffset: 2
42 | shadowCascade2Split: .333333343
43 | shadowCascade4Split: {x: .0666666701, y: .200000003, z: .466666669}
44 | blendWeights: 2
45 | textureQuality: 0
46 | anisotropicTextures: 0
47 | antiAliasing: 0
48 | softParticles: 0
49 | softVegetation: 0
50 | realtimeReflectionProbes: 0
51 | billboardsFaceCameraPosition: 0
52 | vSyncCount: 0
53 | lodBias: .400000006
54 | maximumLODLevel: 0
55 | particleRaycastBudget: 16
56 | excludedTargetPlatforms: []
57 | - serializedVersion: 2
58 | name: Simple
59 | pixelLightCount: 1
60 | shadows: 1
61 | shadowResolution: 0
62 | shadowProjection: 1
63 | shadowCascades: 1
64 | shadowDistance: 20
65 | shadowNearPlaneOffset: 2
66 | shadowCascade2Split: .333333343
67 | shadowCascade4Split: {x: .0666666701, y: .200000003, z: .466666669}
68 | blendWeights: 2
69 | textureQuality: 0
70 | anisotropicTextures: 1
71 | antiAliasing: 0
72 | softParticles: 0
73 | softVegetation: 0
74 | realtimeReflectionProbes: 0
75 | billboardsFaceCameraPosition: 0
76 | vSyncCount: 0
77 | lodBias: .699999988
78 | maximumLODLevel: 0
79 | particleRaycastBudget: 64
80 | excludedTargetPlatforms: []
81 | - serializedVersion: 2
82 | name: Good
83 | pixelLightCount: 2
84 | shadows: 2
85 | shadowResolution: 1
86 | shadowProjection: 1
87 | shadowCascades: 2
88 | shadowDistance: 40
89 | shadowNearPlaneOffset: 2
90 | shadowCascade2Split: .333333343
91 | shadowCascade4Split: {x: .0666666701, y: .200000003, z: .466666669}
92 | blendWeights: 2
93 | textureQuality: 0
94 | anisotropicTextures: 1
95 | antiAliasing: 0
96 | softParticles: 0
97 | softVegetation: 1
98 | realtimeReflectionProbes: 1
99 | billboardsFaceCameraPosition: 1
100 | vSyncCount: 1
101 | lodBias: 1
102 | maximumLODLevel: 0
103 | particleRaycastBudget: 256
104 | excludedTargetPlatforms: []
105 | - serializedVersion: 2
106 | name: Beautiful
107 | pixelLightCount: 3
108 | shadows: 2
109 | shadowResolution: 2
110 | shadowProjection: 1
111 | shadowCascades: 2
112 | shadowDistance: 70
113 | shadowNearPlaneOffset: 2
114 | shadowCascade2Split: .333333343
115 | shadowCascade4Split: {x: .0666666701, y: .200000003, z: .466666669}
116 | blendWeights: 4
117 | textureQuality: 0
118 | anisotropicTextures: 2
119 | antiAliasing: 2
120 | softParticles: 1
121 | softVegetation: 1
122 | realtimeReflectionProbes: 1
123 | billboardsFaceCameraPosition: 1
124 | vSyncCount: 1
125 | lodBias: 1.5
126 | maximumLODLevel: 0
127 | particleRaycastBudget: 1024
128 | excludedTargetPlatforms: []
129 | - serializedVersion: 2
130 | name: Fantastic
131 | pixelLightCount: 4
132 | shadows: 2
133 | shadowResolution: 2
134 | shadowProjection: 1
135 | shadowCascades: 4
136 | shadowDistance: 150
137 | shadowNearPlaneOffset: 2
138 | shadowCascade2Split: .333333343
139 | shadowCascade4Split: {x: .0666666701, y: .200000003, z: .466666669}
140 | blendWeights: 4
141 | textureQuality: 0
142 | anisotropicTextures: 2
143 | antiAliasing: 2
144 | softParticles: 1
145 | softVegetation: 1
146 | realtimeReflectionProbes: 1
147 | billboardsFaceCameraPosition: 1
148 | vSyncCount: 1
149 | lodBias: 2
150 | maximumLODLevel: 0
151 | particleRaycastBudget: 4096
152 | excludedTargetPlatforms: []
153 | m_PerPlatformDefaultQuality: {}
154 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/TagManager.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!78 &1
4 | TagManager:
5 | serializedVersion: 2
6 | tags: []
7 | layers:
8 | - Default
9 | - TransparentFX
10 | - Ignore Raycast
11 | -
12 | - Water
13 | - UI
14 | -
15 | -
16 | -
17 | -
18 | -
19 | -
20 | -
21 | -
22 | -
23 | -
24 | -
25 | -
26 | -
27 | -
28 | -
29 | -
30 | -
31 | -
32 | -
33 | -
34 | -
35 | -
36 | -
37 | -
38 | -
39 | -
40 | m_SortingLayers:
41 | - name: Default
42 | uniqueID: 0
43 | locked: 0
44 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/TimeManager.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!5 &1
4 | TimeManager:
5 | m_ObjectHideFlags: 0
6 | Fixed Timestep: .0199999996
7 | Maximum Allowed Timestep: .333333343
8 | m_TimeScale: 1
9 |
--------------------------------------------------------------------------------
/sample/ProjectSettings/UnityConnectSettings.asset:
--------------------------------------------------------------------------------
1 | %YAML 1.1
2 | %TAG !u! tag:unity3d.com,2011:
3 | --- !u!310 &1
4 | UnityConnectSettings:
5 | m_ObjectHideFlags: 0
6 | m_Enabled: 0
7 | m_TestMode: 0
8 | m_TestEventUrl:
9 | m_TestConfigUrl:
10 | CrashReportingSettings:
11 | m_EventUrl: https://perf-events.cloud.unity3d.com/api/events/crashes
12 | m_Enabled: 0
13 | m_CaptureEditorExceptions: 1
14 | UnityPurchasingSettings:
15 | m_Enabled: 0
16 | m_TestMode: 0
17 | UnityAnalyticsSettings:
18 | m_Enabled: 0
19 | m_InitializeOnStartup: 1
20 | m_TestMode: 0
21 | m_TestEventUrl:
22 | m_TestConfigUrl:
23 | UnityAdsSettings:
24 | m_Enabled: 0
25 | m_InitializeOnStartup: 1
26 | m_TestMode: 0
27 | m_EnabledPlatforms: 4294967295
28 | m_IosGameId:
29 | m_AndroidGameId:
30 |
--------------------------------------------------------------------------------
/sample/UnityPackageManager/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "dependencies": {
3 | }
4 | }
5 |
--------------------------------------------------------------------------------