[v4,0/4] Clarify rectangle behavior
mbox series

Message ID 20260918091835.2332386-1-stefan.klug@ideasonboard.com
Headers show
Series
  • Clarify rectangle behavior
Related show

Message

Stefan Klug Sept. 18, 2026, 9:10 a.m. UTC
Hi all,

This series changes the behavior of PixelArraySize to represent the
physical sensor area instead of the readable pixel area. The reasoning
is explained in a bit more detail in patch 2. Patch 3 applies that idea
to the IPA interface. Patch 4 adds an additional property for
completeness sake which we could drop.

With these patches applied I am able to draw proper bounding rectangles
in camshark. An implemented is available in
https://gitlab.freedesktop.org/camera/camshark/-/tree/sklug/next?ref_type=heads

Version 4 renames PixelArraySize to PixelArrayArea for various reasons
explained in patch 2. In addition patch 1 was added that drops the
PixelArrayOpticalBlackRectangles property as it turned out to be
completely unused.

Version 3 prevents negative crop rectangles in the rpi ipa and issues a
warning in that case. Aside from that a few minor stylistic fixes from
the review were applied.

Best regards,
Stefan

Stefan Klug (4):
  libcamera: property_ids_core: Drop PixelArrayOpticalBlackRectangles
  libcamera: Clarify meaning of PixelArraySize and other rectangles
  libcamera: ipa: core: Use native coordinates for
    IPACameraSensorInfo::analogCrop
  libcamera: ipa: core: Add IPACameraSensorInfo::pixelArrayArea property

 include/libcamera/ipa/core.mojom              |  37 +++-
 src/android/camera_capabilities.cpp           |   6 +-
 src/ipa/mali-c55/algorithms/lsc.cpp           |  11 +-
 src/ipa/rkisp1/algorithms/lsc.cpp             |  11 +-
 src/ipa/rpi/common/ipa_base.cpp               |  20 +-
 src/libcamera/pipeline/uvcvideo/uvcvideo.cpp  |   2 +-
 src/libcamera/property_ids_core.yaml          | 204 ++++++------------
 src/libcamera/sensor/camera_sensor_legacy.cpp |  54 ++---
 src/libcamera/sensor/camera_sensor_raw.cpp    |  36 ++--
 9 files changed, 163 insertions(+), 218 deletions(-)