Update README.md to include mention of GetDisplayMedia

Added to the FAQ to mention GetDisplayMedia if using driver/screen in the section explaining solutions to the error that gets throne if you don't make that swap in example code.
This commit is contained in:
Alex Harvey
2023-05-10 18:00:54 -07:00
committed by Atsushi Watanabe
parent 18cf1fe38a
commit 4eea55285e
+2 -1
View File
@@ -193,6 +193,7 @@ So, when `mediadevices` returns `failed to find the best driver that fits the co
* Driver was not imported as a side effect in your program, e.g. `import _ github.com/pion/mediadevices/pkg/driver/camera`
* Your constraint is too strict that there's no driver can fullfil your requirements. In this case, you can try to turn up the debug level by specifying the following environment variable: `export PION_LOG_DEBUG=all` to see what was too strict and tune that.
* Your driver is not supported/implemented. In this case, you can either let us know (file an issue) and wait for the maintainers to implement it. Or, you can implement it yourself and register it through `RegisterDriverAdapter`
* If trying to use `import _ github.com/pion/mediadevices/pkg/driver/screen` note that you will need to use `GetDisplayMedia` instead of `GetUserMedia`
#### Failed to find vpx/x264/mmal/opus codecs
Since `mediadevices` uses cgo to access video/audio codecs, it needs to find these libraries from the system. To accomplish this, [pkg-config](https://www.freedesktop.org/wiki/Software/pkg-config/) is used for library discovery.
@@ -228,4 +229,4 @@ If you need commercial support or don't want to use public methods you can conta
Check out the [contributing wiki](https://github.com/pion/webrtc/wiki/Contributing) to join the group of amazing people making this project possible: [AUTHORS.txt](./AUTHORS.txt)
### License
MIT License - see [LICENSE](LICENSE) for full text
MIT License - see [LICENSE](LICENSE) for full text