如何添加按钮“上传”在Iphone中使用相机时?

我有一个tableView,我想点击其中一个单元格并将其上传到某个服务器时拍照。 到目前为止,我设法做到了这一点:
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {


//do actions
UIImagePickerController *picker = [[UIImagePickerController alloc] init];

// Set the image picker source to the camera:
picker.sourceType = UIImagePickerControllerSourceTypeCamera;

// Hide the camera controls:
picker.showsCameraControls = YES;
picker.navigationBarHidden = NO;

// Make the view full screen:
picker.wantsFullScreenLayout = YES;
//picker.cameraViewTransform = CGAffineTransformScale(picker.cameraViewTransform, CAMERA_TRANSFORM_X, CAMERA_TRANSFORM_Y);

// Now insert our overlay view (it has to be here cuz it's a modal view):
//picker.cameraOverlayView = overlayView;

matches *aMatch = [appDelegate.matches objectAtIndex:indexPath.row];
NSLog(@"%@", [NSString stringWithFormat:@"%d", aMatch.match_id]);

// Show the picker:
[self presentModalViewController:picker animated:YES];


[picker release];
} 它启动相机并拍照,但我想在点击“使用”时获得“上传”按钮,你能帮帮我吗?它可以吗? (比如facebook应用) 顺便说一句,当我点击使用它回到表格视图,但图像在哪里?是保存在选择器中吗?     
已邀请:
你可以在图像选择器控制器的委托方法中获取图像 - (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingImage:(UIImage *)img editingInfo:(NSDictionary *)editInfo { //在这里编写你的代码以保存你的UIImage对象中的图像,例如: UIImage * myImage = img; //从此处添加上传按钮,或者如果您之前已创建上传按钮并将ti设置为隐藏,则将其隐藏属性设置为false }     
也许我没有解释自己很好,但这里是我尝试做的一个例子(通过添加上传按钮自定义相机的外观):http://developer.apple.com/library/ios/ #samplecode / PhotoPicker /介绍/ Intro.html%23 // apple_ref / DOC / UID / DTS40010196-简介-DontLinkElementID_2 谢谢。     

要回复问题请先登录注册