Implement the change in the VRM10 importer and show where it could be used elsewhere

in my local version of UniVRM I have the change I made, and will leave other changes to your discretion
This commit is contained in:
thoxey
2023-07-25 12:24:18 +01:00
parent 88588bf111
commit efa33106c7
2 changed files with 3 additions and 1 deletions

View File

@@ -43,7 +43,7 @@ namespace UniVRM10
m_useControlRig = useControlRig;
TextureDescriptorGenerator = new Vrm10TextureDescriptorGenerator(Data);
MaterialDescriptorGenerator = materialGenerator ?? new BuiltInVrm10MaterialDescriptorGenerator();
MaterialDescriptorGenerator = materialGenerator ?? Vrm10RenderPipelineMaterialDescriptorGeneratorDescriptorUtility.GetValidVrm10MaterialDescriptorGenerator();
m_externalMap = externalObjectMap;
if (m_externalMap == null)

View File

@@ -387,6 +387,7 @@ namespace VRM.SimpleViewer
static IMaterialDescriptorGenerator GetGltfMaterialGenerator(bool useUrp)
{
//Could be refactored to no longer need this check using RenderPipelineMaterialDescriptorGeneratorUtility
if (useUrp)
{
return new UrpGltfMaterialDescriptorGenerator();
@@ -399,6 +400,7 @@ namespace VRM.SimpleViewer
static IMaterialDescriptorGenerator GetVrmMaterialGenerator(bool useUrp, VRM.glTF_VRM_extensions vrm)
{
//Could be refactored to no longer need this check using VrmRenderPipelineMaterialDescriptorGeneratorDescriptorUtility
if (useUrp)
{
return new VRM.UrpVrmMaterialDescriptorGenerator(vrm);