Enroll Face from JPEG File instead of from camera

fratajcz
Posts: 1
Joined: Thu Jan 14, 2021 4:51 pm

Enroll Face from JPEG File instead of from camera

Postby fratajcz » Fri Jan 15, 2021 11:50 am

Hi!

I am new here and I have just started out with the esp32. I have studied the CameraWebServer example and also looked at the fr_flash.h for ways to persist the enrolled faces in flash.

However, I want to enroll a face from jpg images that are stored either on a SD card or are uploaded as a hex file alongside the sketch.

I have a jpeg encoded integer array that i read from the hex file, I have the width, height and length of the image that is stored in the array, but i just cant piece that together in a way that would be accepted during enrolling.

I see that in the examples, it always works wit a framebuffer struct (camera_fb_t). Can someone explain how i can piece the above mentioned values together so that instead of

Code: Select all

fb = esp_camera_fb_get()
i can just use

Code: Select all

fb = get_fb_from_jpeg()
? Explicitely, get_fb_from_jpeg() is the function i am looking for.

I hope my question makes sense and someone can help me out. I am new to cpp and c, maybe what I am asking for is a no-brainer for some, but it stretches my mind quite a bit.

Cheers and Thanks!

Who is online

Users browsing this forum: No registered users and 22 guests