【问题标题】:Customizing YouTube Player in iOS在 iOS 中自定义 YouTube 播放器
【发布时间】:2014-10-18 02:52:55
【问题描述】:

我有一个使用 Youtube 的 YTPlayerView 流式传输 YouTube 视频的应用程序。我想开始定制它(控制/旋转) 在网上搜索了几天后,我找不到答案。

我能找到的只是使用 JS/Ruby/HTML 来更改播放器。有谁知道实现这一点的方法吗?

【问题讨论】:

    标签: ios youtube-api ytplayerview


    【解决方案1】:

    播放器控件可以在下面描述的字典中给出,并且可以具有值 0,1,2 检查此链接以获取控件功能 https://developers.google.com/youtube/player_parameters#controls

    NSDictionary *playerVars = @{
      @"controls" : @0,
      @"playsinline" : @1,
      @"autohide" : @1,
      @"showinfo" : @0,
      @"modestbranding" : @1
    };
    [self.playerView loadWithVideoId:videoId playerVars:playerVars];
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2019-09-28
      • 1970-01-01
      • 2014-09-23
      相关资源
      最近更新 更多