tesseract  4.00.00dev
polyblk.cpp File Reference
#include <ctype.h>
#include <math.h>
#include <stdio.h>
#include <memory>
#include "elst.h"
#include "polyblk.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 383 of file polyblk.cpp.

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