libcamera: Remove transform from V4L2SubdeviceFormat
Commit6f6e1bf704
("libcamera: camera_sensor: Apply flips at setFormat()") extended the CameraSensor::setFormat() function to apply vertical/horizontal flips on the sensor based on the supplied Transform. To pass the Transform to the function the V4L2SubdeviceFormat structure has been augmented with a Transform member. However as the newly added Transform is not used at all in the V4L2Subdevice class, it should not be part of V4L2SubdeviceFormat. Fix that by removing the transform field from V4L2SubdeviceFormat and pass it as an explicit parameter to CameraSensor::setFormat(). Fixes:6f6e1bf704
("libcamera: camera_sensor: Apply flips at setFormat()) Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
parent
3aa42f36c0
commit
85befa816e
7 changed files with 19 additions and 28 deletions
|
@ -17,6 +17,7 @@
|
|||
#include <libcamera/control_ids.h>
|
||||
#include <libcamera/controls.h>
|
||||
#include <libcamera/geometry.h>
|
||||
#include <libcamera/transform.h>
|
||||
|
||||
#include <libcamera/ipa/core_ipa_interface.h>
|
||||
|
||||
|
@ -29,8 +30,6 @@ class BayerFormat;
|
|||
class CameraLens;
|
||||
class MediaEntity;
|
||||
|
||||
enum class Transform;
|
||||
|
||||
struct CameraSensorProperties;
|
||||
|
||||
class CameraSensor : protected Loggable
|
||||
|
@ -55,7 +54,8 @@ public:
|
|||
|
||||
V4L2SubdeviceFormat getFormat(const std::vector<unsigned int> &mbusCodes,
|
||||
const Size &size) const;
|
||||
int setFormat(V4L2SubdeviceFormat *format);
|
||||
int setFormat(V4L2SubdeviceFormat *format,
|
||||
Transform transform = Transform::Identity);
|
||||
|
||||
const ControlInfoMap &controls() const;
|
||||
ControlList getControls(const std::vector<uint32_t> &ids);
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
|
||||
#include <libcamera/color_space.h>
|
||||
#include <libcamera/geometry.h>
|
||||
#include <libcamera/transform.h>
|
||||
|
||||
#include "libcamera/internal/formats.h"
|
||||
#include "libcamera/internal/media_object.h"
|
||||
|
@ -45,7 +44,6 @@ struct V4L2SubdeviceFormat {
|
|||
uint32_t mbus_code;
|
||||
Size size;
|
||||
std::optional<ColorSpace> colorSpace;
|
||||
Transform transform = Transform::Identity;
|
||||
|
||||
const std::string toString() const;
|
||||
uint8_t bitsPerPixel() const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue