こんにちは、エンジニアのオオバです。

Unity2017.1.0が正式リリースして間もないですが、ベータバージョンは粛々と更新が入っています。
本記事ではオオバ個人が気になる修正内容をピックアップしています。

What's new in 2017.2.0 Beta 3 - Unity

👉DOTweenの教科書を読んでUnityアニメーションをプログラミングしてみよう!

Features

Asset Import: Added support for animated custom properties from FBX.

FBXからアニメーションさせたカスタムプロパティをインポート出来るようになったようです。

Editor: Added assembly definition files feature for script compilation pipeline in the editor. Allows you to define your own managed assemblies based upon scripts inside a folder. By splitting your project's scripts into multiple assemblies, script compilation times in the editor can be greatly reduced. Note that the latest version of Visual Studio Tools for Unity is required for this feature to work with solution and project generation for Visual Studio.

スクリプトコンパイルパイプライン用のアセンブリ定義ファイル機能をエディタに追加しました。フォルダ内のスクリプトに基づいて独自のマネージアセンブリを定義できます。プロジェクトのスクリプトを複数のアセンブリに分割することで、エディタでのスクリプトのコンパイル時間を大幅に短縮できます。

これはとても気になる追加機能です。Win環境整えたら試してみたいです。

OSX: Added support for Retina in macOS standalone builds.

レティナ対応macOS用アプリビルドがサポートされました。

Package Manager: In 2017.2, we are introducing Unity Package Manager. This will be the first stepping stone for the system. We are taking an incremental approach to integrate the system into the Unity ecosystem. It will grow with more features over time. For this first release, we avoid exposing user facing features. Instead, we are exposing an API for enabling internal components to be updated more frequently than the editor (the first pillar of the system).

2017.2では、Unity Package Managerを導入しています。これがシステムの最初の踏み台になるでしょう。システムをUnityエコシステムに統合するための段階的なアプローチをとっています。時間が経つにつれて、より多くの機能が増えていきます。この最初のリリースでは、ユーザーが直面する機能が公開されることはありません。代わりに、内部コンポーネントをエディタ(システムの最初の柱)よりも頻繁に更新できるようにするためのAPIを公開しています。

UnityEditor.PackageManagerパッケージが新規で追加されています。

Particles: Add new option to allow Particle Systems to be destroyed or disabled when they finish playing.

Unity2017.2.0b2b3の気になる更新_0

Particle SystemのメインモジュールにStop Actionというパーティクルが全て終了した際の挙動を設定できるようになりました。Destroyするか 非アクティブにするかです。
ただし非アクティブの場合、GameObjectが非アクティブになるので注意です。

Video: Added pixel aspect ratio support for non-square pixel.

非正方形ピクセルのビデオがサポートされました。

Changes

Android: Changed default frame rate (Application.targetFrameRate 0) to 30 when v-sync is off, similar to iOS.

v-syncがオフの時Androidのデフォルトフレームレートが0から30へ変更されました。

Audio: AudioMixer ducking improvements:
・Optimized CPU performance.
・Changed behaviour so that ducking amount corresponds to the maximum level on each channel.

CPU負荷、ダッキング量が各チャンネルの最大レベルに対応するという点でAudioMixerのダッキングが改善しました。

Scripting: UnityEngine.dll is now split into separate dlls for each UnityEngine module.

UnityEngine.dllがモジュールごとに分割されるようになりました。
詳細求む。

Scripting: MonoBehaviour.OnValidate is now called when adding a MonoBehaviour to a game object in the editor.

MonoBehaviourが追加されたときにもOnValidateが実行されるようになりました。

UI: The legacy (Unity 1.0) UI system components - GUILayer, GUIText, and GUITexture - have been marked as deprecated. GUILayer components are no longer added to the camera by default.

長い間お世話になったGUILayer, GUIText, GUITextureこれらのコンポーネントが非推奨になり、今後削除されることになりました。カメラコンポーネントには既に自動でGUILayerコンポーネントが付かなくなっています。

Improvements

Android: Significantly improved the performance of large prefabs loading (Resources.Load or AssetBundle.LoadAsset APIs) on Android.

Resource.LoadAssetBundle.LoadAssetにおいて巨大なプレファブのロードが顕著に改善されました。非常に気になる修正です。

Graphics: Frame Debugger Improvements:
・Size, format and depth in the texture shader properties tooltip.
・Stencil states.
・Subshader index, pass name and light mode tag.

フレームデバッガが改善したようです。
・テクスチャのサイズ、フォーマット、デプスがツールチップで表示
・ステンシル状態の表示
・SubShaderのindex, Pass, name, LightModeのタグ表示

これは非常にありがたいです。

Unity2017.2.0b2b3の気になる更新_1

ステンシルの情報がほら。

iOS: Generate Notification and Spotlight icons for iOS targets. Additionally [also mentioned under API Changes] modified the functions PlayerSettings.GetIconsForTargetGroup, PlayerSettings.GetIconSizesForTargetGroup and PlayerSettings.SetIconsForTargetGroup to take an optional IconKind parameter to get/set specific kinds of icons.

iOSにおいて通知、スポットライトアイコンを設定できるようになりました。

iOS: Implemented Xcode API for embedding frameworks.

Xcodeにフレームワークを埋め込むAPIが追加されました。

Kernel: Completion events added to all return AsyncOperations.

Unity - Scripting API: AsyncOperation

全てのAsyncOperationにcompletedというイベントが追加されました。

IEnumerator Start ()  
{
    ResourceRequest r = Resources.LoadAsync ("A");  
    r.completed += obj => {  
        Debug.Log ("完了1");  
    };  
    yield return r;  
    Debug.Log ("完了2");  
}

この場合、以下のように出力される

完了2  
完了1  

Particles: Burst Emission now supports curve modes for the count.

Particle SystemのEmissionモジュールが放出数をカーブで設定できるようになりました。

Unity2017.2.0b3

Unity2017.2.0b2b3の気になる更新_2

Unity2017.1.0f1

Unity2017.2.0b2b3の気になる更新_3

UI: Introduced a shader keyword to all of the UI shaders, which controls the rect clipping. Rect clipping is only done when the mask component is enabled. This leads to much better UI performance when masks are not used.

#pragma multi_compile __ UNITY_UI_CLIP_RECT

UIシェーダーにUNITY_UI_CLIP_RECTキーワードが追加されました。
マスクをマスクコンポーネント未使用時のみ矩形クリッピングが適用されます。これはマスクコンポーネントより非常に高速です。

まとめ

気になる修正を羅列しましたが、その中でも気になるのは以下です。

今回もリリースノートのFixesは言及対象にしていないので(毎回量が多いため)、オオバも別途目を通しておこうと思います。

オススメ記事
検証環境