Skip to content

Commit

Permalink
Google Vision Text Annotation response added(#26)
Browse files Browse the repository at this point in the history
  • Loading branch information
brunsgaard authored Mar 17, 2019
1 parent 99ed30e commit 0fda7ed
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 48 deletions.
73 changes: 39 additions & 34 deletions gen/go/ssn/ocrservice/v1/ocrservice.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions gen/go/ssn/ocrservice/v1/ocrservice.pb.validate.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 9 additions & 9 deletions gen/python/ssn/ocrservice/v1/ocrservice_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 8 additions & 3 deletions proto/ssn/ocrservice/v1/ocrservice.proto
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ package ssn.ocrservice.v1;

option go_package = "ocrservice";

import "google/cloud/vision/v1/image_annotator.proto";
import "google/cloud/vision/v1/text_annotation.proto";

// Interface exported by the server.
service OcrService {
Expand All @@ -17,6 +17,11 @@ message OcrScanImageRequest {

message OcrScanImageResponse {
string tess_hocr = 1;
float scale_factor = 2;
google.cloud.vision.v1.AnnotateImageResponse annotate_image_response = 3;
// Aspect ratio is kept, but image might have been resized before
// text annotation was done, boundary polygons should be multiplied
// with the scale factor to get the position of the polygon on the
// original image
double scale_factor = 2;
// TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol
google.cloud.vision.v1.TextAnnotation text_annotation = 3;
}

0 comments on commit 0fda7ed

Please sign in to comment.