Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
sellmair committed Mar 18, 2019
1 parent 4c2b2b0 commit e67f0d2
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,18 @@ val mat = image.rgb()
Simply use the static function ```Yuv.toMat```

```java
Mat mat = Yuv.toMat(image)
Mat mat = Yuv.rgb(image)
```

### Clipping the image
This library supports efficient clipping of the image before converting.
Just pass a clip to the function:

```kotlin
val mat = image.mat(Clip(left=20, top=20, right=40, bottom=40))
val yuv = YuvImage(image).clip(left=20, top=20, right=40, bottom=40)
val yuv = YuvImage(image).with(YuvImage.Clip(left=20, top=20, right=40, bottom=40))
val yuv = YuvImage(image) with YuvImage.Clip(left=20, top=20, right=40, bottom=40)
val rgb: Mat = yuv.rgb()
```

## Get the the dependency
Expand All @@ -31,7 +34,7 @@ val mat = image.mat(Clip(left=20, top=20, right=40, bottom=40))
```
dependencies {
...
implementation "com.quickbirdstudios:yuvtomat:0.1.0"
implementation "com.quickbirdstudios:yuvtomat:1.1.0"
}
```

Expand Down

0 comments on commit e67f0d2

Please sign in to comment.