arkhipenko / esp32-cam-mjpeg

ESP32 mjpeg streaming server
BSD 3-Clause "New" or "Revised" License
172 stars 76 forks source link

Is it possible to increase resolution #3

Closed jagjordi closed 3 years ago

jagjordi commented 3 years ago

Hello, I am using this library with an AI thinker esp32cam module. It works great and I am able to connect through Zoneminder to it (it was not possible with other libraries I tried before). However the quality is quite low. I saw in the code that there is a point where SVGA quality is selected and there are comments about the other qualities. Is it possible to use the other (higher) qualities? Or there is not enough space to fit the buffers? Thanks

arkhipenko commented 3 years ago

Yes - here is the enum: (please do consider that higher resolution means lower FPS).

typedef enum {
    FRAMESIZE_96X96,    // 96x96
    FRAMESIZE_QQVGA,    // 160x120
    FRAMESIZE_QCIF,     // 176x144
    FRAMESIZE_HQVGA,    // 240x176
    FRAMESIZE_240X240,  // 240x240
    FRAMESIZE_QVGA,     // 320x240
    FRAMESIZE_CIF,      // 400x296
    FRAMESIZE_HVGA,     // 480x320
    FRAMESIZE_VGA,      // 640x480
    FRAMESIZE_SVGA,     // 800x600
    FRAMESIZE_XGA,      // 1024x768
    FRAMESIZE_HD,       // 1280x720
    FRAMESIZE_SXGA,     // 1280x1024
    FRAMESIZE_UXGA,     // 1600x1200
    // 3MP Sensors
    FRAMESIZE_FHD,      // 1920x1080
    FRAMESIZE_P_HD,     //  720x1280
    FRAMESIZE_P_3MP,    //  864x1536
    FRAMESIZE_QXGA,     // 2048x1536
    // 5MP Sensors
    FRAMESIZE_QHD,      // 2560x1440
    FRAMESIZE_WQXGA,    // 2560x1600
    FRAMESIZE_P_FHD,    // 1080x1920
    FRAMESIZE_QSXGA,    // 2560x1920
    FRAMESIZE_INVALID
} framesize_t;