libcamera: geometry: Give constructors to Rectangle
Rectangle, unlike Size, has no constructor, requiring the users to explicitly initialize the instances. This is error-prone, add constructors. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
This commit is contained in:
@@ -487,7 +487,7 @@ int CameraSensor::sensorInfo(CameraSensorInfo *info) const
|
||||
info->model = model();
|
||||
|
||||
/* Get the active area size. */
|
||||
Rectangle rect = {};
|
||||
Rectangle rect;
|
||||
int ret = subdev_->getSelection(pad_, V4L2_SEL_TGT_CROP_DEFAULT, &rect);
|
||||
if (ret) {
|
||||
LOG(CameraSensor, Error)
|
||||
|
||||
Reference in New Issue
Block a user