tesseract  4.1.1
mfdefs.cpp File Reference
#include "mfdefs.h"
#include "emalloc.h"
#include <cmath>

Go to the source code of this file.

Functions

MICROFEATURE NewMicroFeature ()
 
void FreeMicroFeatures (MICROFEATURES MicroFeatures)
 

Function Documentation

◆ FreeMicroFeatures()

void FreeMicroFeatures ( MICROFEATURES  MicroFeatures)

This routine deallocates all of the memory consumed by a list of micro-features.

Parameters
MicroFeatureslist of micro-features to be freed

Definition at line 42 of file mfdefs.cpp.

42  {
43  destroy_nodes(MicroFeatures, Efree);
44 } /* FreeMicroFeatures */

◆ NewMicroFeature()

MICROFEATURE NewMicroFeature ( )

This routine allocates and returns a new micro-feature data structure.

Returns
New MICROFEATURE

Definition at line 33 of file mfdefs.cpp.

33  {
34  return (static_cast<MICROFEATURE>(Emalloc (sizeof (MFBLOCK))));
35 } /* NewMicroFeature */
Efree
void Efree(void *ptr)
Definition: emalloc.cpp:45
MFBLOCK
float MFBLOCK[MFSIZE]
Definition: mfdefs.h:32
MICROFEATURE
float * MICROFEATURE
Definition: mfdefs.h:33
Emalloc
void * Emalloc(int Size)
Definition: emalloc.cpp:31
destroy_nodes
void destroy_nodes(LIST list, void_dest destructor)
Definition: oldlist.cpp:157