From d701c15b4ef122341d27a4bdffc6aedb5d28bc78 Mon Sep 17 00:00:00 2001 From: Stefan Weil Date: Mon, 21 Dec 2015 10:01:47 +0100 Subject: [PATCH] Fix compiler warnings (remove unused constants) Signed-off-by: Stefan Weil --- textord/colpartition.cpp | 5 ----- textord/colpartitiongrid.cpp | 8 -------- viewer/svutil.cpp | 1 - 3 files changed, 14 deletions(-) diff --git a/textord/colpartition.cpp b/textord/colpartition.cpp index cef329f202..990fba1149 100644 --- a/textord/colpartition.cpp +++ b/textord/colpartition.cpp @@ -41,9 +41,6 @@ CLISTIZE(ColPartition) //////////////// ColPartition Implementation //////////////// -// If multiple partners survive the partner depth test beyond this level, -// then arbitrarily pick one. -const int kMaxPartnerDepth = 4; // Maximum change in spacing (in inches) to ignore. const double kMaxSpacingDrift = 1.0 / 72; // 1/72 is one point. // Maximum fraction of line height used as an additional allowance @@ -60,8 +57,6 @@ const double kMaxLeaderGapFractionOfMax = 0.25; const double kMaxLeaderGapFractionOfMin = 0.5; // Minimum number of blobs to be considered a leader. const int kMinLeaderCount = 5; -// Cost of a cut through a leader. -const int kLeaderCutCost = 8; // Minimum score for a STRONG_CHAIN textline. const int kMinStrongTextValue = 6; // Minimum score for a CHAIN textline. diff --git a/textord/colpartitiongrid.cpp b/textord/colpartitiongrid.cpp index 9ca5fd4d9c..4d703fbe7d 100644 --- a/textord/colpartitiongrid.cpp +++ b/textord/colpartitiongrid.cpp @@ -35,10 +35,6 @@ const int kMaxPadFactor = 6; // Max multiple of size (min(height, width)) for the distance of the nearest // neighbour for the change of type to be used. const int kMaxNeighbourDistFactor = 4; -// Max RMS color noise to compare colors. -const int kMaxRMSColorNoise = 128; -// Minimum number of blobs in text to make a strong text partition. -const int kHorzStrongTextlineCount = 10; // Maximum number of lines in a credible figure caption. const int kMaxCaptionLines = 7; // Min ratio between biggest and smallest gap to bound a caption. @@ -49,10 +45,6 @@ const double kMinCaptionGapHeightRatio = 0.5; const double kMarginOverlapFraction = 0.25; // Size ratio required to consider an unmerged overlapping partition to be big. const double kBigPartSizeRatio = 1.75; -// Allowed proportional change in stroke width to match for smoothing. -const double kStrokeWidthFractionTolerance = 0.25; -// Allowed constant change in stroke width to match for smoothing. -const double kStrokeWidthConstantTolerance = 2.0; // Fraction of gridsize to allow arbitrary overlap between partitions. const double kTinyEnoughTextlineOverlapFraction = 0.25; // Max vertical distance of neighbouring ColPartition as a multiple of diff --git a/viewer/svutil.cpp b/viewer/svutil.cpp index 2ac94ee80f..ae47e21bda 100644 --- a/viewer/svutil.cpp +++ b/viewer/svutil.cpp @@ -60,7 +60,6 @@ struct addrinfo { #include "svutil.h" -const int kBufferSize = 65536; const int kMaxMsgSize = 4096; // Signals a thread to exit.