Documentation ¶
Index ¶
- func Version() string
- type BoxCharacter
- type BoxText
- type Tess
- func (t *Tess) AvailableLanguages() []string
- func (tess *Tess) BoxText(pagenumber int) (*BoxText, error)
- func (t *Tess) BoxTextRaw(pagenumber int) string
- func (t *Tess) Clear()
- func (t *Tess) Close()
- func (t *Tess) DumpVariables()
- func (t *Tess) HOCRText(pagenumber int) string
- func (t *Tess) InitializedLanguages() string
- func (t *Tess) LoadedLanguages() []string
- func (t *Tess) SetImagePix(pix *leptonica.Pix)
- func (t *Tess) SetInputName(filename string)
- func (t *Tess) Text() string
- func (t *Tess) UNLVText() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BoxCharacter ¶
type BoxText ¶
type BoxText struct {
Characters []BoxCharacter
}
TODO: make this: `type BoxText []BoxCharacter` ?
type Tess ¶
type Tess struct {
// contains filtered or unexported fields
}
Tess represents a tesseract instance
func (*Tess) AvailableLanguages ¶
AvailableLanguages returns the languages available to the given tesseract instance. To find the languages actually loaded use (*Tess).LoadedLanguages().
func (*Tess) BoxTextRaw ¶
BoxTextRaw returns the raw box text for given pagenumber
func (*Tess) Clear ¶
func (t *Tess) Clear()
Clear frees up recognition results and any stored image data, without actually freeing any recognition data that would be time-consuming to reload. Afterwards, you must call SetImagePix before doing any Recognize or Get* operation.
func (*Tess) DumpVariables ¶
func (t *Tess) DumpVariables()
DumpVariables dumps the variables set on a Tess to stdout
func (*Tess) InitializedLanguages ¶
InitializedLanguages returns the languages string used in the last valid initialization. If the last initialization specified "deu+hin" then that will be returned. If hin loaded eng automatically as well, then that will not be included in this list. To find the languages actually loaded use (*Tess).LoadedLanguages().
func (*Tess) LoadedLanguages ¶
LoadedLanguages returns the loaded languages in the vector of STRINGs. Includes all languages loaded for the given tesseract instance, including those loaded as dependencies of other loaded languages.
func (*Tess) SetImagePix ¶
func (t *Tess) SetImagePix(pix *leptonica.Pix)
SetImagePix sets the input image using a leptonica Pix
func (*Tess) SetInputName ¶
SetInputName sets the name of the input file. Needed only for training and loading a UNLV zone file. ++ TODO: drop this?