rename and add more video descriptors

use struct to define uvc descriptor for video_capture since uvc is
rather too complicated to use macro templates
This commit is contained in:
hathach
2024-01-26 22:55:55 +07:00
parent bd3c4fbe1e
commit b5cd673330
5 changed files with 392 additions and 98 deletions

View File

@@ -50,17 +50,17 @@
typedef struct {
tusb_desc_interface_t std;
tusb_desc_cs_video_ctl_itf_hdr_t ctl;
tusb_desc_video_control_header_t ctl;
} tusb_desc_vc_itf_t;
typedef struct {
tusb_desc_interface_t std;
tusb_desc_cs_video_stm_itf_hdr_t stm;
tusb_desc_video_streaming_inout_header_t stm;
} tusb_desc_vs_itf_t;
typedef union {
tusb_desc_cs_video_ctl_itf_hdr_t ctl;
tusb_desc_cs_video_stm_itf_hdr_t stm;
tusb_desc_video_control_header_t ctl;
tusb_desc_video_streaming_inout_header_t stm;
} tusb_desc_video_itf_hdr_t;
typedef struct TU_ATTR_PACKED {
@@ -78,9 +78,9 @@ typedef union {
uint8_t bFormatIndex;
uint8_t bNumFrameDescriptors;
};
tusb_desc_cs_video_fmt_uncompressed_t uncompressed;
tusb_desc_cs_video_fmt_mjpeg_t mjpeg;
tusb_desc_cs_video_fmt_frame_based_t frame_based;
tusb_desc_video_format_uncompressed_t uncompressed;
tusb_desc_video_format_mjpeg_t mjpeg;
tusb_desc_video_format_framebased_t frame_based;
} tusb_desc_cs_video_fmt_t;
typedef union {
@@ -93,9 +93,9 @@ typedef union {
uint16_t wWidth;
uint16_t wHeight;
};
tusb_desc_cs_video_frm_uncompressed_t uncompressed;
tusb_desc_cs_video_frm_mjpeg_t mjpeg;
tusb_desc_cs_video_frm_frame_based_t frame_based;
tusb_desc_video_frame_uncompressed_t uncompressed;
tusb_desc_video_frame_mjpeg_t mjpeg;
tusb_desc_video_frame_framebased_t frame_based;
} tusb_desc_cs_video_frm_t;
/* video streaming interface */