//
// RootViewController.m
// InvokPhoto
//
// Copyright (c) 2015年 朝夕. All rights reserved.
//
#import "RootViewController.h"
@interface RootViewController ()
@property (nonatomic, retain) UIImageView *imageView;
@end
@implementation RootViewController
- (void)viewDidLoad {
[super viewDidLoad];
self.view.backgroundColor = [UIColor whiteColor];
self.navigationItem.title = @"相册";
// 保存图片到相册
// [self saveImage];
//访问相册
[self visitPhoto];
//调用摄像头
[self camera];
}
#pragma mark -- 访问相册
- (void)visitPhoto{
UIBarButtonItem *rigthBtn = [[UIBarButtonItem alloc] initWithTitle:@"访问相册" style:(UIBarButtonItemStyleDone) target:self action:@selector(selectPhoto:)];
self.navigationItem.rightBarButtonItem = rigthBtn;
[rigthBtn release];
self.imageView = [[UIImageView alloc] initWithFrame:CGRectMake(100, 350, 2
OC学习之道:UIImagePickerController的使用,使用UIImagePickerController调用本地摄像头,本地相册
最新推荐文章于 2023-11-26 21:19:51 发布