是否有可能让应用程序查找"某些功能"在一张照片

时间:2014-08-22 03:00:31

标签: ios camera

我想创建一个应用程序,让您拍摄一张您不知道的音乐笔记,应用程序将分析照片以查看该笔记的内容。我是编码的新手,所以任何帮助都会很棒。该应用程序将类似于应用程序快照播放,但它不会播放音符,而是告诉您它是什么音符。

到目前为止,这是我的代码。

(ViewController.m)

#import "ViewController.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad
{
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
}
- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}
- (IBAction)takePhoto:(id)sender {

    picker = [[UIImagePickerController alloc] init];
    picker.delegate = self;
    [picker setSourceType:UIImagePickerControllerSourceTypeCamera];
    [self presentViewController:picker animated:YES completion:NULL];

}

-(void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info {

    image = [info objectForKey:@"UIImagePickerControllerOriginalImage"];
    [imageView setImage:image];
    [self dismissViewControllerAnimated:YES completion:NULL];
}

-(void)imagePickerControllerDidCancel:(UIImagePickerController *)picker {

    [self dismissViewControllerAnimated:YES completion:NULL];
}
#pragma mark iAd Delagate Methods

-(void)bannerViewDidLoadAd:(ADBannerView *)banner {

    [UIView beginAnimations:nil context:nil];

    [UIView setAnimationDuration:1];

    [banner setAlpha:1];

    [UIView commitAnimations];


}

@end

(VeiwController.h)

#import <UIKit/UIKit.h>
#import <iAd/iAd.h>

@interface ViewController : UIViewController <UINavigationControllerDelegate,UIImagePickerControllerDelegate> {

     IBOutlet UIImageView *imageView;

    UIImagePickerController *picker;
    UIImage *image;
}

- (IBAction)takePhoto:(id)sender;



@end

由于

1 个答案:

答案 0 :(得分:2)

这是可能的。它需要图像识别。但是,这不是Stack Overflow帖子中可以回答的问题。

尝试在线搜索图像识别算法。