How to change shadow background white to other colors

后端 未结 3 719
抹茶落季
抹茶落季 2020-12-30 10:55

I\'m trying to change UIPageViewController shadow color while doing a flip animation. But always it displaying white color only. How to change a color of flip s

3条回答
  •  旧时难觅i
    2020-12-30 11:49

    - (void) renderPageAtIndex:(NSUInteger)index inContext:(CGContextRef)ctx {
    UIImage *image = [images objectAtIndex:index];
    CGRect imageRect = CGRectMake(0, 0, image.size.width, image.size.height);
    CGAffineTransform transform = aspectFit(imageRect,
                                                CGContextGetClipBoundingBox(ctx));
    CGContextConcatCTM(ctx, transform);
    CGContextDrawImage(ctx, imageRect, [image CGImage]);
    }
    

提交回复
热议问题