feat(cam): add camera buffer alloc function

This commit is contained in:
gaoxu
2025-07-04 16:58:44 +08:00
parent b9c224215e
commit ee3de247e2
13 changed files with 166 additions and 35 deletions

View File

@@ -1,5 +1,5 @@
/*
* SPDX-FileCopyrightText: 2021-2024 Espressif Systems (Shanghai) CO LTD
* SPDX-FileCopyrightText: 2021-2025 Espressif Systems (Shanghai) CO LTD
*
* SPDX-License-Identifier: Apache-2.0
*/
@@ -133,6 +133,19 @@ struct esp_cam_ctlr_t {
*/
esp_err_t (*get_buffer_len)(esp_cam_ctlr_t *, size_t *);
/**
* @brief Allocate aligned camera buffer for ESP CAM controller
*
* @param[in] esp_cam_ctlr_t * ESP CAM controller handle
* @param[in] size_t Buffer size in bytes
* @param[in] uint32_t Buffer allocation capabilities
*
* @return
* - Buffer pointer on success
* - NULL on failure
*/
void *(*alloc_buffer)(esp_cam_ctlr_t *, size_t, uint32_t);
void *user_data; ///< User data
};