Пример #1
0
        public Coordinate Execute(TOcrResultStructures.TOcrResultsItem start, TOcrResultStructures.TOcrResultsItem end, int imgWidth, int imgHeight)
        {
            double x      = start.XPos;
            double y      = start.YPos;
            double height = Math.Max(start.YDim, end.XDim);
            double width  = end.XPos + end.XDim - start.XPos;

            return(_createRelativeCoordinate.Execute(x, y, height, width, imgHeight, imgWidth));
        }
Пример #2
0
 private static bool IsNewSentence(TOcrResultStructures.TOcrResultsItem last, TOcrResultStructures.TOcrResultsItem item)
 {
     return((last.XPos + last.XDim + (Math.Max(item.YDim, last.YDim) * 2)) < item.XPos);
 }
Пример #3
0
 private Coordinate CreateCoordinate(TOcrResultStructures.TOcrResultsItem start, TOcrResultStructures.TOcrResultsItem end, int width, int heigt)
 {
     return(_transymCreateRelativeCoordinate.Execute(start, end, width, heigt));
 }