Skip to content

Commit

Permalink
Fix for Unity 2018 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
simonoliver committed Mar 27, 2018
1 parent 1fab664 commit ee10de6
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions ResourceChecker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -276,11 +276,7 @@ int GetBitsPerPixel(TextureFormat format)
case TextureFormat.PVRTC_RGBA4:// PowerVR (iOS) 4 bits/pixel compressed with alpha channel texture format
return 4;
case TextureFormat.ETC_RGB4:// ETC (GLES2.0) 4 bits/pixel compressed RGB texture format.
return 4;
case TextureFormat.ATC_RGB4:// ATC (ATITC) 4 bits/pixel compressed RGB texture format.
return 4;
case TextureFormat.ATC_RGBA8:// ATC (ATITC) 8 bits/pixel compressed RGB texture format.
return 8;
return 4;
case TextureFormat.BGRA32:// Format returned by iPhone camera
return 32;
#if !UNITY_5 && !UNITY_5_3_OR_NEWER
Expand Down Expand Up @@ -372,8 +368,7 @@ void ListTextures()
{

GUILayout.BeginHorizontal ();
Texture tex = new Texture();
tex = tDetails.texture;
Texture tex =tDetails.texture;
if(tDetails.texture.GetType() == typeof(Texture2DArray) || tDetails.texture.GetType() == typeof(Cubemap)){
tex = AssetPreview.GetMiniThumbnail(tDetails.texture);
}
Expand Down

0 comments on commit ee10de6

Please sign in to comment.