Tesseract  3.02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
plotedges.cpp File Reference
#include "plotedges.h"
#include "render.h"
#include "split.h"

Go to the source code of this file.

Functions

void display_edgepts (LIST outlines)
void draw_blob_edges (TBLOB *blob)
void mark_outline (EDGEPT *edgept)
void mark_split (SPLIT *split)

Variables

ScrollViewedge_window = NULL

Function Documentation

void display_edgepts ( LIST  outlines)

Definition at line 53 of file plotedges.cpp.

{
void *window;
/* Set up window */
if (edge_window == NULL) {
edge_window = c_create_window ("Edges", 750, 150,
400, 128, -400.0, 400.0, 0.0, 256.0);
}
else {
}
/* Render the outlines */
window = edge_window;
/* Reclaim old memory */
iterate(outlines) {
render_edgepts (window, (EDGEPT *) first_node (outlines), White);
}
}
void draw_blob_edges ( TBLOB blob)

Definition at line 77 of file plotedges.cpp.

{
TESSLINE *ol;
LIST edge_list = NIL_LIST;
for (ol = blob->outlines; ol != NULL; ol = ol->next)
push_on (edge_list, ol->loop);
display_edgepts(edge_list);
destroy(edge_list);
}
}
void mark_outline ( EDGEPT edgept)

Definition at line 95 of file plotedges.cpp.

{ /* Start of point list */
void *window = edge_window;
float x = edgept->pos.x;
float y = edgept->pos.y;
c_move(window, x, y);
x -= 4;
y -= 12;
c_draw(window, x, y);
x -= 2;
y += 4;
c_draw(window, x, y);
x -= 4;
y += 2;
c_draw(window, x, y);
x += 10;
y += 6;
c_draw(window, x, y);
c_make_current(window);
}
void mark_split ( SPLIT split)

Definition at line 130 of file plotedges.cpp.

{
void *window = edge_window;
c_move (window, (float) split->point1->pos.x, (float) split->point1->pos.y);
c_draw (window, (float) split->point2->pos.x, (float) split->point2->pos.y);
c_make_current(window);
}

Variable Documentation

ScrollView* edge_window = NULL

Definition at line 43 of file plotedges.cpp.