• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2008 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #ifndef btk_SDK_Internal_EM_H
18 #define btk_SDK_Internal_EM_H
19 
20 /**
21  *  SDK object
22  */
23 
24 /* ---- includes ----------------------------------------------------------- */
25 
26 #include "SDK.h"
27 #include "b_BasicEm/Context.h"
28 
29 /* ---- related objects  --------------------------------------------------- */
30 
31 /* ---- typedefs ----------------------------------------------------------- */
32 
33 /** function return status */
34 typedef enum
35 {
36 	/** sdk handle id */
37 	btk_HID_SDK,
38 
39 	/** dcr handle id */
40 	btk_HID_DCR,
41 
42 	/** face finder handle id */
43 	btk_HID_FF
44 
45 } btk_HandleId;
46 
47 
48 /** SDK context object */
49 struct btk_SDK
50 {
51 	/** context (must occur as first element) */
52 	struct bbs_Context contextE;
53 
54 	/** handle id */
55 	btk_HandleId hidE;
56 
57 	/** reference counter */
58 	u32 refCtrE;
59 
60 	/** ptr to malloc function */
61 	btk_fpMalloc mallocFPtrE;
62 
63 	/** ptr to free function */
64 	btk_fpFree freeFPtrE;
65 
66 	/** error handler function pointer */
67 	btk_fpError errorFPtrE;
68 
69 	/* maximum image witdh used */
70 	u32 maxImageWidthE;
71 
72 	/* maximum image height used */
73 	u32 maxImageHeightE;
74 };
75 
76 /* ---- constants ---------------------------------------------------------- */
77 
78 /* ---- functions ---------------------------------------------------------- */
79 
80 /** tests parameter consistency */
81 btk_Status btk_SDK_paramConsistencyTest( struct btk_SDK* hsdkA,
82 										 const void* memPtrA,
83 										 u32 memSizeA,
84 										 const char* fNameA );
85 
86 #endif /* btk_SDK_Internal_EM_H */
87