DrawRect() public static method

public static DrawRect ( Rect rect, Color color ) : void
rect UnityEngine.Rect
color Color
return void
Exemplo n.º 1
0
        protected static void DrawVU(Rect r, float level, float blend, bool topdown)
        {
            level = 1f - level;
            Rect rect = new Rect(r.x + 1f, r.y + 1f + ((!topdown) ? (level * r.height) : 0f), r.width - 2f, r.y - 2f + ((!topdown) ? (r.height - level * r.height) : (level * r.height)));

            AudioMixerDrawUtils.DrawRect(r, new Color(0.1f, 0.1f, 0.1f));
            AudioMixerDrawUtils.DrawRect(rect, new Color(0.6f, 0.2f, 0.2f));
        }
Exemplo n.º 2
0
        protected static void DrawVU(Rect r, float level, float blend, bool topdown)
        {
            level = 1f - level;
            Rect rect = new Rect(r.x + 1f, (float)((double)r.y + 1.0 + (!topdown ? (double)level * (double)r.height : 0.0)), r.width - 2f, (float)((double)r.y - 2.0 + (!topdown ? (double)r.height - (double)level * (double)r.height : (double)level * (double)r.height)));

            AudioMixerDrawUtils.DrawRect(r, new Color(0.1f, 0.1f, 0.1f));
            AudioMixerDrawUtils.DrawRect(rect, new Color(0.6f, 0.2f, 0.2f));
        }
Exemplo n.º 3
0
        protected static void DrawVU(Rect r, float level, float blend, bool topdown)
        {
            level = 1.0f - level;
            const float border = 1;
            var         r2     = new Rect(r.x + border, r.y + border + (topdown ? 0.0f : level * r.height), r.width - 2 * border, r.y - 2 * border + (topdown ? level * r.height : r.height - level * r.height));

            AudioMixerDrawUtils.DrawRect(r, new Color(0.1f, 0.1f, 0.1f));
            AudioMixerDrawUtils.DrawRect(r2, new Color(0.6f, 0.2f, 0.2f));
        }