1 /*---------------------------------------------------------------------------*
2 Project: TwlSDK - PRC - include
3 File: prc/algo_light.h
4
5 Copyright 2003-2008 Nintendo. All rights reserved.
6
7 These coded instructions, statements, and computer programs contain
8 proprietary information of Nintendo of America Inc. and/or Nintendo
9 Company Ltd., and are protected by Federal copyright law. They may
10 not be disclosed to third parties or copied or duplicated in any form,
11 in whole or in part, without the prior written consent of Nintendo.
12
13 $Date:: 2008-09-18#$
14 $Rev: 8573 $
15 $Author: okubata_ryoma $
16 *---------------------------------------------------------------------------*/
17 #ifndef NITRO_PRC_ALGO_LIGHT_H_
18 #define NITRO_PRC_ALGO_LIGHT_H_
19
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23
24 #include <nitro/misc.h>
25 #include <nitro/types.h>
26 #include <nitro/prc/types.h>
27 #include <nitro/prc/common.h>
28 #include <nitro/prc/resample.h>
29 #include <nitro/prc/algo_common.h>
30
31 /*===========================================================================*
32 Constant Definitions
33 *===========================================================================*/
34
35 /*===========================================================================*
36 Type Definitions
37 *===========================================================================*/
38
39 /*---------------------------------------------------------------------------*
40 Parameters for Sample DB Expansion
41 normalizeSize Normalization Size
42 resampleThreshold post-normalization resample threshold
43 *---------------------------------------------------------------------------*/
44 typedef PRCPrototypeDBParam_Common PRCPrototypeDBParam_Light;
45
46 /*---------------------------------------------------------------------------*
47 Parameters for Input Pattern Interpretation
48 normalizeSize Normalization Size
49 resampleThreshold post-normalization resample threshold
50 *---------------------------------------------------------------------------*/
51 typedef PRCInputPatternParam_Common PRCInputPatternParam_Light;
52
53 /*---------------------------------------------------------------------------*
54 Input-Originating Recognition Pattern
55 *---------------------------------------------------------------------------*/
56 typedef PRCInputPattern_Common PRCInputPattern_Light;
57
58 /*---------------------------------------------------------------------------*
59 Sample DB Expanded in Memory
60 *---------------------------------------------------------------------------*/
61 typedef PRCPrototypeDB_Common PRCPrototypeDB_Light;
62
63 /*---------------------------------------------------------------------------*
64 Parameters for Recognition Processing
65 *---------------------------------------------------------------------------*/
66 typedef struct PRCRecognizeParam_Light
67 {
68 int dummy;
69 }
70 PRCRecognizeParam_Light;
71
72
73
74 /*---------------------------------------------------------------------------*
75 Name: PRC_Init_Light
76
77 Description: Initializes pattern recognition API.
78
79 Arguments: None.
80
81 Returns: None.
82 *---------------------------------------------------------------------------*/
PRC_Init_Light(void)83 static inline void PRC_Init_Light(void)
84 {
85 PRC_Init_Common();
86 }
87
88 /*---------------------------------------------------------------------------*
89 Name: PRC_GetPrototypeDBBufferSize_Light
90
91 Description: Calculates the work area size required for expanding sample DB.
92
93 Arguments: prototypeList sample pattern list
94
95 Returns: required memory capacity for expanding sample DB
96 *---------------------------------------------------------------------------*/
PRC_GetPrototypeDBBufferSize_Light(const PRCPrototypeList * prototypeList)97 static inline u32 PRC_GetPrototypeDBBufferSize_Light(const PRCPrototypeList *prototypeList)
98 {
99 return PRC_GetPrototypeDBBufferSize_Common(prototypeList);
100 }
101
102 /*---------------------------------------------------------------------------*
103 Name: PRC_GetPrototypeDBBufferSizeEx_Light
104
105 Description: Calculates the work area size required for expanding sample DB.
106
107 Arguments: prototypeList sample pattern list
108 kindMask mask for type specification
109 ignoreDisabledEntries Whether or not sample DB entries with the enabled flag FALSE are ever expanded.
110
111 param parameters for sample DB expansion
112
113 Returns: required memory capacity for expanding sample DB
114 *---------------------------------------------------------------------------*/
115 static inline u32
PRC_GetPrototypeDBBufferSizeEx_Light(const PRCPrototypeList * prototypeList,u32 kindMask,BOOL ignoreDisabledEntries,const PRCPrototypeDBParam_Light * param)116 PRC_GetPrototypeDBBufferSizeEx_Light(const PRCPrototypeList *prototypeList,
117 u32 kindMask,
118 BOOL ignoreDisabledEntries,
119 const PRCPrototypeDBParam_Light *param)
120 {
121 return PRC_GetPrototypeDBBufferSizeEx_Common(prototypeList, kindMask, ignoreDisabledEntries,
122 param);
123 }
124
125 /*---------------------------------------------------------------------------*
126 Name: PRC_InitPrototypeDB_Light
127
128 Description: Creates the PRCPrototypeDB structure.
129 A buffer region larger than the size that PRC_GetPrototypeDBBufferSize returns needs to be set up in the buffer.
130
131
132 Arguments: protoDB sample DB structure to be initialized
133 buffer pointer to memory region used for sample DB expansion
134 (Memory area size >= return value of PRC_GetPrototypeDBBufferSize)
135 prototypeList sample pattern list
136
137 Returns: TRUE if create succeeded.
138 *---------------------------------------------------------------------------*/
139 static inline BOOL
PRC_InitPrototypeDB_Light(PRCPrototypeDB_Light * protoDB,void * buffer,const PRCPrototypeList * prototypeList)140 PRC_InitPrototypeDB_Light(PRCPrototypeDB_Light *protoDB,
141 void *buffer, const PRCPrototypeList *prototypeList)
142 {
143 return PRC_InitPrototypeDB_Common(protoDB, buffer, prototypeList);
144 }
145
146 /*---------------------------------------------------------------------------*
147 Name: PRC_InitPrototypeDBEx_Light
148
149 Description: Creates the PRCPrototypeDB structure.
150 A buffer region larger than the size that PRC_GetPrototypeDBBufferSize returns needs to be set up in the buffer.
151
152 Parameters during expansion can be specified with param.
153
154 Arguments: protoDB sample DB structure to be initialized
155 buffer pointer to memory region used for sample DB expansion
156 (Memory area size >= return value of PRC_GetPrototypeDBBufferSize)
157 prototypeList sample pattern list
158 kindMask mask for type specification
159 ignoreDisabledEntries Whether or not sample DB entries with the enabled flag FALSE are ever expanded.
160
161 param parameters for sample DB expansion
162
163 Returns: TRUE if create succeeded.
164 *---------------------------------------------------------------------------*/
165 static inline BOOL
PRC_InitPrototypeDBEx_Light(PRCPrototypeDB_Light * protoDB,void * buffer,const PRCPrototypeList * prototypeList,u32 kindMask,BOOL ignoreDisabledEntries,const PRCPrototypeDBParam_Light * param)166 PRC_InitPrototypeDBEx_Light(PRCPrototypeDB_Light *protoDB,
167 void *buffer,
168 const PRCPrototypeList *prototypeList,
169 u32 kindMask,
170 BOOL ignoreDisabledEntries, const PRCPrototypeDBParam_Light *param)
171 {
172 return PRC_InitPrototypeDBEx_Common(protoDB, buffer, prototypeList, kindMask,
173 ignoreDisabledEntries, param);
174 }
175
176 /*---------------------------------------------------------------------------*
177 Name: PRC_GetInputPatternBufferSize_Light
178
179 Description: Calculates work area required for expanding pattern data for comparison.
180
181
182 Arguments: maxPointCount Upper limit of input points (includes stylus up marker)
183 maxStrokeCount Upper limit of stroke count
184
185 Returns: memory capacity required for expanding pattern
186 *---------------------------------------------------------------------------*/
PRC_GetInputPatternBufferSize_Light(int maxPointCount,int maxStrokeCount)187 static inline u32 PRC_GetInputPatternBufferSize_Light(int maxPointCount, int maxStrokeCount)
188 {
189 return PRC_GetInputPatternBufferSize_Common(maxPointCount, maxStrokeCount);
190 }
191
192 /*---------------------------------------------------------------------------*
193 Name: PRC_InitInputPattern_Light
194
195 Description: Creates PRCInputPattern structure.
196
197 Arguments: pattern pattern structure to be initialized
198 buffer pointer to memory region used for pattern expansion
199 (Region size >=return value of PRC_GetInputPatternBufferSize)
200 strokes Raw input coordinate value before forming
201 maxPointCount Upper limit of input points (includes stylus up marker)
202 maxStrokeCount Upper limit of stroke count
203
204 Returns: TRUE if create succeeded.
205 *---------------------------------------------------------------------------*/
206 static inline BOOL
PRC_InitInputPattern_Light(PRCInputPattern_Light * pattern,void * buffer,const PRCStrokes * strokes,int maxPointCount,int maxStrokeCount)207 PRC_InitInputPattern_Light(PRCInputPattern_Light *pattern,
208 void *buffer,
209 const PRCStrokes *strokes, int maxPointCount, int maxStrokeCount)
210 {
211 return PRC_InitInputPattern_Common(pattern, buffer, strokes, maxPointCount, maxStrokeCount);
212 }
213
214 /*---------------------------------------------------------------------------*
215 Name: PRC_InitInputPatternEx_Light
216
217 Description: Creates PRCInputPattern structure.
218 Specification of parameters for input pattern interpretation can be done with param.
219
220 Arguments: pattern pattern structure to be initialized
221 buffer pointer to memory region used for pattern expansion
222 (Region size >=return value of PRC_GetInputPatternBufferSize)
223 strokes Raw input coordinate value before forming
224 param parameters for input pattern interpretation
225
226 Returns: TRUE if create succeeded.
227 *---------------------------------------------------------------------------*/
228 static inline BOOL
PRC_InitInputPatternEx_Light(PRCInputPattern_Light * pattern,void * buffer,const PRCStrokes * strokes,int maxPointCount,int maxStrokeCount,const PRCInputPatternParam_Light * param)229 PRC_InitInputPatternEx_Light(PRCInputPattern_Light *pattern,
230 void *buffer,
231 const PRCStrokes *strokes,
232 int maxPointCount,
233 int maxStrokeCount, const PRCInputPatternParam_Light *param)
234 {
235 return PRC_InitInputPatternEx_Common(pattern, buffer, strokes, maxPointCount, maxStrokeCount,
236 param);
237 }
238
239 /*---------------------------------------------------------------------------*
240 Name: PRC_GetRecognitionBufferSizeEx_Light
241
242 Description: Calculates the work area size required for recognition algorithm.
243
244
245 Arguments: maxPointCount Upper limit of input points (includes stylus up marker)
246 maxStrokeCount Upper limit of stroke count
247 protoDB sample DB
248 param parameters for recognition processing
249
250 Returns: The memory capacity required for the recognition algorithm.
251 *---------------------------------------------------------------------------*/
252 u32
253
254
255 PRC_GetRecognitionBufferSizeEx_Light(int maxPointCount,
256 int maxStrokeCount,
257 const PRCPrototypeDB_Light *protoDB,
258 const PRCRecognizeParam_Light *param);
259
260 /*---------------------------------------------------------------------------*
261 Name: PRC_GetRecognitionBufferSize_Light
262
263 Description: Calculates the work area size required for recognition algorithm.
264
265
266 Arguments: maxPointCount Upper limit of input points (includes stylus up marker)
267 maxStrokeCount Upper limit of stroke count
268 protoDB sample DB
269
270 Returns: The memory capacity required for the recognition algorithm.
271 *---------------------------------------------------------------------------*/
272 static inline u32
PRC_GetRecognitionBufferSize_Light(int maxPointCount,int maxStrokeCount,const PRCPrototypeDB_Light * protoDB)273 PRC_GetRecognitionBufferSize_Light(int maxPointCount,
274 int maxStrokeCount, const PRCPrototypeDB_Light *protoDB)
275 {
276 return PRC_GetRecognitionBufferSizeEx_Light(maxPointCount, maxStrokeCount, protoDB, NULL);
277 }
278
279 /*---------------------------------------------------------------------------*
280 Name: PRC_GetRecognizedEntriesEx_Light
281
282 Description: Compares and recognizes a specific kind entry and input pattern to return the top numRanking ranking of the result.
283
284
285 Arguments: resultEntries Pointer to array that holds pointer to recognition result.
286 If less than the requested number could be recognized, fill in remainder with NULL.
287
288 resultScores pointer to recognition result score array
289 numRanking Number of returns to result*
290 buffer Pointer to memory region used by recognition algorithm
291 (Region size >= return value of PRC_GetRecognitionBufferSize)
292 input Input pattern
293 protoDB sample DB
294 kindMask Take the AND of kind values for each sample DB entry, with any non-zero values considered valid.
295
296 param parameters for recognition processing
297
298 Returns: Number of compared patterns in the sample DB
299 *---------------------------------------------------------------------------*/
300 int
301
302
303 PRC_GetRecognizedEntriesEx_Light(PRCPrototypeEntry **resultEntries,
304 fx32 *resultScores,
305 int numRanking,
306 void *buffer,
307 const PRCInputPattern_Light *input,
308 const PRCPrototypeDB_Light *protoDB,
309 u32 kindMask, const PRCRecognizeParam_Light *param);
310
311 /*---------------------------------------------------------------------------*
312 Name: PRC_GetRecognizedEntries_Light
313
314 Description: Compares and recognizes sample DB input patterns, and returns the top numRanking ranking of the result.
315
316
317 Arguments: resultEntries Pointer to array that holds pointer to recognition result.
318 If less than the requested number could be recognized, fill in remainder with NULL.
319
320 resultScores pointer to recognition result score array
321 numRanking the number of items desired to be returned to result*
322 buffer Pointer to memory region used by recognition algorithm
323 (Region size >= return value of PRC_GetRecognitionBufferSize)
324 input Input pattern
325 protoDB sample DB
326
327 Returns: Number of compared patterns in the sample DB
328 *---------------------------------------------------------------------------*/
329 static inline int
PRC_GetRecognizedEntries_Light(PRCPrototypeEntry ** resultEntries,fx32 * resultScores,int numRanking,void * buffer,const PRCInputPattern_Light * input,const PRCPrototypeDB_Light * protoDB)330 PRC_GetRecognizedEntries_Light(PRCPrototypeEntry **resultEntries,
331 fx32 *resultScores,
332 int numRanking,
333 void *buffer,
334 const PRCInputPattern_Light *input,
335 const PRCPrototypeDB_Light *protoDB)
336 {
337 return PRC_GetRecognizedEntriesEx_Light(resultEntries, resultScores, numRanking, buffer, input,
338 protoDB, PRC_KIND_ALL, NULL);
339 }
340
341 /*---------------------------------------------------------------------------*
342 Name: PRC_GetRecognizedEntryEx_Light
343
344 Description: Compares and recognizes a specific kind entry and input pattern for the sample DB.
345
346 Arguments: resultEntry Pointer that receives pointer to recognized sample DB entry.
347 If could not recognize, NULL is entered.
348 buffer Pointer to memory region used by recognition algorithm
349 (Region size >= return value of PRC_GetRecognitionBufferSize)
350 input Input pattern
351 protoDB sample DB
352 kindMask Take the AND of kind values for each sample DB entry, with any non-zero values considered valid.
353
354 param parameters for recognition processing
355
356 Returns: score value
357 *---------------------------------------------------------------------------*/
358 static inline fx32
PRC_GetRecognizedEntryEx_Light(PRCPrototypeEntry ** resultEntry,void * buffer,const PRCInputPattern_Light * input,const PRCPrototypeDB_Light * protoDB,u32 kindMask,const PRCRecognizeParam_Light * param)359 PRC_GetRecognizedEntryEx_Light(PRCPrototypeEntry **resultEntry,
360 void *buffer,
361 const PRCInputPattern_Light *input,
362 const PRCPrototypeDB_Light *protoDB,
363 u32 kindMask, const PRCRecognizeParam_Light *param)
364 {
365 fx32 score;
366 (void)PRC_GetRecognizedEntriesEx_Light(resultEntry, &score, 1, buffer, input, protoDB, kindMask,
367 param);
368 return score;
369 }
370
371 /*---------------------------------------------------------------------------*
372 Name: PRC_GetRecognizedEntry_Light
373
374 Description: Compares and recognizes sample DB and input pattern.
375
376 Arguments: resultEntry Pointer that receives pointer to recognized sample DB entry.
377 If could not recognize, NULL is entered.
378 buffer Pointer to memory region used by recognition algorithm
379 (Region size >= return value of PRC_GetRecognitionBufferSize)
380 input Input pattern
381 protoDB sample DB
382
383 Returns: score value
384 *---------------------------------------------------------------------------*/
385 static inline fx32
PRC_GetRecognizedEntry_Light(PRCPrototypeEntry ** resultEntry,void * buffer,const PRCInputPattern_Light * input,const PRCPrototypeDB_Light * protoDB)386 PRC_GetRecognizedEntry_Light(PRCPrototypeEntry **resultEntry,
387 void *buffer,
388 const PRCInputPattern_Light *input,
389 const PRCPrototypeDB_Light *protoDB)
390 {
391 return PRC_GetRecognizedEntryEx_Light(resultEntry, buffer, input, protoDB, PRC_KIND_ALL, NULL);
392 }
393
394 /*---------------------------------------------------------------------------*
395 Name: PRC_GetInputPatternStrokes_Light
396
397 Description: Gets dot sequence data from PRCInputPattern structure.
398
399 Arguments: strokes: Obtained dot sequence data
400 Overwriting is not permitted.
401 input Input pattern
402
403 Returns: None.
404 *---------------------------------------------------------------------------*/
405 static inline void
PRC_GetInputPatternStrokes_Light(PRCStrokes * strokes,const PRCInputPattern_Light * input)406 PRC_GetInputPatternStrokes_Light(PRCStrokes *strokes, const PRCInputPattern_Light *input)
407 {
408 PRC_GetInputPatternStrokes_Common(strokes, input);
409 }
410
411
412 /*===========================================================================*
413 Inline Functions
414 *===========================================================================*/
415
416
417
418
419 /*===========================================================================*
420 Set as the standard function of the graphics recognition API
421 *===========================================================================*/
422 #ifndef PRC_DEFAULT_ALGORITHM
423 #define PRC_DEFAULT_ALGORITHM "Light"
424
425 /*---------------------------------------------------------------------------*
426 Parameters for Sample DB Expansion
427 *---------------------------------------------------------------------------*/
428 typedef PRCPrototypeDBParam_Light PRCPrototypeDBParam;
429
430 /*---------------------------------------------------------------------------*
431 Parameters for Input Pattern Interpretation
432 *---------------------------------------------------------------------------*/
433 typedef PRCInputPatternParam_Light PRCInputPatternParam;
434
435 /*---------------------------------------------------------------------------*
436 Input-Originating Recognition Pattern
437 *---------------------------------------------------------------------------*/
438 typedef PRCInputPattern_Light PRCInputPattern;
439
440 /*---------------------------------------------------------------------------*
441 Sample DB Expanded in Memory
442 *---------------------------------------------------------------------------*/
443 typedef PRCPrototypeDB_Light PRCPrototypeDB;
444
445 /*---------------------------------------------------------------------------*
446 Parameters for Recognition Processing
447 *---------------------------------------------------------------------------*/
448 typedef PRCRecognizeParam_Light PRCRecognizeParam;
449
450
451 /*---------------------------------------------------------------------------*
452 Functions
453 *---------------------------------------------------------------------------*/
PRC_Init(void)454 static inline void PRC_Init(void)
455 {
456 PRC_Init_Light();
457 }
458
PRC_GetPrototypeDBBufferSize(const PRCPrototypeList * prototypeList)459 static inline u32 PRC_GetPrototypeDBBufferSize(const PRCPrototypeList *prototypeList)
460 {
461 return PRC_GetPrototypeDBBufferSize_Light(prototypeList);
462 }
463
464 static inline u32
PRC_GetPrototypeDBBufferSizeEx(const PRCPrototypeList * prototypeList,u32 kindMask,BOOL ignoreDisabledEntries,const PRCPrototypeDBParam * param)465 PRC_GetPrototypeDBBufferSizeEx(const PRCPrototypeList *prototypeList,
466 u32 kindMask,
467 BOOL ignoreDisabledEntries, const PRCPrototypeDBParam *param)
468 {
469 return PRC_GetPrototypeDBBufferSizeEx_Light(prototypeList, kindMask, ignoreDisabledEntries,
470 param);
471 }
472
473 static inline BOOL
PRC_InitPrototypeDB(PRCPrototypeDB * protoDB,void * buffer,const PRCPrototypeList * prototypeList)474 PRC_InitPrototypeDB(PRCPrototypeDB *protoDB, void *buffer, const PRCPrototypeList *prototypeList)
475 {
476 return PRC_InitPrototypeDB_Light(protoDB, buffer, prototypeList);
477 }
478
479 static inline BOOL
PRC_InitPrototypeDBEx(PRCPrototypeDB * protoDB,void * buffer,const PRCPrototypeList * prototypeList,u32 kindMask,BOOL ignoreDisabledEntries,const PRCPrototypeDBParam * param)480 PRC_InitPrototypeDBEx(PRCPrototypeDB *protoDB,
481 void *buffer,
482 const PRCPrototypeList *prototypeList,
483 u32 kindMask, BOOL ignoreDisabledEntries, const PRCPrototypeDBParam *param)
484 {
485 return PRC_InitPrototypeDBEx_Light(protoDB, buffer, prototypeList, kindMask,
486 ignoreDisabledEntries, param);
487 }
488
PRC_GetInputPatternBufferSize(int maxPointCount,int maxStrokeCount)489 static inline u32 PRC_GetInputPatternBufferSize(int maxPointCount, int maxStrokeCount)
490 {
491 return PRC_GetInputPatternBufferSize_Light(maxPointCount, maxStrokeCount);
492 }
493
494 static inline BOOL
PRC_InitInputPattern(PRCInputPattern * pattern,void * buffer,const PRCStrokes * strokes,int maxPointCount,int maxStrokeCount)495 PRC_InitInputPattern(PRCInputPattern *pattern,
496 void *buffer, const PRCStrokes *strokes, int maxPointCount, int maxStrokeCount)
497 {
498 return PRC_InitInputPattern_Light(pattern, buffer, strokes, maxPointCount, maxStrokeCount);
499 }
500
501 static inline BOOL
PRC_InitInputPatternEx(PRCInputPattern * pattern,void * buffer,const PRCStrokes * strokes,int maxPointCount,int maxStrokeCount,const PRCInputPatternParam * param)502 PRC_InitInputPatternEx(PRCInputPattern *pattern,
503 void *buffer,
504 const PRCStrokes *strokes,
505 int maxPointCount, int maxStrokeCount, const PRCInputPatternParam *param)
506 {
507 return PRC_InitInputPatternEx_Light(pattern, buffer, strokes, maxPointCount, maxStrokeCount,
508 param);
509 }
510
511 static inline u32
PRC_GetRecognitionBufferSize(int maxPointCount,int maxStrokeCount,const PRCPrototypeDB_Light * protoDB)512 PRC_GetRecognitionBufferSize(int maxPointCount,
513 int maxStrokeCount, const PRCPrototypeDB_Light *protoDB)
514 {
515 return PRC_GetRecognitionBufferSize_Light(maxPointCount, maxStrokeCount, protoDB);
516 }
517
518 static inline u32
PRC_GetRecognitionBufferSizeEx(int maxPointCount,int maxStrokeCount,const PRCPrototypeDB_Light * protoDB,const PRCRecognizeParam_Light * param)519 PRC_GetRecognitionBufferSizeEx(int maxPointCount,
520 int maxStrokeCount,
521 const PRCPrototypeDB_Light *protoDB,
522 const PRCRecognizeParam_Light *param)
523 {
524 return PRC_GetRecognitionBufferSizeEx_Light(maxPointCount, maxStrokeCount, protoDB, param);
525 }
526
527 static inline fx32
PRC_GetRecognizedEntry(PRCPrototypeEntry ** resultEntry,void * buffer,const PRCInputPattern * input,const PRCPrototypeDB * protoDB)528 PRC_GetRecognizedEntry(PRCPrototypeEntry **resultEntry,
529 void *buffer, const PRCInputPattern *input, const PRCPrototypeDB *protoDB)
530 {
531 return PRC_GetRecognizedEntry_Light(resultEntry, buffer, input, protoDB);
532 }
533
534 static inline fx32
PRC_GetRecognizedEntryEx(PRCPrototypeEntry ** resultEntry,void * buffer,const PRCInputPattern * input,const PRCPrototypeDB * protoDB,u32 kindMask,const PRCRecognizeParam * param)535 PRC_GetRecognizedEntryEx(PRCPrototypeEntry **resultEntry,
536 void *buffer,
537 const PRCInputPattern *input,
538 const PRCPrototypeDB *protoDB,
539 u32 kindMask, const PRCRecognizeParam *param)
540 {
541 return PRC_GetRecognizedEntryEx_Light(resultEntry, buffer, input, protoDB, kindMask, param);
542 }
543
544 static inline int
PRC_GetRecognizedEntries(PRCPrototypeEntry ** resultEntries,fx32 * resultScores,int numRanking,void * buffer,const PRCInputPattern * input,const PRCPrototypeDB * protoDB)545 PRC_GetRecognizedEntries(PRCPrototypeEntry **resultEntries,
546 fx32 *resultScores,
547 int numRanking,
548 void *buffer, const PRCInputPattern *input, const PRCPrototypeDB *protoDB)
549 {
550 return PRC_GetRecognizedEntries_Light(resultEntries, resultScores, numRanking, buffer, input,
551 protoDB);
552 }
553
554 static inline int
PRC_GetRecognizedEntriesEx(PRCPrototypeEntry ** resultEntries,fx32 * resultScores,int numRanking,void * buffer,const PRCInputPattern * input,const PRCPrototypeDB * protoDB,u32 kindMask,const PRCRecognizeParam * param)555 PRC_GetRecognizedEntriesEx(PRCPrototypeEntry **resultEntries,
556 fx32 *resultScores,
557 int numRanking,
558 void *buffer,
559 const PRCInputPattern *input,
560 const PRCPrototypeDB *protoDB,
561 u32 kindMask, const PRCRecognizeParam *param)
562 {
563 return PRC_GetRecognizedEntriesEx_Light(resultEntries, resultScores, numRanking, buffer, input,
564 protoDB, kindMask, param);
565 }
566
PRC_GetInputPatternStrokes(PRCStrokes * strokes,const PRCInputPattern * input)567 static inline void PRC_GetInputPatternStrokes(PRCStrokes *strokes, const PRCInputPattern *input)
568 {
569 PRC_GetInputPatternStrokes_Light(strokes, input);
570 }
571
572 #endif // PRC_DEFAULT_ALGORITHM
573
574
575
576
577 #ifdef __cplusplus
578 } /* extern "C" */
579 #endif
580
581 /* NITRO_PRC_ALGO_LIGHT_H_ */
582 #endif
583