Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to cast a website to smart TV ? #7

Open
KrLikeblue opened this issue Aug 24, 2020 · 0 comments
Open

How to cast a website to smart TV ? #7

KrLikeblue opened this issue Aug 24, 2020 · 0 comments

Comments

@KrLikeblue
Copy link

Hello,

I want to cast website to smart TV. for example I want to load "www.google.com" in my iPhone and cast it to TV. How can I do that ?

What I will have to change in below code ?

 client.launch(appId: CastAppIdentifier.defaultMediaPlayer) { (result) in
           switch result {
           case .success(let app):
               let media = CastMedia(title: "TEST CAST", url: URL(string: "http://traffic.libsyn.com/billburr/MMPC_8-1-16.mp3")!, contentType: "audio/mp3")

               self.client.load(media: media, with: app) { result in
                   switch result {
                   case .success(let status):
                       print(status)

                   case .failure(let error):
                       print(error)
                   }
               }

           case .failure(let error):
               print(error)
           }
       }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant