Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.

Add the ability for ML Kit to create image from bytes#901

Closed
bparrishMines wants to merge 25 commits into
flutter-team-archive:masterfrom
bparrishMines:mlkit_android
Closed

Add the ability for ML Kit to create image from bytes#901
bparrishMines wants to merge 25 commits into
flutter-team-archive:masterfrom
bparrishMines:mlkit_android

Conversation

@bparrishMines

Copy link
Copy Markdown
Contributor

No description provided.


switch (call.method) {
case "BarcodeDetector#detectInImage":
try {

@bparrishMines bparrishMines Nov 17, 2018

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Moved this to top of onMethodCall for all detectors

@kroikie kroikie left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small adjustment to handling invalid rotation value. Otherwise LGTM.

case ImageRotation.rotation_270:
return 270;
default:
return -1;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we just return 0 in this case?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea. Done and added an assert.

@bparrishMines

Copy link
Copy Markdown
Contributor Author

Closed for improved PR #971

@bparrishMines bparrishMines deleted the mlkit_android branch January 3, 2019 20:34
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants