mirror of
https://github.com/78/xiaozhi-esp32.git
synced 2026-02-18 09:58:09 +00:00
* Fix: uart-uhci compiling errors * Enhance Esp32Camera functionality by adding optional byte swapping for RGB565 format. Introduce SetSwapBytes method to enable/disable byte order swapping, and update Capture method to utilize an encode buffer for improved memory management and performance during image processing.
17 lines
466 B
C++
17 lines
466 B
C++
#ifndef CAMERA_H
|
|
#define CAMERA_H
|
|
|
|
#include <string>
|
|
|
|
class Camera {
|
|
public:
|
|
virtual void SetExplainUrl(const std::string& url, const std::string& token) = 0;
|
|
virtual bool Capture() = 0;
|
|
virtual bool SetHMirror(bool enabled) = 0;
|
|
virtual bool SetVFlip(bool enabled) = 0;
|
|
virtual bool SetSwapBytes(bool enabled) { return false; } // Optional, default no-op
|
|
virtual std::string Explain(const std::string& question) = 0;
|
|
};
|
|
|
|
#endif // CAMERA_H
|