private static RenderMode GetBlendMode(VrmMaterial material) { if (material.IsKeywordEnabled(KeyAlphaTestOn)) { return(RenderMode.Cutout); } else if (material.IsKeywordEnabled(KeyAlphaBlendOn)) { switch (material.GetInt(PropZWrite)) { case EnabledIntValue: return(RenderMode.TransparentWithZWrite); case DisabledIntValue: return(RenderMode.Transparent); default: Console.WriteLine("[GetBlendMode] Invalid ZWrite Int Value."); return(RenderMode.Transparent); } } else { return(RenderMode.Opaque); } }
private static CullMode GetCullMode(VrmMaterial material) { switch ((CullMode)material.GetInt(PropCullMode)) { case CullMode.Off: return(CullMode.Off); case CullMode.Front: return(CullMode.Front); case CullMode.Back: return(CullMode.Back); default: Console.WriteLine("[GetCullMode]: Invalid CullMode."); return(CullMode.Back); } }