Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bcm2385-codec not reporting about encoder dropping frame #6680

Open
lmkq222 opened this issue Feb 21, 2025 · 1 comment
Open

bcm2385-codec not reporting about encoder dropping frame #6680

lmkq222 opened this issue Feb 21, 2025 · 1 comment
Assignees

Comments

@lmkq222
Copy link

lmkq222 commented Feb 21, 2025

Describe the bug

While implementing v4l2 h264 encoding I have stumbled upon an issue of H264 encoder dropping frames when bitrate overshots intended values. According to Stateful-M2M-Encoder docs I expected to receive CAPTURE buffer with V4L2_BUF_FLAG_ERROR set, but looking at the bcm2385-codec it seems like it silently returns a buffer to the VPU without notifying user space.

Steps to reproduce the behaviour

  1. Open V4L2 /dev/video11 encoder
  2. Setup H264 encoding 720x576p, 25fps, bitrate 10MBit/s, constrained baseline profile, repeate sequence header
  3. Open /dev/urandom and feed random data to the encoder
  4. Observe encoder dropping frames and not notifying the user space

Device (s)

Raspberry Pi Zero 2 W

System

  • Raspberry Pi reference 2025-02-05 Generated using pi-gen, https://github.com/RPi-Distro/pi-gen, 9a4a00f082b23c94caa210e7441fdf5d6a341056, stage2
  • Nov 26 2024 12:54:19
    Copyright (c) 2012 Broadcom
    version 2ae30f53898ae2f1ba77ff570a92991bedfb0398 (clean) (release) (start)
  • Linux raspberrypi 6.6.74+rpt-rpi-v8 1 SMP PREEMPT Debian 1:6.6.74-1+rpt1 (2025-01-27) aarch64 GNU/Linux

Logs

No response

Additional context

No response

@6by9
Copy link
Contributor

6by9 commented Feb 21, 2025

Forum thread (such as it was) https://forums.raspberrypi.com/viewtopic.php?t=384108

@6by9 6by9 self-assigned this Feb 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants