@@ -275,9 +275,9 @@ bool V4L2Grabber::init()
275
275
try
276
276
{
277
277
Info (_log, " *************************************************************************************************" );
278
- Info (_log, " Starting V4L2 grabber. Selected: %s [%s] %d x %d @ %d fps %s" , QSTRING_CSTR (foundDevice), QSTRING_CSTR (dev.name ),
278
+ Info (_log, " Starting V4L2 grabber. Selected: %s [%s] %d x %d @ %d fps %s input %d " , QSTRING_CSTR (foundDevice), QSTRING_CSTR (dev.name ),
279
279
dev.valid [foundIndex].x , dev.valid [foundIndex].y , dev.valid [foundIndex].fps ,
280
- QSTRING_CSTR (pixelFormatToString (dev.valid [foundIndex].pf )));
280
+ QSTRING_CSTR (pixelFormatToString (dev.valid [foundIndex].pf )), _input );
281
281
Info (_log, " *************************************************************************************************" );
282
282
283
283
if (init_device (foundDevice, dev.valid [foundIndex]))
@@ -548,11 +548,14 @@ void V4L2Grabber::enumerateV4L2devices(bool silent)
548
548
if (properties.valid .size () == 0 && realName.indexOf (" usbtv " , 0 , Qt::CaseInsensitive) == 0 )
549
549
{
550
550
Warning (_log, " To have proper colors when using UTV007 grabber, you may need to add 'sudo systemctl stop hyperhdr@pi && v4l2-ctl -s pal-B && sudo systemctl start hyperhdr@pi' to /etc/rc.local or run it manually to set the PAL standard" );
551
- { DevicePropertiesItem diL; diL.x = 320 ; diL.y = 240 ; diL.fps = 30 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = 0 ; properties.valid .append (diL); }
552
- { DevicePropertiesItem diL; diL.x = 320 ; diL.y = 288 ; diL.fps = 25 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = 0 ; properties.valid .append (diL); }
553
- { DevicePropertiesItem diL; diL.x = 360 ; diL.y = 240 ; diL.fps = 30 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = 0 ; properties.valid .append (diL); }
554
- { DevicePropertiesItem diL; diL.x = 720 ; diL.y = 480 ; diL.fps = 30 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = 0 ; properties.valid .append (diL); }
555
- { DevicePropertiesItem diL; diL.x = 720 ; diL.y = 576 ; diL.fps = 25 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = 0 ; properties.valid .append (diL); }
551
+ for (int input = 0 ; input < properties.inputs .size (); input++)
552
+ {
553
+ { DevicePropertiesItem diL; diL.x = 320 ; diL.y = 240 ; diL.fps = 30 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = input; properties.valid .append (diL); }
554
+ { DevicePropertiesItem diL; diL.x = 320 ; diL.y = 288 ; diL.fps = 25 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = input; properties.valid .append (diL); }
555
+ { DevicePropertiesItem diL; diL.x = 360 ; diL.y = 240 ; diL.fps = 30 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = input; properties.valid .append (diL); }
556
+ { DevicePropertiesItem diL; diL.x = 720 ; diL.y = 480 ; diL.fps = 30 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = input; properties.valid .append (diL); }
557
+ { DevicePropertiesItem diL; diL.x = 720 ; diL.y = 576 ; diL.fps = 25 ; diL.pf = identifyFormat (V4L2_PIX_FMT_YUYV); diL.v4l2PixelFormat = V4L2_PIX_FMT_YUYV; diL.input = input; properties.valid .append (diL); }
558
+ }
556
559
}
557
560
558
561
_deviceProperties.insert (realName, properties);
@@ -562,7 +565,7 @@ void V4L2Grabber::enumerateV4L2devices(bool silent)
562
565
for (int i = 0 ; i < properties.valid .count (); i++)
563
566
{
564
567
const auto & di = properties.valid [i];
565
- Info (_log, " %s [%s] %d x %d @ %d fps %s" , QSTRING_CSTR (realName), QSTRING_CSTR (properties.name ), di.x , di.y , di.fps , QSTRING_CSTR (pixelFormatToString (di.pf )));
568
+ Info (_log, " %s [%s] %d x %d @ %d fps %s input %d " , QSTRING_CSTR (realName), QSTRING_CSTR (properties.name ), di.x , di.y , di.fps , QSTRING_CSTR (pixelFormatToString (di.pf )), di. input );
566
569
}
567
570
}
568
571
}
0 commit comments