Why it is not possible to use PIXFORMAT_RGB888 with higher resolutions than QVGA?

riccardo.brue
Posts: 10
Joined: Fri Jun 21, 2019 1:49 pm

Why it is not possible to use PIXFORMAT_RGB888 with higher resolutions than QVGA?

Postby riccardo.brue » Tue Oct 15, 2019 10:23 am

I need to scan some barcodes using the ZXing library (C++ porting) and I cannot capture and decode images (RGB888) with resolutions higher than 320x240 (QVGA), which causes panics and overflows on the ESP-WHO. Why there is this limitation?

I need to capture at least XGA (1024x768) images using RGB888 in order to successfully decode the barcodes, but this seems just not possible with the ESP-WHO board.

This is the C++ porting of ZXing library: https://github.com/nu-book/zxing-cpp

And this is actually the code that I am calling in order to decode the image:

Code: Select all

int w = 320; //width of the captured frame
int h = 240; //height of the captured frame
int channelsNo = 3; //R,G and B (3 channels from RGB888)
int rowBytes=w * channelsNo; //bytes per row
bool tryHarder = true; //tries to find the barcode with more than one scan
bool tryRotate = true; //tries to rotate the image

//From ZXing library, in order to decode the barcode inside the image (from fb->buf)
Result result = ReadBarcode(w, h, fb->buf, rowBytes, pixelBytes, 0, 1, 2, {}, tryRotate, tryHarder);
Where fb->buf is just the captured frame (RGB888 and 320x240 resolution), but this is not enough to decode the barcode. Any solution?

Who is online

Users browsing this forum: No registered users and 13 guests