private static Material GetDefaultDiffuseMaterial() { #if UNITY_EDITOR // also save the material in the Assets if (!RuntimeUrdf.IsRuntimeMode() && MaterialExtensions.GetRenderPipelineType() == MaterialExtensions.RenderPipelineType.Standard) { s_DefaultDiffuse = RuntimeUrdf.AssetDatabase_GetBuiltinExtraResource <Material>("Default-Diffuse.mat"); } #endif if (s_DefaultDiffuse) { // Could't use the "Default-Diffuse.mat", either because of HDRP or runtime. so let's create one. s_DefaultDiffuse = MaterialExtensions.CreateBasicMaterial(); } return(s_DefaultDiffuse); }
public void AssetDatabase_GetBuiltinExtraResource_Sprite() { RuntimeUrdf.runtimeModeEnabled = false; Assert.IsNotNull(RuntimeUrdf.AssetDatabase_GetBuiltinExtraResource <Sprite>("UI/Skin/Background.psd")); }