Skip to content
This repository was archived by the owner on Nov 30, 2020. It is now read-only.

Commit fcdb350

Browse files
committed
Fixed #447
1 parent 618fffc commit fcdb350

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

PostProcessing/Runtime/Utils/TextureFormatUtilities.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
using System;
22
using System.Collections.Generic;
3-
using System.Linq;
43
using UnityEngine.Assertions;
54

65
namespace UnityEngine.Rendering.PostProcessing
@@ -72,12 +71,12 @@ static TextureFormatUtilities()
7271
// In 2018.1 SystemInfo.SupportsRenderTextureFormat() generates garbage so we need to
7372
// cache its calls to avoid that...
7473
s_SupportedRenderTextureFormats = new Dictionary<int, bool>();
75-
IEnumerable<int> values = Enum.GetValues(typeof(RenderTextureFormat)).Cast<int>();
74+
var values = Enum.GetValues(typeof(RenderTextureFormat));
7675

77-
foreach (int format in values)
76+
foreach (var format in values)
7877
{
7978
bool supported = SystemInfo.SupportsRenderTextureFormat((RenderTextureFormat)format);
80-
s_SupportedRenderTextureFormats.Add(format, supported);
79+
s_SupportedRenderTextureFormats.Add((int)format, supported);
8180
}
8281
}
8382

0 commit comments

Comments
 (0)