<div dir="ltr">I'm finally getting around to getting this working. It looks like my patience (slothfulness) has paid off because there is the external (black box) tuner option now. I've gone through the mythhdrecorder code and I think I understand most of what needs to happen. I do have a few questions though.<div><br></div><div>From what the Wiki says, MythTV is expecting a MPTS as output from the external program on STDOUT. This USB device only has YUYV output, so do I need to pass it through ffmpeg or the h.264 library before sending it to MythTV? I think that I'll leave the channel changing with IR blaster to a separate script so that it doesn't have to support all kinds of blasters. Basically, this should be pretty simple:</div><div><ol><li>Send commands to the UVC device to set resolution, framerate, (picture quality in the future).</li><li>Read from /dev/video0</li><li>Run the stream through ffmpeg/h264 library</li><li>Send output to STDOUT</li></ol><div>Am I on the right track here? Anything I'm missing (I understand that I have to read STDIN and send command results on STDERR)?</div><div><br></div><div>Thanks.</div><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">----------------<br>Robert LeBlanc<br>PGP Fingerprint 79A2 9CA4 6CC4 45DD A904  C70E E654 3BB2 FA62 B9F1</div></div><br></div></div><br><div class="gmail_quote"><div dir="ltr">On Tue, Aug 15, 2017 at 8:44 AM Devin Heitmueller <<a href="mailto:dheitmueller@kernellabs.com">dheitmueller@kernellabs.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">> I believe the device can output in a few different formats, I'm going to<br>
> mess with that a bit today. For the analog capture devices, I can't set the<br>
> recording profile to 1080p, only like 700x580 or something so the device is<br>
> downscaling. I'll see if I can use v4l2-cfg to set the frame rate. When I do<br>
> a non-raw capture, it understands that the frame rate is 30 or 60 (depending<br>
> on what I set in steamer) and VLC reports that and plays it back properly.<br>
><br>
> I can also try twiddling with the code to see if I can get some additional<br>
> parameters passed to the device, do you know where this code would be?<br>
<br>
It tends to be heavily dependent on the device.  Most webcams let you<br>
adjust the frame rate and resolution because the net effect is how it<br>
configures the onboard image sensor.  However with a device that<br>
consumes digital video from an HDMI source, there are more limitations<br>
on how much control the receiver can exercise in terms of resolutions<br>
and framerates.  If the device supports frame decimation and/or<br>
scaling then it can be pretty flexible.  However if it's more of a<br>
"dumb" device, then it just takes whatever comes back from the HDMI<br>
receiver chip and pushes it over the USB bus.<br>
<br>
You might want to load the device up under Windows and see what<br>
options are offered to you, as that might provide some guidance as to<br>
what the hardware is actually capable of.<br>
<br>
Regarding 1080p vs 700x580, my guess is MythTV has some hard-coded<br>
resolutions (based on typical NTSC/PAL use cases) and the actual<br>
commands to set the resolution in the hardware are completely ignored.<br>
You would probably have to save a few frames of actual video from the<br>
driver and see what their effective resolution is, as opposed what<br>
MythTV is supposedly telling the device to operate at.<br>
<br>
Devin<br>
<br>
-- <br>
Devin J. Heitmueller - Kernel Labs<br>
<a href="http://www.kernellabs.com" rel="noreferrer" target="_blank">http://www.kernellabs.com</a><br>
_______________________________________________<br>
mythtv-users mailing list<br>
<a href="mailto:mythtv-users@mythtv.org" target="_blank">mythtv-users@mythtv.org</a><br>
<a href="http://lists.mythtv.org/mailman/listinfo/mythtv-users" rel="noreferrer" target="_blank">http://lists.mythtv.org/mailman/listinfo/mythtv-users</a><br>
<a href="http://wiki.mythtv.org/Mailing_List_etiquette" rel="noreferrer" target="_blank">http://wiki.mythtv.org/Mailing_List_etiquette</a><br>
MythTV Forums: <a href="https://forum.mythtv.org" rel="noreferrer" target="_blank">https://forum.mythtv.org</a><br>
</blockquote></div>