设置 Apple TV 视频 JavaScript [英] Setting up Apple TV video JavaScript

查看:33
本文介绍了设置 Apple TV 视频 JavaScript的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个简单的函数可以启动处理 Apple TV 视频播放的 player

I have a simple function that will launch the player that handles video playback for the Apple TV

function launchPlayer() {
    var player = new Player();
    var playlist = new Playlist();
    var mediaItem = new MediaItem("video", "http://localhost:9001/videos/nsoperations.mp4");
    player.playlist = playlist;
    player.playlist.push(mediaItem);
    player.present();
}

根据 播放器文档,播放视频所需的只是播放器、播放列表(docs),以及一个媒体项目(文档).我已经掌握了所有这些,但是在运行我的代码时,出现错误:无法同时满足约束.据我所知,我们不处理这些内置播放器的自动布局.我用错了播放器吗?

According to the Player Documentation, all I needed to play a video back is a player, a playlist(docs), and a media item(docs). I've got all those, but when running my code, I get an error: Unable to simultaneously satisfy constraints. To my understanding, we don't deal with auto-layout for these built in players. Did I use the player wrong?

错误的完整细节如下:

(
    "<NSLayoutConstraint:0x7f8162e8f270 UIView:0x7f8162e964b0.leading == UIView:0x7f8162e9a640.leading>",
    "<NSLayoutConstraint:0x7f8162e945b0 H:|-(0)-[UIView:0x7f8162e964b0]   (Names: '|':TVRelatedContentView:0x7f8162e990a0 )>",
    "<NSLayoutConstraint:0x7f8162e930c0 H:|-(90)-[UIView:0x7f8162e9a640]   (Names: '|':TVRelatedContentView:0x7f8162e990a0 )>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162e8f270 UIView:0x7f8162e964b0.leading == UIView:0x7f8162e9a640.leading>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:35:59.886 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x7f8162e93a20 UIView:0x7f8162e964b0.trailing == UIView:0x7f8162e9a640.trailing>",
    "<NSLayoutConstraint:0x7f8162e92de0 UIView:0x7f8162e964b0.trailing == TVRelatedContentView:0x7f8162e990a0.trailing>",
    "<NSLayoutConstraint:0x7f8162e930c0 H:|-(90)-[UIView:0x7f8162e9a640]   (Names: '|':TVRelatedContentView:0x7f8162e990a0 )>",
    "<NSLayoutConstraint:0x7f8162e975e0 UIView:0x7f8162e9a640.width == TVRelatedContentView:0x7f8162e990a0.width>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162e93a20 UIView:0x7f8162e964b0.trailing == UIView:0x7f8162e9a640.trailing>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.024 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x7f8162e93a20 UIView:0x7f8162e964b0.trailing == UIView:0x7f8162e9a640.trailing>",
    "<NSLayoutConstraint:0x7f8162e92de0 UIView:0x7f8162e964b0.trailing == TVRelatedContentView:0x7f8162e990a0.trailing>",
    "<NSLayoutConstraint:0x7f8162e930c0 H:|-(90)-[UIView:0x7f8162e9a640]   (Names: '|':TVRelatedContentView:0x7f8162e990a0 )>",
    "<NSLayoutConstraint:0x7f8162e975e0 UIView:0x7f8162e9a640.width == TVRelatedContentView:0x7f8162e990a0.width - 2010>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162e93a20 UIView:0x7f8162e964b0.trailing == UIView:0x7f8162e9a640.trailing>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.092 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x7f8162e975e0 UIView:0x7f8162e9a640.width == TVRelatedContentView:0x7f8162e990a0.width - 2010>",
    "<NSLayoutConstraint:0x7f8162e23cd0 'UIView-Encapsulated-Layout-Width' H:[TVRelatedContentView:0x7f8162e990a0(1920)]>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162e975e0 UIView:0x7f8162e9a640.width == TVRelatedContentView:0x7f8162e990a0.width - 2010>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.126 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x7f8162c8e520 H:|-(>=70)-[UIView:0x7f8162e1dbd0]   (Names: '|':_UIAlertControllerActionView:0x7f8162ec3a30 )>",
    "<NSLayoutConstraint:0x7f8162c0b2f0 UIView:0x7f8162e1dbd0.trailing <= _UIAlertControllerActionView:0x7f8162ec3a30.trailing - 70>",
    "<NSLayoutConstraint:0x7f8164266d40 UIView:0x7f8164226270.width == _UIAlertControllerCollectionViewCell:0x7f8164228e10.width>",
    "<NSLayoutConstraint:0x7f816423abd0 _UIAlertControllerActionView:0x7f8162ec3a30.width == UIView:0x7f8164226270.width>",
    "<NSLayoutConstraint:0x7f8164224720 'UIView-Encapsulated-Layout-Width' H:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c0b2f0 UIView:0x7f8162e1dbd0.trailing <= _UIAlertControllerActionView:0x7f8162ec3a30.trailing - 70>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.127 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x7f8162c87400 V:[_UIAlertControllerActionView:0x7f8162ec3a30(>=80)]>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>",
    "<NSLayoutConstraint:0x7f816425a130 'UIView-Encapsulated-Layout-Height' V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c87400 V:[_UIAlertControllerActionView:0x7f8162ec3a30(>=80)]>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.127 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x7f8162c88760 UIImageView:0x7f8162e22190.centerY == _UIAlertControllerActionView:0x7f8162ec3a30.centerY>",
    "<NSLayoutConstraint:0x7f8162c86800 UIImageView:0x7f8162e22190.bottom <= _UIAlertControllerActionView:0x7f8162ec3a30.bottom - 6>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>",
    "<NSLayoutConstraint:0x7f816425a130 'UIView-Encapsulated-Layout-Height' V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c86800 UIImageView:0x7f8162e22190.bottom <= _UIAlertControllerActionView:0x7f8162ec3a30.bottom - 6>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.128 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x7f8162c88760 UIImageView:0x7f8162e22190.centerY == _UIAlertControllerActionView:0x7f8162ec3a30.centerY>",
    "<NSLayoutConstraint:0x7f8162c867b0 V:|-(>=6)-[UIImageView:0x7f8162e22190]   (Names: '|':_UIAlertControllerActionView:0x7f8162ec3a30 )>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>",
    "<NSLayoutConstraint:0x7f816425a130 'UIView-Encapsulated-Layout-Height' V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c88760 UIImageView:0x7f8162e22190.centerY == _UIAlertControllerActionView:0x7f8162ec3a30.centerY>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.138 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
    (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) 
(
    "<NSAutoresizingMaskLayoutConstraint:0x7f8162f51c30 h=--& v=--& H:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>",
    "<NSLayoutConstraint:0x7f8162c8e520 H:|-(>=70)-[UIView:0x7f8162e1dbd0]   (Names: '|':_UIAlertControllerActionView:0x7f8162ec3a30 )>",
    "<NSLayoutConstraint:0x7f8162c0b2f0 UIView:0x7f8162e1dbd0.trailing <= _UIAlertControllerActionView:0x7f8162ec3a30.trailing - 70>",
    "<NSLayoutConstraint:0x7f8164266d40 UIView:0x7f8164226270.width == _UIAlertControllerCollectionViewCell:0x7f8164228e10.width>",
    "<NSLayoutConstraint:0x7f816423abd0 _UIAlertControllerActionView:0x7f8162ec3a30.width == UIView:0x7f8164226270.width>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c0b2f0 UIView:0x7f8162e1dbd0.trailing <= _UIAlertControllerActionView:0x7f8162ec3a30.trailing - 70>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.138 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
    (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) 
(
    "<NSAutoresizingMaskLayoutConstraint:0x7f8162f51cd0 h=--& v=--& V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>",
    "<NSLayoutConstraint:0x7f8162c87400 V:[_UIAlertControllerActionView:0x7f8162ec3a30(>=80)]>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c87400 V:[_UIAlertControllerActionView:0x7f8162ec3a30(>=80)]>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.139 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
    (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) 
(
    "<NSAutoresizingMaskLayoutConstraint:0x7f8162f51cd0 h=--& v=--& V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>",
    "<NSLayoutConstraint:0x7f8162c88760 UIImageView:0x7f8162e22190.centerY == _UIAlertControllerActionView:0x7f8162ec3a30.centerY>",
    "<NSLayoutConstraint:0x7f8162c867b0 V:|-(>=6)-[UIImageView:0x7f8162e22190]   (Names: '|':_UIAlertControllerActionView:0x7f8162ec3a30 )>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c88760 UIImageView:0x7f8162e22190.centerY == _UIAlertControllerActionView:0x7f8162ec3a30.centerY>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.139 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
    (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) 
(
    "<NSAutoresizingMaskLayoutConstraint:0x7f8162f51cd0 h=--& v=--& V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>",
    "<NSLayoutConstraint:0x7f8162c867b0 V:|-(>=6)-[UIImageView:0x7f8162e22190]   (Names: '|':_UIAlertControllerActionView:0x7f8162ec3a30 )>",
    "<NSLayoutConstraint:0x7f8162c86800 UIImageView:0x7f8162e22190.bottom <= _UIAlertControllerActionView:0x7f8162ec3a30.bottom - 6>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c86800 UIImageView:0x7f8162e22190.bottom <= _UIAlertControllerActionView:0x7f8162ec3a30.bottom - 6>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.144 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
    (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) 
(
    "<NSAutoresizingMaskLayoutConstraint:0x7f8162f51c30 h=--& v=--& H:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>",
    "<NSLayoutConstraint:0x7f8162c8e520 H:|-(>=70)-[UIView:0x7f8162e1dbd0]   (Names: '|':_UIAlertControllerActionView:0x7f8162ec3a30 )>",
    "<NSLayoutConstraint:0x7f8162c0b2f0 UIView:0x7f8162e1dbd0.trailing <= _UIAlertControllerActionView:0x7f8162ec3a30.trailing - 70>",
    "<NSLayoutConstraint:0x7f8164266d40 UIView:0x7f8164226270.width == _UIAlertControllerCollectionViewCell:0x7f8164228e10.width>",
    "<NSLayoutConstraint:0x7f816423abd0 _UIAlertControllerActionView:0x7f8162ec3a30.width == UIView:0x7f8164226270.width>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c0b2f0 UIView:0x7f8162e1dbd0.trailing <= _UIAlertControllerActionView:0x7f8162ec3a30.trailing - 70>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.145 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
    (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) 
(
    "<NSAutoresizingMaskLayoutConstraint:0x7f8162f51cd0 h=--& v=--& V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>",
    "<NSLayoutConstraint:0x7f8162c87400 V:[_UIAlertControllerActionView:0x7f8162ec3a30(>=80)]>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c87400 V:[_UIAlertControllerActionView:0x7f8162ec3a30(>=80)]>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.145 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
    (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) 
(
    "<NSAutoresizingMaskLayoutConstraint:0x7f8162f51cd0 h=--& v=--& V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>",
    "<NSLayoutConstraint:0x7f8162c88760 UIImageView:0x7f8162e22190.centerY == _UIAlertControllerActionView:0x7f8162ec3a30.centerY>",
    "<NSLayoutConstraint:0x7f8162c867b0 V:|-(>=6)-[UIImageView:0x7f8162e22190]   (Names: '|':_UIAlertControllerActionView:0x7f8162ec3a30 )>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c88760 UIImageView:0x7f8162e22190.centerY == _UIAlertControllerActionView:0x7f8162ec3a30.centerY>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
2015-09-11 07:36:00.146 TestingTVML[3354:323153] Unable to simultaneously satisfy constraints.
    Probably at least one of the constraints in the following list is one you don't want. 
    Try this: 
        (1) look at each constraint and try to figure out which you don't expect; 
        (2) find the code that added the unwanted constraint or constraints and fix it. 
    (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) 
(
    "<NSAutoresizingMaskLayoutConstraint:0x7f8162f51cd0 h=--& v=--& V:[_UIAlertControllerCollectionViewCell:0x7f8164228e10(0)]>",
    "<NSLayoutConstraint:0x7f8162c867b0 V:|-(>=6)-[UIImageView:0x7f8162e22190]   (Names: '|':_UIAlertControllerActionView:0x7f8162ec3a30 )>",
    "<NSLayoutConstraint:0x7f8162c86800 UIImageView:0x7f8162e22190.bottom <= _UIAlertControllerActionView:0x7f8162ec3a30.bottom - 6>",
    "<NSLayoutConstraint:0x7f8164266d90 UIView:0x7f8164226270.height == _UIAlertControllerCollectionViewCell:0x7f8164228e10.height>",
    "<NSLayoutConstraint:0x7f816425e320 _UIAlertControllerActionView:0x7f8162ec3a30.height == UIView:0x7f8164226270.height>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7f8162c86800 UIImageView:0x7f8162e22190.bottom <= _UIAlertControllerActionView:0x7f8162ec3a30.bottom - 6>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.      
  [2]: https://developer.apple.com/library/prerelease/tvos/documentation/TVMLJS/Reference/TVJSPlaylist_Ref/index.html#//apple_ref/javascript/cl/Playlist
  [3]: https://developer.apple.com/library/prerelease/tvos/documentation/TVMLJS/Reference/TVJSMediaItem_Ref/index.html#//apple_ref/javascript/cl/MediaItem

推荐答案

你的样品没问题,可以工作.即使有约束错误,但玩家也不是很宽容.

Your sample is ok and do work. Even with the constraint errors, but player is not very forgiving.

我认为您正在使用 Python SimpleHTTPServer 进行测试,它不适用于视频流,但是如果您使用 Apache 或例如直接来自苹果的此文件http://trailers.apple.com/movies/focus_features/9/9-clip_480p.mov" 它将起作用.

I think you're using the Python SimpleHTTPServer for your test, it did not worked for video streaming, but if you use Apache or for example this file directly from apple "http://trailers.apple.com/movies/focus_features/9/9-clip_480p.mov" it will work.

这篇关于设置 Apple TV 视频 JavaScript的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆