Combine Zxing with EasyAR

0 votes
asked Jul 29, 2019 by rlmidiaalvs (2,440 points)
I need to get color32 or bytes[] to pass in the zxing decode. I get buffer from EasyAR image and use 'copy to byte Array', but the rotation is incorret. I tried readpixels from screen, but it's slow.  Any sugestion? Thanks!

1 Answer

0 votes
answered Jul 30, 2019 by zhangpengar (3,060 points)
selected Aug 1, 2019 by rlmidiaalvs
 
Best answer
The rotation of the image is normal, as the data is raw camera data and the camera is not aware of screen rotation. You don't need to care about the rotation if you only need to get text from zxing. QRCode is designed that rotation doesn't affect its decoding.

If you want to display the detected quadrangle, you need to first get the coordinates from zxing and then apply the rotation from inputFrame.cameraParameters().imageOrientation(screenRotation).
commented Sep 2, 2019 by permanaaditya (130 points)
i got same problem, how to get color32 or bytes[] from camera data in EasyAR 3.0.1 Unity3d?
commented Sep 2, 2019 by zhangpengar (3,060 points)
You can call OutputFrame.inputFrame().image().buffer().data to get the raw pointer. Be careful that all these objects needed to be disposed in C#.
Welcome to EasyAR SDK Q&A, where you can ask questions and receive answers from other members of the community.
...