I have a series of UIImages with which I need to simulate depth. I can\'t use scaling because I need to be able to rotate the parent view, and the images should look like t
I finally solved this by using CATransform3DMakeTranslation, which seems to be the only way to move a layer up or down the z-axis:
UIImageView *three = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"3.png"]];
three.layer.transform = CATransform3DMakeTranslation(0.0f, 0.0f, 20.0f);
three.center = CGPointMake(160 + 60, 240 - 60);
[self.view addSubview:three];
(I also moved UIImageView one -20.0f pixels on the z-axis. That finally gave the effect I was looking for.)