Skip to content

Commit

Permalink
Merge pull request #1792 from ousttrue/version/v0_103_1
Browse files Browse the repository at this point in the history
UniVRM-0.103.1
  • Loading branch information
ousttrue authored Sep 13, 2022
2 parents 13011e1 + 7d6f835 commit 0585486
Show file tree
Hide file tree
Showing 10 changed files with 35 additions and 20 deletions.
4 changes: 2 additions & 2 deletions Assets/UniGLTF/Runtime/UniGLTF/UniGLTFVersion.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ public static partial class UniGLTFVersion
{
public const int MAJOR = 2;
public const int MINOR = 39;
public const int PATCH = 0;
public const string VERSION = "2.39.0";
public const int PATCH = 1;
public const string VERSION = "2.39.1";
}
}
4 changes: 2 additions & 2 deletions Assets/UniGLTF/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "com.vrmc.gltf",
"version": "0.103.0",
"version": "0.103.1",
"displayName": "UniGLTF",
"description": "GLTF importer and exporter",
"unity": "2019.4",
Expand All @@ -11,7 +11,7 @@
"name": "VRM Consortium"
},
"dependencies": {
"com.vrmc.vrmshaders": "0.103.0",
"com.vrmc.vrmshaders": "0.103.1",
"com.unity.modules.animation": "1.0.0"
}
}
4 changes: 2 additions & 2 deletions Assets/VRM/Runtime/Format/VRMVersion.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ public static partial class VRMVersion
{
public const int MAJOR = 0;
public const int MINOR = 103;
public const int PATCH = 0;
public const string VERSION = "0.103.0";
public const int PATCH = 1;
public const string VERSION = "0.103.1";
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"name": "VRM.Samples.SimpleViewer",
"rootNamespace": "",
"references": [
"GUID:da3e51d19d51a544fa14d43fee843098",
"GUID:b7aa47b240b57de44a4b2021c143c9bf",
Expand Down
19 changes: 15 additions & 4 deletions Assets/VRM/Samples~/SimpleViewer/ViewerUI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ private void Start()
string[] cmds = System.Environment.GetCommandLineArgs();
if (cmds.Length > 1)
{
LoadModelAsync(cmds[1]);
LoadPathAsync(cmds[1]);
}

m_texts.Start();
Expand Down Expand Up @@ -391,10 +391,20 @@ void OnOpenClicked()
return;
}

LoadModelAsync(path);
LoadPathAsync(path);
}

async void LoadModelAsync(string path, byte[] bytes = null)
async void LoadPathAsync(string path)
{
if (!File.Exists(path))
{
Debug.LogWarning($"{path} not exists");
return;
}
LoadModelAsync(path, File.ReadAllBytes(path));
}

async void LoadModelAsync(string path, byte[] bytes)
{
var size = bytes != null ? bytes.Length : 0;
Debug.Log($"LoadModelAsync: {path}: {size}bytes");
Expand All @@ -406,9 +416,10 @@ async void LoadModelAsync(string path, byte[] bytes = null)
case ".glb":
case ".zip":
{
var instance = await GltfUtility.LoadBytesAsync(path, bytes,
var instance = await GltfUtility.LoadAsync(path,
GetIAwaitCaller(m_useAsync.isOn),
GetGltfMaterialGenerator(m_useUrpMaterial.isOn));
SetModel(instance);
break;
}

Expand Down
6 changes: 3 additions & 3 deletions Assets/VRM/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "com.vrmc.univrm",
"version": "0.103.0",
"version": "0.103.1",
"displayName": "VRM",
"description": "VRM importer",
"unity": "2019.4",
Expand All @@ -14,8 +14,8 @@
"name": "VRM Consortium"
},
"dependencies": {
"com.vrmc.vrmshaders": "0.103.0",
"com.vrmc.gltf": "0.103.0",
"com.vrmc.vrmshaders": "0.103.1",
"com.vrmc.gltf": "0.103.1",
"com.unity.ugui": "1.0.0"
},
"samples": [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
{
"name": "VRM10.Samples.VRM10Viewer",
"rootNamespace": "",
"references": [
"GUID:b7aa47b240b57de44a4b2021c143c9bf",
"GUID:da3e51d19d51a544fa14d43fee843098",
"GUID:8d76e605759c3f64a957d63ef96ada7c",
"GUID:e47c917724578cc43b5506c17a27e9a0"
"GUID:e47c917724578cc43b5506c17a27e9a0",
"GUID:1cd941934d098654fa21a13f28346412"
],
"includePlatforms": [],
"excludePlatforms": [],
Expand Down
5 changes: 3 additions & 2 deletions Assets/VRM10/Samples~/VRM10Viewer/VRM10ViewerUI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using System.Linq;
using System.Threading;
using UniGLTF;
using UniGLTF.Utils;
using UniHumanoid;
using UnityEngine;
using UnityEngine.UI;
Expand Down Expand Up @@ -276,7 +277,7 @@ public void UpdatePose(bool useBvh, Animator bvhAnimator)
{
var controlRig = m_controller.Runtime.ControlRig;

foreach (HumanBodyBones bone in Enum.GetValues(typeof(HumanBodyBones)))
foreach (HumanBodyBones bone in CachedEnum.GetValues<HumanBodyBones>())
{
if (bone == HumanBodyBones.LastBone)
{
Expand All @@ -300,7 +301,7 @@ public void UpdatePose(bool useBvh, Animator bvhAnimator)

if (bone == HumanBodyBones.Hips)
{
controlRigBone.position = bvhBone.position * controlRig.InitialHipsHeight;
controlRigBone.localPosition = bvhBone.localPosition * controlRig.InitialHipsHeight;
}
}
else
Expand Down
6 changes: 3 additions & 3 deletions Assets/VRM10/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "com.vrmc.vrm",
"version": "0.103.0",
"version": "0.103.1",
"displayName": "VRM-1.0β",
"description": "VRM-1.0β importer",
"unity": "2019.4",
Expand All @@ -14,8 +14,8 @@
"name": "VRM Consortium"
},
"dependencies": {
"com.vrmc.vrmshaders": "0.103.0",
"com.vrmc.gltf": "0.103.0"
"com.vrmc.vrmshaders": "0.103.1",
"com.vrmc.gltf": "0.103.1"
},
"samples": [
{
Expand Down
2 changes: 1 addition & 1 deletion Assets/VRMShaders/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "com.vrmc.vrmshaders",
"version": "0.103.0",
"version": "0.103.1",
"displayName": "VRM Shaders",
"description": "VRM Shaders",
"unity": "2019.4",
Expand Down

0 comments on commit 0585486

Please sign in to comment.