invert uv rotation direction of mtoon 1.0

This commit is contained in:
Masataka SUMI 2022-10-04 15:47:32 +09:00
parent e670fd66e3
commit 64f7c3faaf
2 changed files with 2 additions and 6 deletions

View File

@ -154,9 +154,7 @@ namespace UniVRM10
}
// Speed unit Conversion
const float rotationPerSecToRadianPerSec = Mathf.PI * 2f;
// Coords conversion
const float unityToGltfCoordsConversion = -1f;
mtoon.UvAnimationRotationSpeedFactor = context.UvAnimationRotationSpeedFactor * rotationPerSecToRadianPerSec * unityToGltfCoordsConversion;
mtoon.UvAnimationRotationSpeedFactor = context.UvAnimationRotationSpeedFactor * rotationPerSecToRadianPerSec;
// Texture Transforms
var scale = context.TextureScale;

View File

@ -226,9 +226,7 @@ namespace UniVRM10
{
// Speed unit Conversion
const float radianPerSecToRotationPerSec = 1f / (Mathf.PI * 2f);
// Coords conversion
const float gltfToUnityCoordsConversion = -1f;
yield return (MToon10Prop.UvAnimationRotationSpeedFactor.ToUnityShaderLabName(), uvAnimSpeedRotation.Value * radianPerSecToRotationPerSec * gltfToUnityCoordsConversion);
yield return (MToon10Prop.UvAnimationRotationSpeedFactor.ToUnityShaderLabName(), uvAnimSpeedRotation.Value * radianPerSecToRotationPerSec);
}
// UI