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

Port to Apple TV #184

Closed
kaeltis opened this issue Nov 4, 2015 · 202 comments
Closed

Port to Apple TV #184

kaeltis opened this issue Nov 4, 2015 · 202 comments

Comments

@kaeltis
Copy link

kaeltis commented Nov 4, 2015

From what I've read, porting from iOS to Apple TV should be fairly easy - would be awesome to see moonlight on the new Apple TV 😍

@jeaz
Copy link

jeaz commented Nov 4, 2015

Yeah, that would be an awesome addition.

@awaescher
Copy link

+1

@Maimberis
Copy link

would love to see this as well now with the app store on the new Apple TV

@InfernoDigital
Copy link

I agree! It would be way easier than streaming from an iphone to it!

@basvroegop
Copy link

This would be amazing. Though I'm not sure how you'd handle the on-screen controls for start, select, L3 and R3.

@kaeltis
Copy link
Author

kaeltis commented Nov 17, 2015

Afaik the AppleTV supports some controllers - or just use one connected directly to the PC.

@basvroegop
Copy link

There's support for official MFi controllers, but those don't have buttons for start, select, L3 and R3. The app solves this on iPhone and iPad by showing virtual buttons on the screen, but that won't work on Apple TV.

That being said, seems like KinoConsole solved this by showing a dropdown for those buttons when hitting the menu button on the controller. It's not perfect, but should at least get things through Apple's approval.

Anyway, noticed I was a bit early posting here. Turns out the Apple TV-version has already been discussed and seems like they're at least investigating that. Heres the thing @mrb113 posted a while back:

#177

@InfernoDigital
Copy link

@basvroegop Wow! Thanks for that link! I hope they "investigate" further now that the iOS app has been released. Using an AppleTV to stream PC games would be an awesome, cheaper alternative to a SHIELD.

@basvroegop
Copy link

Yeah, agreed! Recently got a Steam Link, but Moonlight actually performs a lot better. Would be great having this on the tv instead.

@InfernoDigital
Copy link

Yeah, at the moment I just have moonlight on my Ipad mini, but we have an old AppleTV, and if we ever upgraded to the new one I'd definitely want this on it!

@SvatoplukHus
Copy link

it is the right move, any ETA?

@mrb113
Copy link
Member

mrb113 commented Nov 22, 2015

Thanks for letting us know which platforms you guys would like to see Moonlight on in the future. We are investigating the feasibility of this - if, in the future, we commit to bringing Moonlight to AppleTV, we will provide an update. For now, I am marking this as a feature request.

@basvroegop
Copy link

Noticed someone made an unofficial Apple TV port. No repository for it yet though. Here's hoping! http://www.macrumors.com/2015/12/02/apple-tv-pc-game-streaming/

@Aghassi
Copy link
Contributor

Aghassi commented Dec 3, 2015

@basvroegop Unfortunately the guy who did that hasn't published his source code. @dwaxemberg is looking into it I'm pretty sure. It is just a matter of porting at this point. In due time.

@kevsmithpublic
Copy link

That guy just did :-) I needed to sleep, now posted to Github
https://github.com/kevsmithpublic/moonlight-ios

Just a note, I did this as a quick and dirty port so I could use it, I'm sure the original developers will do a proper port in due course.

@Aghassi
Copy link
Contributor

Aghassi commented Dec 3, 2015

@kevsmithpublic You rock, thanks man! @dwaxemberg and I will have a look when we get a chance. Thanks!

@basvroegop
Copy link

You're a real hero, @kevsmithpublic. Thanks a ton! Time to bag my Steam Link again.

@mrb113
Copy link
Member

mrb113 commented Dec 3, 2015

Thanks @kevsmithpublic! We're all excited to see your port. We plan on pulling in as much of your work as is possible if we're able to make a tvOS port.

For the rest of the community wondering what the holdup is on the official Moonlight end:
We can't use what Kevin did to submit to Apple. He had to modify the SDK to enable some functionality Moonlight is depending on - we obviously can't submit something like that to Apple. We're following up to figure out what we can do to make a tvOS port that we can ship on the App Store.

Rest assured that it's one of our top priorities right now. Thanks for bumping this issue and letting us know that a tvOS port is important to you guys!

@basvroegop
Copy link

Great to hear, @mrb113!

I just installed @kevsmithpublic's port and it seems to work great. I'm no developer though, so it took me a while to find the file he references to on his repository. Reached it via the following route eventually:

Rightclick the Xcode program > Show package contents > Contents > Developer > Platforms > AppleTVOS.platform > Developer > SDKs > APPLETVOS.sdk > System > Library > Frameworks > AVFoundation.framework > Headers > AVSampleBufferDisplayLayer

Needed to rightclick the folder it was in, hit 'Show info', hit the lock at the bottom and give myself permission to write in that folder first, though.

Really smooth experience so far at least! Only problem I really ran into was a glitchy settings tab on the left, which means you can't really change the bitrate or resolution like on iOS.

@ceesco53
Copy link

ceesco53 commented Dec 3, 2015

If I want to aid in developing this, should I base from @kevsmithpublic port for now? I plan on using the stratus xl steel series controller.

Edit: the steel series nimbus controller looks to be made for the Apple TV. I'll use that too, but I don't have one yet.

@Aghassi
Copy link
Contributor

Aghassi commented Dec 3, 2015

@ceesco53 It would be better to start with the Moonlight source, and build fresh then work with @kevsmithpublic modified version. As @mrb113 mentioned, that version uses a modified version of the SDK, which we can't publish to Apple's App Store. That doesn't mean however you can't mirror some of what was done in the other port, as long as it isn't the modified SDK part.

@cgutman
Copy link
Member

cgutman commented Dec 3, 2015

The AVSampleBufferDisplayLayer issue will bite us whether or not we use Kevin's code. TvOS's docs say that AVSampleBufferDisplayLayer should be available, so I've filed a bug report with Apple.

In the meantime, we anyone who wants to help should grab either Kevin's source or the code in master today and begin fixing tvOS incompatibilities.

@ClintChil
Copy link

I looked into porting moonlight to tvOS last month and ran into the AVSampleBufferDisplayLayer prohibited in tvOS issue.

After some searching, someone suggested using software decoding as a work around. That's where I gave up on my fork because I figured losing hardware based decoding would have too big of an impact on performance.

Here is a list of prohibited classes and methods in tvOS:

https://gist.github.com/gonzalolarralde/fb9bd2b164e88a287ad8

@swallace17
Copy link

This would be awesome! If an official port is not currently possible due to issues with hardware decoding and private API's as suggested by ClintChil above, is there any possibility the official team would take kevsmithpublic's approach involving modifying the SKD, make the process more official and available for side-loading via X-Code only?

Or is an official version using permissible methods/classes a real possibility?

@at45
Copy link

at45 commented Jan 21, 2016

Putting in a comment to follow-up on this, is there any updates yet?

@mrb113
Copy link
Member

mrb113 commented Jan 22, 2016

We are not going to modify the SDK in order to release Moonlight. Any release for Apple TV will be on the App Store and modifying the SDK is not permissible there.

As far as I know, the relevant APIs that we need for Moonlight to work are still not available for use on Apple TV. We are investigating if this will be fixed by Apple in a later update. As Cameron said, he's filed a bug with them. All we can do now is be patient 😄

@amolloy
Copy link

amolloy commented Jan 22, 2016

Out of curiosity, has anyone filed a RADAR bug with Apple requesting they make this API available to tvOS? On the one hand, I feel like a lot of the "TV Prohibited" APIs were ones they probably just didn't get a chance to vet in time to ship. On the other hand, there may be actual reasons the API in question has been marked prohibited, and there's a reasonable chance Apple won't do anything about it one way or the other without at least one issue logged in their database.

@mrb113
Copy link
Member

mrb113 commented Jan 22, 2016

As @cgutman said,

TvOS's docs say that AVSampleBufferDisplayLayer should be available, so I've filed a bug report with Apple.

@amolloy
Copy link

amolloy commented Jan 22, 2016

Sorry, missed that.

On Fri, Jan 22, 2016 at 12:19 PM, Michelle Bergeron <
notifications@github.com> wrote:

As @cgutman https://github.com/cgutman said,

TvOS's docs say that AVSampleBufferDisplayLayer should be available, so
I've filed a bug report with Apple.


Reply to this email directly or view it on GitHub
#184 (comment)
.

@serafimovich
Copy link

great work guys, thanks.. can't wait for apple tv release now)
tried it on iphone and it works pretty smooth.. hope i'll get my mfi controller in a couple of weeks and will try to compile and test moonlight on apple tv

@lifeiscontent
Copy link

lifeiscontent commented Feb 2, 2019

@cgutman the Provenance team has handle the button mapping pretty elegantly, basically the way they do it is if you hold down L1,L2,R1,R2 at the same time, the A,B,X,Y buttons on the controller can be used for select,start,L3,R3.

X = L3
B = R3
Y = SELECT
A = START

@williamdev
Copy link

Hey guys for the time being just use the Steam Link app for Apple TV

@dinooo13
Copy link

dinooo13 commented Jun 4, 2019

Hey guys watched the keynote? Apple TV now supports Xbox and Playstation Controllers natively! I have already tried it with a few games (not moonlight) works like a charm!

@maddox
Copy link

maddox commented Jun 4, 2019

I’m most curious about the latency.

Also, I assume these just show up as mfi controllers, and that’s why they just work with other games already?

@dinooo13
Copy link

dinooo13 commented Jun 4, 2019

I don‘t have a standard mfi controller to compare them to one another but the latency seems to be okay. Yeah it‘s pretty easy to set up just navigate to the bluetooth menu and activate pairing mode on your controller to connect.

@ajmi982
Copy link

ajmi982 commented Jun 4, 2019 via email

@williamdev
Copy link

Hey guys watched the keynote? Apple TV now supports Xbox and Playstation Controllers natively! I have already tried it with a few games (not moonlight) works like a charm!

Hey, is it part of the Apple TV software yet or will they add that feature later. I cant seem to be able to pair my ds4 controller to my apple tv right now.

@williamdev
Copy link

williamdev commented Jun 4, 2019

And does netflix stop working when you install the beta tvos.

@dinooo13
Copy link

dinooo13 commented Jun 4, 2019

Sorry I should‘ve posted my setup i got an Apple TV 4k and I‘m on tvOS 13 beta 1 and yes for me (in germany) Netflix still works like normal. I only tried the Xbox One Controller not the DualShock 4 but it should work too. Just go to the Bluetooth settings and activate pairing mode on your controller then it shows up and connects like a normal mfi controller.

@igno2k
Copy link

igno2k commented Aug 6, 2019

Any hints how to get it running on a current Apple TV 4K with tvOS 13 beta?

@dMopp
Copy link

dMopp commented Sep 1, 2019

Please please please. Adding it to AppleTV. This would increase the usage by 10000% :D (of AppleTV)

Ah and yez, Steam, Netflix and Co are working with XBox One Controller now (Beta TVOS13). So please please please, release at least an beta in testflight :D

@williamdev
Copy link

Just use Steam Link for now. Works well.

@dMopp
Copy link

dMopp commented Sep 1, 2019 via email

@williamdev
Copy link

On your Steam Application Library, go to the bottom left-hand corner and hit add a game>add a non steam game. Then select your game

@williamdev
Copy link

Then it will appear in your library

@williamdev
Copy link

Google is your friend like always

@dMopp
Copy link

dMopp commented Sep 1, 2019

THis does not work with Windows Live Games, like Forza :(

@williamdev
Copy link

williamdev commented Sep 1, 2019 via email

@dMopp
Copy link

dMopp commented Sep 1, 2019

Nope. And tried SteamLink 4K now. Horrible latency :( So Iam waiting for moonlight on ATV :D

@Trashpants
Copy link

With the release of tvOS 13 now out and support for Xbox and PS4 controllers now in the hands of regular people we should be at a stage where we’re basically good to go with this right?

What, outside of the regular iOS app, is missing from the current build to get a full tvOS release?

@mbial
Copy link

mbial commented Sep 26, 2019

If there are issues getting the app approved in the App Store, perhaps it's worthwhile to consider a collaborative effort with AltStore. This is a new concept where each iOS device is treated as a developer device that will permit sideloading and reauthenticating apps using a background desktop app. I'm not certain whether there would be issues with AppleTV vs. other iOS devices that mount in iTunes, but it's definitely worthy of consideration.

@parndt
Copy link

parndt commented Oct 16, 2019

#380 (comment)

@cgutman
Copy link
Member

cgutman commented Oct 28, 2019

It's out on the App Store (approved this morning) - https://apps.apple.com/us/app/moonlight-game-streaming/id1000551566?ls=1

@cgutman cgutman closed this as completed Oct 28, 2019
@maddox
Copy link

maddox commented Oct 28, 2019

lmao, I never thought I’d live to see this issue closed.

Great work everyone!

@Argon2000
Copy link

Finally, been watching this thread for years :D

@parndt
Copy link

parndt commented Oct 28, 2019

Thanks @cgutman !! That's excellent news.

@mattbenic
Copy link

Congratulations, this is great news :)

@jamesfmackenzie
Copy link

Great news! Will download today!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests