0
我修復了我的應用程序的方向爲橫向只。Facebook圖形API - 錯誤的圖像方向
這是我如何獲得截圖。
UIImage *img = UIGraphicsGetImageFromCurrentImageContext();
,我通過
UIImage * landscapeImage = [[UIImage alloc] initWithCGImage: img.CGImage scale: 1.0 orientation: UIImageOrientationRight];
我用FB iOS版SDK發佈的截圖給Facebook改變方向。
NSMutableDictionary *params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
landscapeImage, @"picture",
SOME_URL,@"link",
@"Have fun",@"name",
@"Join the fun",@"message",
@"0",@"position",
nil];
[_facebook requestWithGraphPath:@"me/photos"
andParams:params
andHttpMethod:@"POST"
andDelegate:self];
的問題是我無法控制的方向和上傳圖像的方向總是要麼
-----
| |
| P |
-----
或
-----
| |
| q |
-----
,但我想要的形象水平放置(景觀)。
-------
| |
-------
在此先感謝!