Beispiel #1
0
        protected override void OnPostRender()
        {
            base.OnPostRender();

            Camera cam = Camera.current;

            if (cam == null)
            {
                return;
            }

            DrawLines.LineMode = LINE_MODE.LINES;
            Matrix4x4 m = Matrix4x4.identity;

            foreach (var line in lines)
            {
                DrawLines.Draw(cam, line.Control, Color.red, m);
                DrawLines.Draw(cam, line.Positions, Color.blue, m);
                DrawVertices.Draw(cam, 0.02f, line.Positions, Color.yellow, m);
            }
        }
        protected virtual void OnPostRender()
        {
            Camera cam = Camera.current;

            if (cam == null)
            {
                return;
            }
            if (Points == null)
            {
                return;
            }
            if (Indices == null)
            {
                return;
            }

            Matrix4x4 m = Matrix4x4.identity;

            DrawLines.LineMode = LINE_MODE.LINES;
            DrawLines.Draw(cam, Points, LineColor, m, Indices);
            DrawVertices.Draw(cam, 0.02f, Points, Color.yellow, m);
        }