https://github.com/bookzhan/bzyuvlib
Support YUV conversion to RGBA / BGRA, also adapted to YUV conversion of Camera1 and Camera2
https://github.com/bookzhan/bzyuvlib
android camera1 camera2 libyuv yuv-conversion yuv2rgb
Last synced: about 1 month ago
JSON representation
Support YUV conversion to RGBA / BGRA, also adapted to YUV conversion of Camera1 and Camera2
- Host: GitHub
- URL: https://github.com/bookzhan/bzyuvlib
- Owner: bookzhan
- Created: 2020-05-15T09:56:56.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2025-11-11T12:44:40.000Z (4 months ago)
- Last Synced: 2025-11-11T14:26:49.858Z (4 months ago)
- Topics: android, camera1, camera2, libyuv, yuv-conversion, yuv2rgb
- Language: C++
- Size: 9.3 MB
- Stars: 55
- Watchers: 2
- Forks: 12
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
I previously wrote a YUV to RGBA project based on RenderScript, address: https://blog.raoyunsoft.com/post/yuv-conversion-renderscript-nv21-yv12-yuv420 If you like it, you can go here to find it, than Android native ScriptIntrinsicYuvToRGB is much more powerful, but recently found that RenderScript is much slower than Google ’s libyuv, so I wrote a YUV conversion project based on libyuv, and also supported the YUV conversion of Camera1 and Camera2 output, and the YUV mirror , Rotation, supported functions are as follows:
1. yuv420pToRGBA/yuv420pToBGRA
2. preHandleYUV
3. yv12ToRGBA/yv12ToBGRA
4. nv21ToRGBA/nv21ToBGRA
5. cropNV21/cropYUV420
6. zoomYUV420
7. bitmapToYUV420
8. yuvToGrey
9. greyToRGBA
10. translationSingleChannel
11. Support RGBA rotation and mirroring
12. yuvI420ToNV21
13. yuvI420ToNV12
#### How to use:
##### 1.First add mavenCentral() as shown below
```
allprojects {
repositories {
maven { url "https://nexus.raoyunsoft.com/repository/maven-releases/" }
}
}
```
##### 2. implementation 'com.guaishou.bzlib:bzyuv:1.1.22@aar'
If it helps you, please give me a start
[中文文档(Chinese DOC)](https://github.com/bookzhan/bzyuvlib/blob/master/README_cn.md)