Skip to content

Commit

Permalink
no message
Browse files Browse the repository at this point in the history
  • Loading branch information
solbisio committed Aug 26, 2016
1 parent d4038a7 commit 233a456
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/GoogleCloudVision.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,13 @@ public function setImage($input, $type = "FILE")
return $this->setRequestBody();
}

public function setImageContents($content)
{
$this->image['content'] = $content;

return $this->setRequestBody();
}

public function convertImgtoBased64($path)
{
$data = file_get_contents($path);
Expand Down

1 comment on commit 233a456

@samwilson
Copy link

Choose a reason for hiding this comment

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

This doesn't base64_encode the content; is that an issue?

What's the use case here? Because it seems that the same result could be achieved with GoogleCloudVision::setImage($content, 'RAW').

(I'm just investigating what people consider the flaws in this library.)

Please sign in to comment.