我可以按照 Google 提供的教程发现 chromecast:https://developers.google.com/cast/cast_2nd-screen_app_tutorial
然后我观察了 Google 编写的应用,例如 Google Music 和 YouTube。这些应用不仅可以通过同一个 MediaRouteButton 发现 chromecast,还可以发现 NexusQ 和 Google TV 等其他在线流媒体。
谁能告诉我如何像Google那样发现局域网中的所有设备? 我可以使用 MediaRouteButton 或 MediaRoute 来执行此操作吗?
最佳答案
看看我开源的 DIAL 应用程序:https://github.com/entertailion/DIAL
这将发现 Google TV 和 ChromeCast 设备,实际上是本地网络上作为 DIAL 服务器的任何设备。
您可以阅读有关 DIAL 规范的信息:http://www.dial-multiscreen.org/dial-protocol-specification
关于android - 如何在 Android 上使用 MediaRoute API 发现 Google TV 和 Nexus-Q 等设备?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18222294/