tesseract  4.00.00dev
polyblk.cpp File Reference
#include "polyblk.h"
#include <ctype.h>
#include <math.h>
#include <stdio.h>
#include <memory>
#include "elst.h"

Go to the source code of this file.

Macros

#define PBLOCK_LABEL_SIZE   150
 
#define INTERSECTING   MAX_INT16
 

Functions

POLY_BLOCK::reflect_in_y_axis

Reflect the coords of the polygon in the y-axis. (Flip the sign of x.)

int lessthan (const void *first, const void *second)
 

Macro Definition Documentation

◆ INTERSECTING

#define INTERSECTING   MAX_INT16

Definition at line 33 of file polyblk.cpp.

◆ PBLOCK_LABEL_SIZE

#define PBLOCK_LABEL_SIZE   150

Definition at line 32 of file polyblk.cpp.

Function Documentation

◆ lessthan()

int lessthan ( const void *  first,
const void *  second 
)

Definition at line 384 of file polyblk.cpp.

384  {
385  ICOORDELT *p1 = (*(ICOORDELT **) first);
386  ICOORDELT *p2 = (*(ICOORDELT **) second);
387 
388  if (p1->x () < p2->x ())
389  return (-1);
390  else if (p1->x () > p2->x ())
391  return (1);
392  else
393  return (0);
394 }
inT16 x() const
access function
Definition: points.h:52