1

I'm trying to get events regarding YouTube video quality changes and rate adaptation and I have realized that there is no way to do that by YouTube Android API and switched to WebView and iFrame. At least there are functions of getting quality and rate adaptation in description of YouTbe iFrame API but I didnt get how to implement iFrame API in combination with WebView to have access to player's function.
Did anybody have such experience and can share some basic logic?

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
Mikhail I
  • 21
  • 1
  • 3

1 Answers1

1

you can look at this project (android-youtube-player) to solve the problem of WebView-IFrame API interaction.

But it won't solve the problem of controlling the quality of playback. As you can read here the method for changing the quality is now a no-op. Therefore, while it's technically possible to receive quality change events, you won't receive any, because you won't be able to actually change the quality.

You can also refer to issue #27 and issue #101.

Pierfrancesco Soffritti
  • 1,678
  • 1
  • 18
  • 22
  • Thanks for clarification! Just wonder how then they did applications for YouTube quality measurements... I know at least YoMo which provides some YouTube measurements and I guess they are able to get something more then just buffering time I'm getting from YouTube Android API. It is understandable why changing of quality is restricted but getting current value (as result of adaptation) would be quite useful without risks. – Mikhail I Aug 08 '18 at 08:38