private static void InitializeShaderPlatforms() { if (s_ShaderPlatformNames == null) { int availableShaderCompilerPlatforms = ShaderUtil.GetAvailableShaderCompilerPlatforms(); List <string> list = new List <string>(); List <int> list2 = new List <int>(); for (int i = 0; i < 0x20; i++) { if ((availableShaderCompilerPlatforms & (((int)1) << i)) != 0) { list.Add(((ShaderUtil.ShaderCompilerPlatformType)i).ToString()); list2.Add(i); } } s_ShaderPlatformNames = list.ToArray(); s_ShaderPlatformIndices = list2.ToArray(); } }
private static void InitializeShaderPlatforms() { if (ShaderInspectorPlatformsPopup.s_ShaderPlatformNames != null) { return; } int compilerPlatforms = ShaderUtil.GetAvailableShaderCompilerPlatforms(); List <string> stringList = new List <string>(); List <int> intList = new List <int>(); for (int index = 0; index < 32; ++index) { if ((compilerPlatforms & 1 << index) != 0) { stringList.Add(((ShaderUtil.ShaderCompilerPlatformType)index).ToString()); intList.Add(index); } } ShaderInspectorPlatformsPopup.s_ShaderPlatformNames = stringList.ToArray(); ShaderInspectorPlatformsPopup.s_ShaderPlatformIndices = intList.ToArray(); }
private static void InitializeShaderPlatforms() { if (ShaderInspectorPlatformsPopup.s_ShaderPlatformNames != null) { return; } int availableShaderCompilerPlatforms = ShaderUtil.GetAvailableShaderCompilerPlatforms(); List <string> list = new List <string>(); List <int> list2 = new List <int>(); for (int i = 0; i < 32; i++) { if ((availableShaderCompilerPlatforms & 1 << i) != 0) { list.Add(((ShaderUtil.ShaderCompilerPlatformType)i).ToString()); list2.Add(i); } } ShaderInspectorPlatformsPopup.s_ShaderPlatformNames = list.ToArray(); ShaderInspectorPlatformsPopup.s_ShaderPlatformIndices = list2.ToArray(); }
static void InitializeShaderPlatforms() { if (s_ShaderPlatformNames != null) { return; } int platformMask = ShaderUtil.GetAvailableShaderCompilerPlatforms(); var names = new List <string>(); var indices = new List <int>(); for (int i = 0; i < 32; ++i) { if ((platformMask & (1 << i)) == 0) { continue; } names.Add(((Rendering.ShaderCompilerPlatform)i).ToString()); indices.Add(i); } s_ShaderPlatformNames = names.ToArray(); s_ShaderPlatformIndices = indices.ToArray(); }