{"action":"created","issue":{"url":"https://api.github.com/repos/mavlink/qgroundcontrol/issues/3982","repository_url":"https://api.github.com/repos/mavlink/qgroundcontrol","labels_url":"https://api.github.com/repos/mavlink/qgroundcontrol/issues/3982/labels{/name}","comments_url":"https://api.github.com/repos/mavlink/qgroundcontrol/issues/3982/comments","events_url":"https://api.github.com/repos/mavlink/qgroundcontrol/issues/3982/events","html_url":"https://github.com/mavlink/qgroundcontrol/issues/3982","id":173617968,"number":3982,"title":"UVC Video support","user":{"login":"cda725","id":20874683,"avatar_url":"https://avatars.githubusercontent.com/u/20874683?v=3","gravatar_id":"","url":"https://api.github.com/users/cda725","html_url":"https://github.com/cda725","followers_url":"https://api.github.com/users/cda725/followers","following_url":"https://api.github.com/users/cda725/following{/other_user}","gists_url":"https://api.github.com/users/cda725/gists{/gist_id}","starred_url":"https://api.github.com/users/cda725/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cda725/subscriptions","organizations_url":"https://api.github.com/users/cda725/orgs","repos_url":"https://api.github.com/users/cda725/repos","events_url":"https://api.github.com/users/cda725/events{/privacy}","received_events_url":"https://api.github.com/users/cda725/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":12,"created_at":"2016-08-27T22:11:40Z","updated_at":"2016-08-28T22:39:46Z","closed_at":null,"body":"In an effort to expand the capabilities of Qgroundcontrol I am attempting to add UVC video support.\r\n\r\nThe purpose for this is to use the system as  ground control station and portable ground control station supporting the myriad of wireless video transmitter/receiver systems that are ubiquitous on remote controlled vehicles today. Most are composite or HDMI on the receiver and UVC devices are available with various input options to meet the users needs.\r\n\r\nIn addition, UVC does not have the processor demand that devices such as the EZCAP and similar devices do nor does it require drivers. Regardless of OS is just \"works\" wit whatever system you plug it into.\r\n\r\nMost DIY (and many commercial) systems make use of the following components;\r\n\r\n1. A remote for direct human control\r\n2. A wireless video link (in varying frequencies) to send the video feed from a camera to a receiver\r\n3. Optionally, often  a tablet or portable PC to run software to display telemetry data such as a map overlay, GPS position, speed and so on. On most commercial systems, in addition to the map data and other telemetry information, the APP usually allows a view of the camera feed for FPV operation.\r\n\r\nDJI is a great example of a system that uses a remote in conjunction with a tablet. You can use the tablet to display your location on a map overlay, get data about the vehicle, set waypoints and such and you can view the video feed. This simplifies the overall setup and allows a lightweight portable ground control station.\r\n\r\nThe DJI system is of course proprietary but basically works the same as a DIY model in that there is a transmitter, receiver and computing device on the ground side. \r\n\r\nQgroundcontrol is a very nice system and would allow someone to easily clone the commercial systems on a budget. Adding UVC video support would allow several configurations. I will give an example of one below:\r\n\r\nAssuming a UAV ( quad drone) build for our example the following would be installed:\r\n\r\n1. Gimbal(s) \r\n2. Camera(s)\r\n3. Wireless telemetry module\r\n4. Pixhawk\r\n5. Wireless video transmitter (which are small, light, powerful and will most will run from 3S to 7S\r\n6. Remote receiver such as an X8R\r\n\r\nOn the user end the following in our example is used:\r\n\r\n1. Taranis X9D remote\r\n2. Android tablet\r\n3. USB hub\r\n4 UVC capture device for the video receiver\r\n5. USB Wireless telemetry receiver.\r\n6. Video receiver with composite or HDMI out\r\n\r\n\r\nI have tested the USB wireless telemetry modules and can fly several miles with my remote and Qgroundcontrol running from my Android and Windows tablets.  I currently have to run a separate monitor to view my cameras. If one did not need the separate monitor for this configuration they could mount the components to the back of the tablet stand that is attached to the remote and power everything from the Taranis (or whichever brand remote they choose).\r\n\r\nQGC has a nice video window feature and if it allowed a USB capture device, specifically driverless UVC capture devices (since again UVC will work in Android, Unix, Linux, OS X and various other operating system) so that a wireless receiver can be plugged in to it, this would make QGC a much more powerful and versatile package.\r\n\r\nI am not sure I understand the original intent of the video system implemented into the QGC system as it appears to require a lot of gear to get an image to QGC that could be simplified with UVC. With wireless long-range telemetry and video systems being inexpensive and readily available, in addition to weight in flying machines being a serious consideration  it appears like a logical transition for QGC and a much necessary implementation.\r\n\r\nTo be able to use QGC as an \"all-in-one\" app would exponentially expand the possibilities of QGC and its uses. the 3DR Tower app has now made this a standard feature so the industry is certainly leaning toward versatility regarding video. QGC in my opinion is a better app, has better response and the layout is much more appealing. Not to mention that Tower appears to have a latency issue with wireless telemetry devices where QGC does not.\r\n\r\nI have written a simple QT camera app that will look for a UVC device (since most tablets have built-in cameras)  in QT 5 (the same version used to create and build QGC) but the Gstreamer is so heavily nested into QGC I lack the time to reverse engineer its implementation and add the simple UVC plugin. I have also tried to modify the Gstreamer implementation to use UVC but I don't believe this is possible in a method that would be stable - perhaps I am wrong here but after a few attempts and researching the matter it looks like using the built-in QT features is a better method.\r\n\r\nI propose an implementation of USB UVC as outlined above and hope there is general interest in the QGC community to prioritize said implementation.\r\n\r\nThank you to the QGC community and my fellow developers and enthusiasts for reading this issue and considering the proposed implementation.\r\n"},"comment":{"url":"https://api.github.com/repos/mavlink/qgroundcontrol/issues/comments/243004022","html_url":"https://github.com/mavlink/qgroundcontrol/issues/3982#issuecomment-243004022","issue_url":"https://api.github.com/repos/mavlink/qgroundcontrol/issues/3982","id":243004022,"user":{"login":"cda725","id":20874683,"avatar_url":"https://avatars.githubusercontent.com/u/20874683?v=3","gravatar_id":"","url":"https://api.github.com/users/cda725","html_url":"https://github.com/cda725","followers_url":"https://api.github.com/users/cda725/followers","following_url":"https://api.github.com/users/cda725/following{/other_user}","gists_url":"https://api.github.com/users/cda725/gists{/gist_id}","starred_url":"https://api.github.com/users/cda725/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cda725/subscriptions","organizations_url":"https://api.github.com/users/cda725/orgs","repos_url":"https://api.github.com/users/cda725/repos","events_url":"https://api.github.com/users/cda725/events{/privacy}","received_events_url":"https://api.github.com/users/cda725/received_events","type":"User","site_admin":false},"created_at":"2016-08-28T22:39:46Z","updated_at":"2016-08-28T22:39:46Z","body":"@dogmaphobic \r\n\r\nAwesome work!!! We are close. \r\n\r\nRegarding the Android,  I have some code that will look for UVC as a camera that is working in a self contained app. With your mods  I can see the front and rear camera and a USB web camera but UVC devices are not showing up. I believe I can fix this by adding my code to yours in the way it is detecting \"cameras\".\r\n\r\nAlso I may have found the root of the camera switch bug which I will address with my code modification. I don't want to speculate until I have tested locally.\r\n\r\nI am undoubtedly not got to be as quick as you but I will get on it - you are obviously a far more proficient programmer than I and I have great respect for that!\r\n\r\nI am going to try the desktop Windows version and OS X version as well to see if UVC is working there since I know that OS X is treating it as a camera.\r\n\r\nOddly, Camera-Fi treats it as a camera (of sorts). I am just going to apply a patch similar to theirs for the UVC.\r\n\r\n"}}
{"actor":{"display_login":"cda725"}}