~ubuntu-branches/ubuntu/utopic/sikuli/utopic

« back to all changes in this revision

Viewing changes to sikuli-script/src/main/native/vision.h

  • Committer: Bazaar Package Importer
  • Author(s): Gilles Filippini
  • Date: 2011-10-04 23:32:13 UTC
  • mfrom: (4.1.2 sid)
  • Revision ID: james.westby@ubuntu.com-20111004233213-36fm78hx0z53tkuw
Tags: 1.0~x~rc3-dfsg1-2
* New patch fix-cmake-sikuli-ide.patch:
  + Fix random FTBFS due to missing inter target dependency

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
 
 *  vision.h
3
 
 *  sikuli
4
 
 *
5
 
 *  Created by Tom Yeh on 8/1/10.
6
 
 *  Copyright 2010 __MyCompanyName__. All rights reserved.
 
2
 * Copyright 2010-2011, Sikuli.org
 
3
 * Released under the MIT License.
7
4
 *
8
5
 */
9
6
 
13
10
#include "find-result.h"
14
11
#include "opencv.hpp"
15
12
#include "tessocr.h"
 
13
#include "cvgui.h"
16
14
 
17
15
using namespace cv;
18
16
 
81
79
};
82
80
 
83
81
class Vision{
 
82
   static std::map<std::string, float> _params;
 
83
   static void initParameters();
 
84
 
84
85
public:
85
86
      
86
 
   static vector<FindResult> find(FindInput q);
 
87
   static std::vector<FindResult> find(FindInput q);
87
88
 
88
89
   static std::vector<FindResult> findChanges(FindInput q);
89
90
   
95
96
   static string query(const char* index_filename, cv::Mat image);
96
97
   
97
98
   static OCRText recognize_as_ocrtext(cv::Mat image);
 
99
   
 
100
   static std::vector<FindResult> findBlobs(const cv::Mat& image);
98
101
      
99
102
   static std::string recognize(cv::Mat image);
100
103
 
101
104
   //helper functions
102
105
   static cv::Mat createMat(int _rows, int _cols, unsigned char* _data);
103
106
 
 
107
   static void setParameter(std::string param, float val);
 
108
   static float getParameter(std::string param);
 
109
 
104
110
private:   
105
111
      
106
112
};