- (UIImage *)composeImage:(UIImage*)firstImage secondImage:(UIImage*)secondImage
{
UIGraphicsBeginImageContext(firstImage.size);
[firstImage drawInRect:CGRectMake(0, 0, firstImage.size.width, firstImage.size.height)];
// CGFloat height = mkvc.headerView.frame.size.height * 2 * 0.84;
// CGFloat width = mkvc.headerView.frame.size.width * 2 * 0.84;
// CGFloat y = mkvc.headerView.frame.origin.y * 2 * 0.84;
// CGFloat x = mkvc.headerView.frame.origin.x * 2 * 0.84;
//
// [secondImage drawInRect:CGRectMake(x, y, width, height)];
[secondImage drawInRect:CGRectMake(0, 0, 540, 540)];
UIImage *resImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return resImage;
}
{
UIGraphicsBeginImageContext(firstImage.size);
[firstImage drawInRect:CGRectMake(0, 0, firstImage.size.width, firstImage.size.height)];
// CGFloat height = mkvc.headerView.frame.size.height * 2 * 0.84;
// CGFloat width = mkvc.headerView.frame.size.width * 2 * 0.84;
// CGFloat y = mkvc.headerView.frame.origin.y * 2 * 0.84;
// CGFloat x = mkvc.headerView.frame.origin.x * 2 * 0.84;
//
// [secondImage drawInRect:CGRectMake(x, y, width, height)];
[secondImage drawInRect:CGRectMake(0, 0, 540, 540)];
UIImage *resImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return resImage;
}