我正在使用UIImagePicker加載圖片,我上傳到照片庫(在我的iPad上),但是它沒有alpha通道加載。 我有tripple檢查,以確保圖像有一個。除非它在同步到iTunes時被刪除?如何使用UIImagePicker加載圖片的阿爾法
這裏是代碼我使用的圖像拾取當它完成採摘:
-(void)imagePickerController: (UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info
{
//dissmiss picker
[imagePopOver dismissPopoverAnimated:YES];
//get the picker image
UIImage *image = [info objectForKey:@"UIImagePickerControllerOriginalImage"];
//create image view for selected image
UIImageView *imageView = [[UIImageView alloc] initWithImage:image];
imageView.frame = CGRectMake(0, 0, imageView.image.size.width, imageView.image.size.height);
imageView.center = CGPointMake(512, 384);
[imageLayer addSubview:imageView];
//release image and image view
[image release];
[imageView release];
}
我在做什麼錯?我希望這不是'Doh!'時刻。
歡迎來到計算器。你可以通過添加一些引用使這個答案更有用。 – CCoder