650e924336e3a53d34af73dd4015f518df9fe2e3
[platform/framework/native/vision.git] / src / QRCodeRecognitionInfo.h
1 //
2 // Tizen C++ SDK
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Flora License, Version 1.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 //     http://floralicense.org/license
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an AS IS BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17
18 #ifndef QRCODERECOGNITIONINFO_H
19 #define QRCODERECOGNITIONINFO_H
20
21 #include "QRCodeTypes.h"
22
23 namespace sari2
24 {
25
26 class QRCodeRecognitionInfo
27 {
28
29 friend class QRCodeRecognizer;
30
31 public:
32         QRCodeRecognitionInfo();
33         ~QRCodeRecognitionInfo();
34         QRCodeRecognitionInfo(const QRCodeRecognitionInfo&);
35         QRCodeRecognitionInfo& operator=(const QRCodeRecognitionInfo&);
36
37     inline unsigned char id() const { return mId; }
38
39     inline unsigned char version() const { return mVersion; }
40
41     inline QRCodeErrorCorrectionLevel errorCorrectionLevel() const { return mErrorCorrectionLevel; }
42
43     inline const char* text() const { return mText; }
44
45     inline const float* transform() const { return mTransform; }
46
47     void rectangle(float *coordinates) const;
48
49 private:
50
51     unsigned char mId;
52     unsigned char mVersion;
53     QRCodeErrorCorrectionLevel mErrorCorrectionLevel;
54     char* mText;
55     float mTransform[16];
56     const float *mLeft, *mRight;
57 };
58
59 }
60 #endif // QRCODERECOGNITIONINFO_H