Skip to content

Commit

Permalink
Merge pull request #2478 from ousttrue/fix/remove_vrmlib
Browse files Browse the repository at this point in the history
[vrm10] vrmlib による mesh 処理を gltf/vrm0.x のものと同じものに
  • Loading branch information
ousttrue authored Nov 6, 2024
2 parents e16c286 + 95019c9 commit 129af09
Show file tree
Hide file tree
Showing 9 changed files with 69 additions and 679 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
using System.Linq;
using UniGLTF.Extensions.VRMC_vrm;
using UnityEngine;
using VrmLib;

namespace UniVRM10
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
using System;
using System.Collections.Generic;
using System.Linq;
using UnityEngine;
using VrmLib;

namespace UniVRM10
{
Expand Down
10 changes: 5 additions & 5 deletions Assets/VRM10/Runtime/IO/ExpressionExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ namespace UniVRM10
{
public static class ExpressionExtensions
{
public static MorphTargetBinding? Build10(this MorphTargetBind bind, GameObject root, Vrm10Importer.ModelMap loader, VrmLib.Model model)
public static MorphTargetBinding? Build10(this MorphTargetBind bind, GameObject root, Vrm10Importer importer)
{
if (bind.Node.TryGetValidIndex(model.Nodes.Count, out var nodeIndex))
if (bind.Node.TryGetValidIndex(importer.Nodes.Count, out var nodeIndex))
{
var libNode = model.Nodes[nodeIndex];
if (libNode.MeshGroup == null)
var node = importer.Nodes[nodeIndex];
var smr = node.GetComponent<SkinnedMeshRenderer>();
if (smr == null)
{
return default;
}
var node = loader.Nodes[libNode].transform;
var relativePath = node.RelativePathFrom(root.transform);
return new MorphTargetBinding(relativePath, bind.Index.Value, bind.Weight.Value);
}
Expand Down
307 changes: 0 additions & 307 deletions Assets/VRM10/Runtime/IO/Model/MeshImporterDivided.cs

This file was deleted.

11 changes: 0 additions & 11 deletions Assets/VRM10/Runtime/IO/Model/MeshImporterDivided.cs.meta

This file was deleted.

Loading

0 comments on commit 129af09

Please sign in to comment.