IsAlphaOnlyTextureFormat() private method

private IsAlphaOnlyTextureFormat ( TextureFormat format ) : bool
format TextureFormat
return bool
 public void OnPreviewSettings(UnityEngine.Object[] targets)
 {
     if (ShaderUtil.hardwareSupportsRectRenderTexture)
     {
         GUI.enabled = true;
         this.InitPreview();
         bool flag  = true;
         bool flag2 = true;
         bool flag3 = false;
         int  a     = 8;
         foreach (Texture texture in targets)
         {
             a = Mathf.Max(a, TextureUtil.GetMipmapCount(texture));
             Cubemap cubemap = texture as Cubemap;
             if (cubemap != null)
             {
                 TextureFormat format = cubemap.format;
                 if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                 {
                     flag2 = false;
                 }
                 if (TextureUtil.HasAlphaTextureFormat(format) && (TextureUtil.GetUsageMode(texture) == TextureUsageMode.Default))
                 {
                     flag3 = true;
                 }
             }
             else
             {
                 flag3 = true;
                 flag2 = false;
             }
         }
         if (flag2)
         {
             this.m_PreviewType = PreviewType.Alpha;
             flag = false;
         }
         else if (!flag3)
         {
             this.m_PreviewType = PreviewType.RGB;
             flag = false;
         }
         if (flag)
         {
             GUIContent[] contentArray = new GUIContent[] { Styles.RGBIcon, Styles.alphaIcon };
             int          previewType  = (int)this.m_PreviewType;
             if (GUILayout.Button(contentArray[previewType], Styles.preButton, new GUILayoutOption[0]))
             {
                 this.m_PreviewType = (PreviewType)(++previewType % contentArray.Length);
             }
         }
         GUI.enabled = a != 1;
         GUILayout.Box(Styles.smallZoom, Styles.preLabel, new GUILayoutOption[0]);
         GUI.changed = false;
         GUILayoutOption[] options = new GUILayoutOption[] { GUILayout.MaxWidth(64f) };
         this.m_MipLevel = Mathf.Round(GUILayout.HorizontalSlider(this.m_MipLevel, (float)(a - 1), 0f, Styles.preSlider, Styles.preSliderThumb, options));
         GUILayout.Box(Styles.largeZoom, Styles.preLabel, new GUILayoutOption[0]);
         GUI.enabled = true;
     }
 }
        public void OnPreviewSettings(Object[] targets)
        {
            if (!ShaderUtil.hardwareSupportsRectRenderTexture)
            {
                return;
            }
            GUI.enabled = true;
            InitPreview();

            bool showMode  = true;
            bool alphaOnly = true;
            //@TODO: Share some code with texture inspector???
            bool hasAlpha = false;
            int  mipCount = 8;

            foreach (Texture t2 in targets)
            {
                mipCount = Mathf.Max(mipCount, TextureUtil.GetMipmapCount(t2));

                Cubemap cubemap = t2 as Cubemap;
                if (cubemap)
                {
                    TextureFormat format = cubemap.format;
                    if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                    {
                        alphaOnly = false;
                    }
                    if (TextureUtil.HasAlphaTextureFormat(format))
                    {
                        TextureUsageMode mode = TextureUtil.GetUsageMode(t2);
                        if (mode == TextureUsageMode.Default) // all other texture usage modes don't displayable alpha
                        {
                            hasAlpha = true;
                        }
                    }
                }
                else
                {
                    hasAlpha  = true;
                    alphaOnly = false;
                }
            }

            if (alphaOnly)
            {
                m_PreviewType = PreviewType.Alpha;
                showMode      = false;
            }
            else if (!hasAlpha)
            {
                m_PreviewType = PreviewType.RGB;
                showMode      = false;
            }

            if (showMode)
            {
                GUIContent[] kPreviewIcons = { Styles.RGBIcon, Styles.alphaIcon };
                int          index         = (int)m_PreviewType;
                if (GUILayout.Button(kPreviewIcons[index], Styles.preButton))
                {
                    m_PreviewType = (PreviewType)(++index % kPreviewIcons.Length);
                }
            }

            GUI.enabled = (mipCount != 1);
            GUILayout.Box(Styles.smallZoom, Styles.preLabel);
            GUI.changed = false;
            m_MipLevel  = Mathf.Round(GUILayout.HorizontalSlider(m_MipLevel, mipCount - 1, 0, Styles.preSlider, Styles.preSliderThumb, GUILayout.MaxWidth(64)));
            GUILayout.Box(Styles.largeZoom, Styles.preLabel);
            GUI.enabled = true;
        }
示例#3
0
 public override void OnPreviewSettings()
 {
     if (this.IsCubemap())
     {
         this.m_CubemapPreview.OnPreviewSettings(base.targets);
     }
     else
     {
         if (TextureInspector.s_Styles == null)
         {
             TextureInspector.s_Styles = new TextureInspector.Styles();
         }
         Texture texture = base.target as Texture;
         bool    flag    = true;
         bool    flag2   = false;
         bool    flag3   = true;
         int     num     = 1;
         if (base.target is Texture2D || base.target is ProceduralTexture)
         {
             flag2 = true;
             flag3 = false;
         }
         UnityEngine.Object[] targets = base.targets;
         for (int i = 0; i < targets.Length; i++)
         {
             Texture texture2 = (Texture)targets[i];
             if (!(texture2 == null))
             {
                 TextureFormat format = (TextureFormat)0;
                 bool          flag4  = false;
                 if (texture2 is Texture2D)
                 {
                     format = (texture2 as Texture2D).format;
                     flag4  = true;
                 }
                 else if (texture2 is ProceduralTexture)
                 {
                     format = (texture2 as ProceduralTexture).format;
                     flag4  = true;
                 }
                 if (flag4)
                 {
                     if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                     {
                         flag2 = false;
                     }
                     if (TextureUtil.HasAlphaTextureFormat(format))
                     {
                         if (TextureUtil.GetUsageMode(texture2) == TextureUsageMode.Default)
                         {
                             flag3 = true;
                         }
                     }
                 }
                 num = Mathf.Max(num, TextureUtil.GetMipmapCount(texture2));
             }
         }
         if (flag2)
         {
             this.m_ShowAlpha = true;
             flag             = false;
         }
         else if (!flag3)
         {
             this.m_ShowAlpha = false;
             flag             = false;
         }
         if (flag && texture != null && !TextureInspector.IsNormalMap(texture))
         {
             this.m_ShowAlpha = GUILayout.Toggle(this.m_ShowAlpha, (!this.m_ShowAlpha) ? TextureInspector.s_Styles.RGBIcon : TextureInspector.s_Styles.alphaIcon, TextureInspector.s_Styles.previewButton, new GUILayoutOption[0]);
         }
         GUI.enabled = (num != 1);
         GUILayout.Box(TextureInspector.s_Styles.smallZoom, TextureInspector.s_Styles.previewLabel, new GUILayoutOption[0]);
         GUI.changed     = false;
         this.m_MipLevel = Mathf.Round(GUILayout.HorizontalSlider(this.m_MipLevel, (float)(num - 1), 0f, TextureInspector.s_Styles.previewSlider, TextureInspector.s_Styles.previewSliderThumb, new GUILayoutOption[]
         {
             GUILayout.MaxWidth(64f)
         }));
         GUILayout.Box(TextureInspector.s_Styles.largeZoom, TextureInspector.s_Styles.previewLabel, new GUILayoutOption[0]);
         GUI.enabled = true;
     }
 }
 public override void OnPreviewSettings()
 {
     if (this.IsCubemap())
     {
         this.m_CubemapPreview.OnPreviewSettings(base.targets);
     }
     else
     {
         if (s_Styles == null)
         {
             s_Styles = new Styles();
         }
         Texture target = base.target as Texture;
         bool    flag   = true;
         bool    flag2  = false;
         bool    flag3  = true;
         int     a      = 1;
         if ((base.target is Texture2D) || (base.target is ProceduralTexture))
         {
             flag2 = true;
             flag3 = false;
         }
         foreach (Texture texture2 in base.targets)
         {
             TextureFormat format = (TextureFormat)0;
             bool          flag4  = false;
             if (texture2 is Texture2D)
             {
                 format = (texture2 as Texture2D).format;
                 flag4  = true;
             }
             else if (texture2 is ProceduralTexture)
             {
                 format = (texture2 as ProceduralTexture).format;
                 flag4  = true;
             }
             if (flag4)
             {
                 if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                 {
                     flag2 = false;
                 }
                 if (TextureUtil.HasAlphaTextureFormat(format) && (TextureUtil.GetUsageMode(texture2) == TextureUsageMode.Default))
                 {
                     flag3 = true;
                 }
             }
             a = Mathf.Max(a, TextureUtil.GetMipmapCount(texture2));
         }
         if (flag2)
         {
             this.m_ShowAlpha = true;
             flag             = false;
         }
         else if (!flag3)
         {
             this.m_ShowAlpha = false;
             flag             = false;
         }
         if (flag && !IsNormalMap(target))
         {
             this.m_ShowAlpha = GUILayout.Toggle(this.m_ShowAlpha, !this.m_ShowAlpha ? s_Styles.RGBIcon : s_Styles.alphaIcon, s_Styles.previewButton, new GUILayoutOption[0]);
         }
         GUI.enabled = a != 1;
         GUILayout.Box(s_Styles.smallZoom, s_Styles.previewLabel, new GUILayoutOption[0]);
         GUI.changed = false;
         GUILayoutOption[] options = new GUILayoutOption[] { GUILayout.MaxWidth(64f) };
         this.m_MipLevel = Mathf.Round(GUILayout.HorizontalSlider(this.m_MipLevel, (float)(a - 1), 0f, s_Styles.previewSlider, s_Styles.previewSliderThumb, options));
         GUILayout.Box(s_Styles.largeZoom, s_Styles.previewLabel, new GUILayoutOption[0]);
         GUI.enabled = true;
     }
 }
        public override void OnPreviewSettings()
        {
            if (IsCubemap())
            {
                m_CubemapPreview.OnPreviewSettings(targets);
                return;
            }

            if (IsTexture2DArray() && !SystemInfo.supports2DArrayTextures)
            {
                return;
            }

            if (s_Styles == null)
            {
                s_Styles = new Styles();
            }

            // TextureInspector code is reused for RenderTexture and Cubemap inspectors.
            // Make sure we can handle the situation where target is just a Texture and
            // not a Texture2D. It's also used for large popups for mini texture fields,
            // and while it's being shown the actual texture object might disappear --
            // make sure to handle null targets.
            Texture tex       = target as Texture;
            bool    alphaOnly = false;
            bool    hasAlpha  = true;
            int     mipCount  = 1;

            if (target is Texture2D)
            {
                alphaOnly = true;
                hasAlpha  = false;
            }

            foreach (Texture t in targets)
            {
                if (t == null) // texture might have disappeared while we're showing this in a preview popup
                {
                    continue;
                }
                TextureFormat format      = 0;
                bool          checkFormat = false;
                if (t is Texture2D)
                {
                    format      = (t as Texture2D).format;
                    checkFormat = true;
                }

                if (checkFormat)
                {
                    if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                    {
                        alphaOnly = false;
                    }
                    if (TextureUtil.HasAlphaTextureFormat(format))
                    {
                        TextureUsageMode mode = TextureUtil.GetUsageMode(t);
                        if (mode == TextureUsageMode.Default) // all other texture usage modes don't displayable alpha
                        {
                            hasAlpha = true;
                        }
                    }
                }

                mipCount = Mathf.Max(mipCount, TextureUtil.GetMipmapCount(t));
            }


            List <PreviewMode> previewCandidates = new List <PreviewMode>(5);

            previewCandidates.Add(PreviewMode.RGB);
            previewCandidates.Add(PreviewMode.R);
            previewCandidates.Add(PreviewMode.G);
            previewCandidates.Add(PreviewMode.B);
            previewCandidates.Add(PreviewMode.A);

            if (alphaOnly)
            {
                previewCandidates.Clear();
                previewCandidates.Add(PreviewMode.A);
                m_PreviewMode = PreviewMode.A;
            }
            else if (!hasAlpha)
            {
                previewCandidates.Remove(PreviewMode.A);
            }


            if (previewCandidates.Count > 1 && tex != null && !IsNormalMap(tex))
            {
                int selectedIndex = previewCandidates.IndexOf(m_PreviewMode);
                if (selectedIndex == -1)
                {
                    selectedIndex = 0;
                }

                if (previewCandidates.Contains(PreviewMode.RGB))
                {
                    m_PreviewMode = GUILayout.Toggle(m_PreviewMode == PreviewMode.RGB, s_Styles.previewButtonContents[0], s_Styles.toolbarButton)
                        ? PreviewMode.RGB
                        : m_PreviewMode;
                }
                if (previewCandidates.Contains(PreviewMode.R))
                {
                    m_PreviewMode = GUILayout.Toggle(m_PreviewMode == PreviewMode.R, s_Styles.previewButtonContents[1], s_Styles.toolbarButton)
                        ? PreviewMode.R
                        : m_PreviewMode;
                }
                if (previewCandidates.Contains(PreviewMode.G))
                {
                    m_PreviewMode = GUILayout.Toggle(m_PreviewMode == PreviewMode.G, s_Styles.previewButtonContents[2], s_Styles.toolbarButton)
                        ? PreviewMode.G
                        : m_PreviewMode;
                }
                if (previewCandidates.Contains(PreviewMode.B))
                {
                    m_PreviewMode = GUILayout.Toggle(m_PreviewMode == PreviewMode.B, s_Styles.previewButtonContents[3], s_Styles.toolbarButton)
                        ? PreviewMode.B
                        : m_PreviewMode;
                }
                if (previewCandidates.Contains(PreviewMode.A))
                {
                    m_PreviewMode = GUILayout.Toggle(m_PreviewMode == PreviewMode.A, s_Styles.previewButtonContents[4], s_Styles.toolbarButton)
                        ? PreviewMode.A
                        : m_PreviewMode;
                }
            }

            if (mipCount > 1)
            {
                GUILayout.Box(s_Styles.smallZoom, s_Styles.previewLabel);
                GUI.changed = false;
                m_MipLevel  = Mathf.Round(GUILayout.HorizontalSlider(m_MipLevel, mipCount - 1, 0, s_Styles.previewSlider, s_Styles.previewSliderThumb, GUILayout.MaxWidth(64)));

                //For now, we don't have mipmaps smaller than the tile size when using VT.
                if (EditorGUI.UseVTMaterial(tex))
                {
                    int numMipsOfTile = (int)Mathf.Log(VirtualTexturing.EditorHelpers.tileSize, 2) + 1;
                    m_MipLevel = Mathf.Min(m_MipLevel, Mathf.Max(mipCount - numMipsOfTile, 0));
                }

                GUILayout.Box(s_Styles.largeZoom, s_Styles.previewLabel);
            }
        }
 public void OnPreviewSettings(UnityEngine.Object[] targets)
 {
     if (ShaderUtil.hardwareSupportsRectRenderTexture)
     {
         GUI.enabled = true;
         this.InitPreview();
         bool flag  = true;
         bool flag2 = true;
         bool flag3 = false;
         int  num   = 8;
         for (int i = 0; i < targets.Length; i++)
         {
             Texture texture = (Texture)targets[i];
             num = Mathf.Max(num, TextureUtil.GetMipmapCount(texture));
             Cubemap cubemap = texture as Cubemap;
             if (cubemap)
             {
                 TextureFormat format = cubemap.format;
                 if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                 {
                     flag2 = false;
                 }
                 if (TextureUtil.HasAlphaTextureFormat(format))
                 {
                     if (TextureUtil.GetUsageMode(texture) == TextureUsageMode.Default)
                     {
                         flag3 = true;
                     }
                 }
             }
             else
             {
                 flag3 = true;
                 flag2 = false;
             }
         }
         if (flag2)
         {
             this.m_PreviewType = CubemapPreview.PreviewType.Alpha;
             flag = false;
         }
         else if (!flag3)
         {
             this.m_PreviewType = CubemapPreview.PreviewType.RGB;
             flag = false;
         }
         if (flag)
         {
             GUIContent[] array = new GUIContent[]
             {
                 CubemapPreview.Styles.RGBIcon,
                 CubemapPreview.Styles.alphaIcon
             };
             int previewType = (int)this.m_PreviewType;
             if (GUILayout.Button(array[previewType], CubemapPreview.Styles.preButton, new GUILayoutOption[0]))
             {
                 this.m_PreviewType = (previewType + CubemapPreview.PreviewType.Alpha) % (CubemapPreview.PreviewType)array.Length;
             }
         }
         GUI.enabled = (num != 1);
         GUILayout.Box(CubemapPreview.Styles.smallZoom, CubemapPreview.Styles.preLabel, new GUILayoutOption[0]);
         GUI.changed     = false;
         this.m_MipLevel = Mathf.Round(GUILayout.HorizontalSlider(this.m_MipLevel, (float)(num - 1), 0f, CubemapPreview.Styles.preSlider, CubemapPreview.Styles.preSliderThumb, new GUILayoutOption[]
         {
             GUILayout.MaxWidth(64f)
         }));
         GUILayout.Box(CubemapPreview.Styles.largeZoom, CubemapPreview.Styles.preLabel, new GUILayoutOption[0]);
         GUI.enabled = true;
     }
 }
 public override void OnPreviewSettings()
 {
     if (this.IsCubemap())
     {
         this.m_CubemapPreview.OnPreviewSettings(this.targets);
     }
     else
     {
         if (TextureInspector.s_Styles == null)
         {
             TextureInspector.s_Styles = new TextureInspector.Styles();
         }
         Texture target1 = this.target as Texture;
         bool    flag1   = true;
         bool    flag2   = false;
         bool    flag3   = true;
         int     a       = 1;
         if (this.target is Texture2D || this.target is ProceduralTexture)
         {
             flag2 = true;
             flag3 = false;
         }
         foreach (Texture target2 in this.targets)
         {
             TextureFormat format = (TextureFormat)0;
             bool          flag4  = false;
             if (target2 is Texture2D)
             {
                 format = (target2 as Texture2D).format;
                 flag4  = true;
             }
             else if (target2 is ProceduralTexture)
             {
                 format = (target2 as ProceduralTexture).format;
                 flag4  = true;
             }
             if (flag4)
             {
                 if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                 {
                     flag2 = false;
                 }
                 if (TextureUtil.HasAlphaTextureFormat(format) && TextureUtil.GetUsageMode(target2) == TextureUsageMode.Default)
                 {
                     flag3 = true;
                 }
             }
             a = Mathf.Max(a, TextureUtil.CountMipmaps(target2));
         }
         if (flag2)
         {
             this.m_ShowAlpha = true;
             flag1            = false;
         }
         else if (!flag3)
         {
             this.m_ShowAlpha = false;
             flag1            = false;
         }
         if (flag1 && !TextureInspector.IsNormalMap(target1))
         {
             this.m_ShowAlpha = GUILayout.Toggle(this.m_ShowAlpha, !this.m_ShowAlpha ? TextureInspector.s_Styles.RGBIcon : TextureInspector.s_Styles.alphaIcon, TextureInspector.s_Styles.previewButton, new GUILayoutOption[0]);
         }
         GUI.enabled = a != 1;
         GUILayout.Box(TextureInspector.s_Styles.smallZoom, TextureInspector.s_Styles.previewLabel, new GUILayoutOption[0]);
         GUI.changed     = false;
         this.m_MipLevel = Mathf.Round(GUILayout.HorizontalSlider(this.m_MipLevel, (float)(a - 1), 0.0f, TextureInspector.s_Styles.previewSlider, TextureInspector.s_Styles.previewSliderThumb, GUILayout.MaxWidth(64f)));
         GUILayout.Box(TextureInspector.s_Styles.largeZoom, TextureInspector.s_Styles.previewLabel, new GUILayoutOption[0]);
         GUI.enabled = true;
     }
 }
        public override void OnPreviewSettings()
        {
            if (IsCubemap())
            {
                m_CubemapPreview.OnPreviewSettings(targets);
                return;
            }


            if (s_Styles == null)
            {
                s_Styles = new Styles();
            }


            // TextureInspector code is reused for RenderTexture and Cubemap inspectors.
            // Make sure we can handle the situation where target is just a Texture and
            // not a Texture2D. It's also used for large popups for mini texture fields,
            // and while it's being shown the actual texture object might disappear --
            // make sure to handle null targets.
            Texture tex       = target as Texture;
            bool    showMode  = true;
            bool    alphaOnly = false;
            bool    hasAlpha  = true;
            int     mipCount  = 1;

            if (target is Texture2D)
            {
                alphaOnly = true;
                hasAlpha  = false;
            }

            foreach (Texture t in targets)
            {
                if (t == null) // texture might have disappeared while we're showing this in a preview popup
                {
                    continue;
                }
                TextureFormat format      = 0;
                bool          checkFormat = false;
                if (t is Texture2D)
                {
                    format      = (t as Texture2D).format;
                    checkFormat = true;
                }

                if (checkFormat)
                {
                    if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                    {
                        alphaOnly = false;
                    }
                    if (TextureUtil.HasAlphaTextureFormat(format))
                    {
                        TextureUsageMode mode = TextureUtil.GetUsageMode(t);
                        if (mode == TextureUsageMode.Default) // all other texture usage modes don't displayable alpha
                        {
                            hasAlpha = true;
                        }
                    }
                }

                mipCount = Mathf.Max(mipCount, TextureUtil.GetMipmapCount(t));
            }

            if (alphaOnly)
            {
                m_ShowAlpha = true;
                showMode    = false;
            }
            else if (!hasAlpha)
            {
                m_ShowAlpha = false;
                showMode    = false;
            }

            if (showMode && tex != null && !IsNormalMap(tex))
            {
                m_ShowAlpha = GUILayout.Toggle(m_ShowAlpha, m_ShowAlpha ? s_Styles.alphaIcon : s_Styles.RGBIcon, s_Styles.previewButton);
            }

            if (mipCount > 1)
            {
                GUILayout.Box(s_Styles.smallZoom, s_Styles.previewLabel);
                GUI.changed = false;
                m_MipLevel  = Mathf.Round(GUILayout.HorizontalSlider(m_MipLevel, mipCount - 1, 0, s_Styles.previewSlider, s_Styles.previewSliderThumb, GUILayout.MaxWidth(64)));
                GUILayout.Box(s_Styles.largeZoom, s_Styles.previewLabel);
            }
        }
        public void OnPreviewSettings(Object[] targets)
        {
            if (!ShaderUtil.hardwareSupportsRectRenderTexture)
            {
                return;
            }
            GUI.enabled = true;
            this.InitPreview();
            bool flag1 = true;
            bool flag2 = true;
            bool flag3 = false;
            int  a     = 8;

            foreach (Texture target in targets)
            {
                a = Mathf.Max(a, TextureUtil.CountMipmaps(target));
                Cubemap cubemap = target as Cubemap;
                if ((bool)((Object)cubemap))
                {
                    TextureFormat format = cubemap.format;
                    if (!TextureUtil.IsAlphaOnlyTextureFormat(format))
                    {
                        flag2 = false;
                    }
                    if (TextureUtil.HasAlphaTextureFormat(format) && TextureUtil.GetUsageMode(target) == TextureUsageMode.Default)
                    {
                        flag3 = true;
                    }
                }
                else
                {
                    flag3 = true;
                    flag2 = false;
                }
            }
            if (flag2)
            {
                this.m_PreviewType = CubemapPreview.PreviewType.Alpha;
                flag1 = false;
            }
            else if (!flag3)
            {
                this.m_PreviewType = CubemapPreview.PreviewType.RGB;
                flag1 = false;
            }
            if (flag1)
            {
                GUIContent[] guiContentArray = new GUIContent[2] {
                    CubemapPreview.Styles.RGBIcon, CubemapPreview.Styles.alphaIcon
                };
                int previewType = (int)this.m_PreviewType;
                if (GUILayout.Button(guiContentArray[previewType], CubemapPreview.Styles.preButton, new GUILayoutOption[0]))
                {
                    int num;
                    this.m_PreviewType = (CubemapPreview.PreviewType)((num = previewType + 1) % guiContentArray.Length);
                }
            }
            GUI.enabled = a != 1;
            GUILayout.Box(CubemapPreview.Styles.smallZoom, CubemapPreview.Styles.preLabel, new GUILayoutOption[0]);
            GUI.changed     = false;
            this.m_MipLevel = Mathf.Round(GUILayout.HorizontalSlider(this.m_MipLevel, (float)(a - 1), 0.0f, CubemapPreview.Styles.preSlider, CubemapPreview.Styles.preSliderThumb, GUILayout.MaxWidth(64f)));
            GUILayout.Box(CubemapPreview.Styles.largeZoom, CubemapPreview.Styles.preLabel, new GUILayoutOption[0]);
            GUI.enabled = true;
        }