libcamera: v4l2_subdevice: Add method to retrieve the media entity
Add a method to retrieve the media entity associated with a subdevice. The entityName() and deviceNode() methods are not needed anymore as they can be accessed through the media entity, remove them. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
This commit is contained in:
parent
d97cafdf3c
commit
05b0e5ed53
5 changed files with 14 additions and 23 deletions
|
@ -52,7 +52,7 @@ int ListFormatsTest::run()
|
|||
formats = scaler_->formats(0);
|
||||
if (formats.empty()) {
|
||||
cerr << "Failed to list formats on pad 0 of subdevice "
|
||||
<< scaler_->entityName() << endl;
|
||||
<< scaler_->entity()->name() << endl;
|
||||
return TestFail;
|
||||
}
|
||||
for (auto it = formats.begin(); it != formats.end(); ++it)
|
||||
|
@ -61,7 +61,7 @@ int ListFormatsTest::run()
|
|||
formats = scaler_->formats(1);
|
||||
if (formats.empty()) {
|
||||
cerr << "Failed to list formats on pad 1 of subdevice "
|
||||
<< scaler_->entityName() << endl;
|
||||
<< scaler_->entity()->name() << endl;
|
||||
return TestFail;
|
||||
}
|
||||
for (auto it = formats.begin(); it != formats.end(); ++it)
|
||||
|
@ -71,7 +71,7 @@ int ListFormatsTest::run()
|
|||
formats = scaler_->formats(2);
|
||||
if (!formats.empty()) {
|
||||
cerr << "Listing formats on non-existing pad 2 of subdevice "
|
||||
<< scaler_->entityName()
|
||||
<< scaler_->entity()->name()
|
||||
<< " should return an empty format list" << endl;
|
||||
return TestFail;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue