void OnPostRender() { if (_renderLists.Count == 0) { return; } for (int i = 0; i < _renderLists.Count; i++) { RenderList renderList = _renderLists [i]; foreach (Rect rectangle in renderList.rectangles) { if (renderList.wireframe) { DrawWireframe(rectangle, renderList.material); } else { DrawUtils.DrawQuad(rectangle.center, rectangle.width, rectangle.height, new Rect(0, 0, 1, 1), renderList.material); if (_outlineMaterial != null) { DrawWireframe(rectangle, _outlineMaterial); } } } } }