public void Compressed() { var readonlyTexture = AssetDatabase.LoadAssetAtPath <Texture2D>($"{AssetPath}/4x4compressed.dds"); Assert.False(readonlyTexture.isReadable); var(bytes, mime) = AssetTextureUtil.GetTextureBytesWithMime(readonlyTexture); Assert.NotNull(bytes); }
public void NonReadablePng() { var nonReadableTex = AssetDatabase.LoadAssetAtPath <Texture2D>($"{AssetPath}/4x4.png"); Assert.False(nonReadableTex.isReadable); var(bytes, mime) = AssetTextureUtil.GetTextureBytesWithMime(nonReadableTex, ColorSpace.sRGB); Assert.NotNull(bytes); }