~ubuntu-branches/ubuntu/vivid/tesseract/vivid

« back to all changes in this revision

Viewing changes to training/commontraining.h

  • Committer: Package Import Robot
  • Author(s): Jeff Breidenbach
  • Date: 2014-02-03 11:10:20 UTC
  • mfrom: (1.3.1) (19.1.1 experimental)
  • Revision ID: package-import@ubuntu.com-20140203111020-igquodd7pjlp3uri
Tags: 3.03.01-1
* New upstream release, includes critical fix to PDF rendering
* Complete leptonlib transition (see bug #735509)
* Promote from experimental to unstable

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
#ifndef TESSERACT_TRAINING_COMMONTRAINING_H__
15
15
#define TESSERACT_TRAINING_COMMONTRAINING_H__
16
16
 
17
 
#include "oldlist.h"
18
17
#include "cluster.h"
 
18
#include "commandlineflags.h"
 
19
#include "featdefs.h"
19
20
#include "intproto.h"
20
 
#include "featdefs.h"
21
 
 
22
 
// Macros to merge tesseract params with command-line flags.
23
 
#ifdef USE_STD_NAMESPACE
24
 
#include "params.h"
25
 
#  define INT_PARAM_FLAG(name, val, comment) \
26
 
    INT_VAR(FLAGS_##name, val, comment)
27
 
#  define DECLARE_INT_PARAM_FLAG(name) extern INT_VAR_H(FLAGS_##name, 0, "")
28
 
#  define STRING_PARAM_FLAG(name, val, comment) \
29
 
    STRING_VAR(FLAGS_##name, val, comment)
30
 
#  define DECLARE_STRING_PARAM_FLAG(name) \
31
 
    extern STRING_VAR_H(FLAGS_##name, "", "")
32
 
#  define c_str string
33
 
#else
34
 
#include "base/commandlineflags.h"
35
 
#  define INT_PARAM_FLAG(name, val, comment) \
36
 
    DEFINE_int32(name, val, comment)
37
 
#  define DECLARE_INT_PARAM_FLAG(name) DECLARE_int32(name)
38
 
#  define STRING_PARAM_FLAG(name, val, comment) \
39
 
    DEFINE_string(name, val, comment)
40
 
#  define DECLARE_STRING_PARAM_FLAG(name) DECLARE_string(name)
41
 
#endif
 
21
#include "oldlist.h"
42
22
 
43
23
namespace tesseract {
44
24
class Classify;
82
62
void ParseArguments(int* argc, char*** argv);
83
63
 
84
64
namespace tesseract {
 
65
 
85
66
// Helper loads shape table from the given file.
86
67
ShapeTable* LoadShapeTable(const STRING& file_prefix);
87
68
// Helper to write the shape_table.