Performance Issue: FPS does not increase despite lowering/compressing video resolution on Raspberry Pi 5 + IMX296

未关闭
#367 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
42/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
活跃
技术栈
cpp, raspberry-pi

调研方向

Start by reading the IMX296 sensor driver and its supported sensor modes, then trace how rpicam-vid requests frame rate and image dimensions. Check whether the driver supports cropped sensor readout at the requested 1024×128 size and 240 FPS. Done means identifying whether the requested rate is supported and documenting the relevant configuration or limitation; the issue names no source files or tests.

由索引模型根据 Issue 内容生成。

描述

Description

I am currently building a high-speed camera project using a Raspberry Pi 5 and the Raspberry Pi Global Shutter Camera (IMX296).

My goal is to achieve a higher frame rate (FPS). However, even though I have tried to lower and compress the video resolution using rpicam-vid, the actual FPS remains stagnant and does not increase as expected.

Environment

Hardware: Raspberry Pi 5, Raspberry Pi Global Shutter Camera (IMX296)
OS / Kernel: Raspberry Pi OS (Bookworm)
Software / Tool: rpicam-vid

What I've Tried

I attempted to lower the resolution using the --width and --height arguments in rpicam-vid (for example, dropping it down from the native 1456x1088).
While the output video file size decreases and the resolution changes, the running FPS does not go up. It seems to be capped at the default sensor frame rate.

Question
  1. Does the IMX296 sensor support windowing/cropping (ROI) or specific sensor modes to achieve higher FPS at lower resolutions on the Raspberry Pi 5?
  2. Are there specific rpicam-vid arguments (such as --viewfinder-width/--viewfinder-height or explicit --framerate / --level settings) required to properly unlock higher frame rates?

Any guidance or suggestions from the community or the developers would be greatly appreciated!

盧謙毓, 週二 下午5:19

Description

I am currently building a high-speed camera project using a Raspberry Pi 5 and the Raspberry Pi Global Shutter Camera (IMX296).

My goal is to achieve a higher frame rate (FPS). However, even though I have tried to lower and compress the video resolution using rpicam-vid, the actual FPS remains stagnant and does not increase as expected.

Environment

Hardware: Raspberry Pi 5, Raspberry Pi Global Shutter Camera (IMX296)
OS / Kernel: Raspberry Pi OS (Bookworm)
Software / Tool: rpicam-vid

What I've Tried

I attempted to run the following command to record uncompressed high-speed video directly into a ramdisk:
bash
rpicam-vid --frames 480 --framerate 240 --width 1024 --height 128 --codec yuv420 --denoise cdn_off -n -o /mnt/ramdisk/test.yuv
Observed Behavior:
Although the output resolution successfully changes to 1024x128 and the yuv420 file is saved to /mnt/ramdisk/, the actual frame rate does not reach the requested 240 FPS. It seems to be capped at the sensor's standard hardware/driver limit.

Question
  1. Does the IMX296 sensor driver support a high-speed mode or sensor crop/windowing (ROI) that can unlock higher FPS (like 240 FPS) at lower heights (e.g., 128px) on the Raspberry Pi 5?
  2. Are there any specific configurations needed in /boot/firmware/config.txt or additional rpicam-vid switches required to achieve this?

Any guidance or suggestions from the community or the developers would be greatly appreciated!

主要语言
C++
星标
491
派生
199
PR 合并指标
30 天内没有已合并 PR

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

raspberrypi/libcamera 的其他 Issue

查看 raspberrypi/libcamera 的全部 Issue

相似的 Issue

更多 C++ Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。