【发布时间】:2016-11-01 01:19:53
【问题描述】:
我在GCKMediaMetadata 对象和GCKMediaInformation 对象contentID 中传递了相同的url 是否正确?我不知道我在GCKMediaInformation 的contentId 中传递了哪个URL,请帮助我,我是chromecast SDK 的初学者。提前致谢。
-(void)startCasting {
GCKMediaMetadata *metadata = [[GCKMediaMetadata alloc] init];
[metadata addImage:[[GCKImage alloc]
initWithURL:[NSURL URLWithString:@"https://fbcdn-photos-a-a.akamaihd.net/hphotos-ak-prn2/v/t1.0-0/s180x540/10444708_650079241771730_1270013251658544114_n.jpg?oh=f412367bc9632ed21aaf22bd7c08e3b2&oe=57FE0E19&__gda__=1476770561_aebfdf5d8dc13141e31a5848d8551cdb"]
width:480
height:360]];
GCKMediaInformation *mediaInformation =
[[GCKMediaInformation alloc] initWithContentID:@"https://fbcdn-photos-a-a.akamaihd.net/hphotos-ak-prn2/v/t1.0-0/s180x540/10444708_650079241771730_1270013251658544114_n.jpg?oh=f412367bc9632ed21aaf22bd7c08e3b2&oe=57FE0E19&__gda__=1476770561_aebfdf5d8dc13141e31a5848d8551cdb"
streamType:GCKMediaStreamTypeNone
contentType:@"image/jpeg"
metadata:metadata
streamDuration:0
customData:nil];
[_mediaControlChannel loadMedia:mediaInformation autoplay:YES playPosition:0];
}
【问题讨论】:
标签: ios objective-c chromecast google-cast