mv SubAssetKey

This commit is contained in:
Masataka SUMI
2021-05-24 20:12:19 +09:00
parent ede6be174a
commit 9cd3288e4d
12 changed files with 41 additions and 8 deletions

View File

@@ -1,6 +1,7 @@
using System.Collections.Generic;
using System.Linq;
using UnityEditor;
using VRMShaders;
#if UNITY_2020_2_OR_NEWER
using UnityEditor.AssetImporters;
#else

View File

@@ -4,6 +4,7 @@ using System.Linq;
using UniGLTF;
using UnityEditor;
using UnityEngine;
using VRMShaders;
namespace VRM
{
@@ -70,7 +71,7 @@ namespace VRM
/// </summary>
public void ConvertAndExtractImages(Action<IEnumerable<UnityPath>> onTextureReloaded)
{
//
//
// convert images(metallic roughness, occlusion map)
//
var task = m_context.LoadMaterialsAsync();
@@ -112,7 +113,7 @@ namespace VRM
if (!string.IsNullOrEmpty(AssetDatabase.GetAssetPath(o)))
{
// already exists. not dispose
#if VRM_DEVELOP
#if VRM_DEVELOP
Debug.Log($"Loaded. skip: {o}");
#endif
return true;

View File

@@ -0,0 +1,18 @@
{
"name": "VRM10.Samples.Runtime",
"references": [
"UniGLTF",
"VRMShaders.GLTF.IO.Runtime",
"VRM10",
"UniHumanoid"
],
"includePlatforms": [],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": false,
"defineConstraints": [],
"versionDefines": [],
"noEngineReferences": false
}

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 25cb04f3bb4e1844d871da234c1dcc93
AssemblyDefinitionImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -3,6 +3,7 @@ using UnityEngine;
using System.Linq;
using System.IO;
using UnityEditor;
using VRMShaders;
#if UNITY_2020_2_OR_NEWER
using UnityEditor.AssetImporters;
#else

View File

@@ -4,6 +4,7 @@ using UniGLTF;
using System.IO;
using System;
using UniJSON;
using VRMShaders;
#if UNITY_2020_2_OR_NEWER
using UnityEditor.AssetImporters;
#else
@@ -39,7 +40,7 @@ namespace UniVRM10
return "vrm1 not found";
}
// try migrateion
// try migrateion
Byte[] migrated = default;
try
{

View File

@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using UniGLTF;
using VRMShaders;
namespace UniVRM10
{

View File

@@ -4,6 +4,7 @@ using System.Linq;
using MeshUtility;
using UniGLTF;
using UnityEngine;
using VRMShaders;
namespace UniVRM10

View File

@@ -5,6 +5,7 @@ using System.Threading.Tasks;
using UniGLTF;
using UnityEngine;
using VrmLib;
using VRMShaders;
namespace UniVRM10

View File

@@ -3,6 +3,7 @@ using System.Linq;
using NUnit.Framework;
using UniGLTF;
using UnityEngine;
using VRMShaders;
namespace UniVRM10
{

View File

@@ -1,21 +1,21 @@
using System;
using System.Collections.Generic;
namespace UniGLTF
namespace VRMShaders
{
/// <summary>
/// UnityEditor.Experimental.AssetImporter.SourceAssetIdentifier に対応する
///
///
/// * SourceAssetIdentifier が UnityEditor なので、 Runtime でも使えるように
/// * Type が違うが Name が同じだと警告が出る。例えば、Material と 同じ名前の Texture がある場合。
/// Identifier uniqueness violation: 'Alicia_body'. Scripted Importers do not guarantee that subsequent imports of this asset will properly re-link to these targets.
/// * なので、SourceAssetIdentifier は、$"{Type.Name}.{UnityObject.name}" のように強制的に Unique にするのが良さそう
/// * 一方で、Extract したファイル名に $"{Type.Name}." が付属するのは煩わしいのでこれは無しにしたい。
///
///
/// public void AddRemap(SourceAssetIdentifier identifier, UnityEngine.Object externalObject);
///
///
/// の呼び出し時に、identifier.name と externalObject.name が同じでない運用にしてみる。
///
///
/// </summary>
public struct SubAssetKey : IEquatable<SubAssetKey>
{