V-Sekai / godot-vrm

Importer/Exporter for VRM avatars and MToon shader. Available for Godot 4.1+ and 3.2+ in the Asset Library.
https://godotengine.org/asset-library/asset/2031
Other
287 stars 24 forks source link

Fixed _SphereAdd/_MatcapColor regression in VRM 0.0 introduced in 9aa991f . #102

Closed ExpiredPopsicle closed 6 months ago

ExpiredPopsicle commented 6 months ago

Breaking commit: https://github.com/V-Sekai/godot-vrm/commit/9aa991f3dae34c5231c121be7f57de5b7e10d77f

_MatcapColor was added to the MToon shader, which multiplies against the color from _SphereAdd, without adding any way for the VRM 0.0 loader to set it to something other than the default value of vec4(0.0, 0.0, 0.0, 1.0), meaning that it would always have zero additive influence.

This commit also flips the vertical axis of matcapUv in the MToon shader, because the _SphereAdd texture was showing up inverted in Godot.