mirror of
https://github.com/vrm-c/UniVRM.git
synced 2026-08-06 01:39:41 -05:00
comment
This commit is contained in:
parent
bf73c96847
commit
2d5d3bb4d5
|
|
@ -14,6 +14,11 @@ namespace UniVRM10
|
|||
[CustomEditor(typeof(VrmScriptedImporter))]
|
||||
public class VrmScriptedImporterEditorGUI : ScriptedImporterEditor
|
||||
{
|
||||
// const string TextureDirName = "Textures";
|
||||
// const string MaterialDirName = "Materials";
|
||||
// const string MetaDirName = "MetaObjects";
|
||||
// const string ExpressionDirName = "Expressions";
|
||||
|
||||
VrmScriptedImporter m_importer;
|
||||
GltfParser m_parser;
|
||||
VrmLib.Model m_model;
|
||||
|
|
|
|||
|
|
@ -13,11 +13,12 @@ namespace UniVRM10
|
|||
{
|
||||
public static class VrmScriptedImporterImpl
|
||||
{
|
||||
// const string TextureDirName = "Textures";
|
||||
// const string MaterialDirName = "Materials";
|
||||
// const string MetaDirName = "MetaObjects";
|
||||
// const string ExpressionDirName = "Expressions";
|
||||
|
||||
/// <summary>
|
||||
/// VRM1 で パースし、失敗したら Migration してから VRM1 でパースする
|
||||
/// </summary>
|
||||
/// <param name="path"></param>
|
||||
/// <param name="migrateToVrm1"></param>
|
||||
/// <returns></returns>
|
||||
static GltfParser Parse(string path, bool migrateToVrm1)
|
||||
{
|
||||
//
|
||||
|
|
@ -85,60 +86,6 @@ namespace UniVRM10
|
|||
}
|
||||
}
|
||||
|
||||
// try
|
||||
// {
|
||||
// // Create Vrm Model
|
||||
// VrmLib.Model model = VrmLoader.CreateVrmModel(parser);
|
||||
// if (model == null)
|
||||
// {
|
||||
// // maybe VRM-0.X
|
||||
// return;
|
||||
// }
|
||||
// Debug.Log($"VrmLoader.CreateVrmModel: {model}");
|
||||
|
||||
// // Build Unity Model
|
||||
// var assets = EditorUnityBuilder.ToUnityAsset(model, assetPath, this);
|
||||
// ComponentBuilder.Build10(model, assets);
|
||||
|
||||
// // Texture
|
||||
// var externalTextures = this.GetExternalUnityObjects<UnityEngine.Texture2D>();
|
||||
// foreach (var texture in assets.Textures)
|
||||
// {
|
||||
// if (texture == null)
|
||||
// continue;
|
||||
|
||||
// if (externalTextures.ContainsValue(texture))
|
||||
// {
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// ctx.AddObjectToAsset(texture.name, texture);
|
||||
// }
|
||||
// }
|
||||
|
||||
// // Material
|
||||
// var externalMaterials = this.GetExternalUnityObjects<UnityEngine.Material>();
|
||||
// foreach (var material in assets.Materials)
|
||||
// {
|
||||
// if (material == null)
|
||||
// continue;
|
||||
|
||||
// if (externalMaterials.ContainsValue(material))
|
||||
// {
|
||||
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// ctx.AddObjectToAsset(material.name, material);
|
||||
// }
|
||||
// }
|
||||
|
||||
// // Mesh
|
||||
// foreach (var mesh in assets.Meshes)
|
||||
// {
|
||||
// ctx.AddObjectToAsset(mesh.name, mesh);
|
||||
// }
|
||||
|
||||
// //// ScriptableObject
|
||||
// // avatar
|
||||
// ctx.AddObjectToAsset("avatar", assets.HumanoidAvatar);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user