public GRectangle union(GRectangle r) {
		if (isEmpty()) return new GRectangle(r);
		if (r.isEmpty()) return new GRectangle(this);
		double x1 = Math.min(xc, r.xc);
		double y1 = Math.min(yc, r.yc);
		double x2 = Math.max(xc + myWidth, r.xc + r.myWidth);
		double y2 = Math.max(yc + myHeight, r.yc + r.myHeight);
		return new GRectangle(x1, y1, x2 - x1, y2 - y1);
	}