The first circle that is drawn (the innermost one) is OK, but then they get increasingly less circular? I know this must have something to do with the iterations.
//LOAD CIRCLES
circleWidth = 100;
circleHeight = 100;
for (int i = 0; i < 4; i++) {
UIView *circleView = [[UIView alloc] init];
circleView.frame = CGRectMake(0, 0, circleWidth, circleHeight);
circleView.center = self.view.center;
circleView.alpha = 0.7;
circleView.layer.cornerRadius = 50;
circleView.backgroundColor = [UIColor clearColor];
circleView.layer.borderColor = [[UIColor whiteColor] CGColor];
circleView.layer.borderWidth = 3;
circleHeight += 50;
circleWidth += 50;
[self.view addSubview:circleView];
[self.view sendSubviewToBack:circleView];
}
You’re increasing the width and height in each iteration, but the
cornerRadiusremains fixed at 50, which will only result in a circle if width and height are 100 (first iteration). You should set thecornerRadiustocircleWidth * 0.5.