Friday, January 1, 2016

Integrating Chromecast with Kaltura SDK (iOS)

Their documentation says it is built in, but I couldn't find a sample anywhere, so here it is for everyone on how to integrate Chromecast with your Kaltura Player.

- (KPViewController *)player {
    if (!_player) {
        KPPlayerConfig *config = [[KPPlayerConfig alloc] initWithDomain:@"http://cdnapi.kaltura.com"
                                                               uiConfID:@"PlayerConfigId"
                                                              partnerId:@"YourPartnerId"];
        config.entryId = @"YourContentId";
        
        [config addConfigKey:@"chromecast" withDictionary:@{@"plugin":@"true"}];
        
        config.cacheSize = 0.8;
        _player = [[KPViewController alloc] initWithConfiguration:config];
    }
    return _player;
}

I'll cherish the moment where I had to demo this to a customer in order to gain the confidence and to prove my report was correct. 

0 comments:

Post a Comment