2010-06-07 7 views

답변

0

경고 : 코드는 대답 상자에 입력하고 테스트하지 않았습니다. 그래도 꽤 가깝습니다.

NSSize newSize = [self getSizeFromUser]; // you have to write this part. 
CGRect theRect = CGRectMake (0, 0, newSize.width, newSize.height); 

// Put image into new context 
UIGraphicsBeginImageContext (newSize); 
    [theImage drawInRect: theRect]; 
    //get the image from the context 
    UIImage *newImage = UIGraphicsGetImageFromCurrentImageContext(); 
    [[compositeImage retain] autorelease]; 
UIGraphicsEndImageContext(); 
관련 문제