我正在做一些需要我循环浏览图像并在它们之间创建某种淡入和淡出过渡的东西。我习惯了 javascript,所以我自然会想要改变将要淡入的图像视图的深度。有没有办法选择哪个视图显示在顶部?还是有更好的方法来做我想要实现的目标?
CGRect imageFrame = CGRectMake(0.0, 0.0, 1024.0, 280.0);
UIImageView *image_one = [[UIImageView alloc] initWithFrame:imageFrame];
image_one.image = [UIImage imageNamed:@"image_one.png"];
[self.view addSubview:image_one];
UIImageView *image_two = [[UIImageView alloc] initWithFrame:imageFrame];
image_two.image = [UIImage imageNamed:@"image_two.png"];
[self.view addSubview:image_two];