Here is a Xcode project for Apple TV 4

iOS, iPad, iPhone, tvOS specific usage questions
Airrud
New Cone
New Cone
Posts: 6
Joined: 14 Nov 2015 17:50

Here is a Xcode project for Apple TV 4

Postby Airrud » 19 Dec 2015 15:17

Hello all,
I have developed a project for the Apple TV for life streaming from Enigma 2 powered SAT/cable receivers with WebIf. It also supports EPG and the view of recordings. The stream is stable and there is now difference in the quality also in full HD.

Put the IP address of the receiver on the text field on top of the screen. You can also use the Bonjour name if this is enabled on the receiver.
The web port should be 80.
The streaming port in my case is 8001 (VU Plus Duo with VTI image).
HTTPS is not supported.
Loading the EPG data is done in the background because it can take up to 30 minutes. I store the data so that at the next start only the updates will loaded.
The "Movies" button opens the list of recorded movies. It can takes some time if the HD in the receiver is sleeping.
If a movie is playing you can swipe down for EPG info.

In MobileVLCKit.xcodeproject I have built the releases for device and simulator. Then I put them together with:
$ lipo -create Release-appletvos/libTVVLCKit.a Release-appletvsimulator/libTVVLCKit.a -o libTVVLCKit.a
I stored the lib directly in the project and also the header files (which I had to change a little bit because of the pathes).

There are some issues:
- The app does not check if recordings are available (disk built in).
- During compiling some warnings appear. I think simulator and device are not correctly differentiated.
- tvOS does not a allow to store permanent data to the documents folder. I used the temp folder for storing IP address, ports and EPG data. But the temp folder is not save.
- The pause/stop feature I have disabled - it seems it does not work. See the method (void)pausePlayPressed in VideoViewController.m.
- Selecting of special audio tracks does not work. I have disabled my tries. See also the method (void)pausePlayPressed in VideoViewController.m.
- Timeshift is not implemented. I does not know the API in WebIf for doing that.

Here you can download the project: https://www.dropbox.com/s/ol73m4sbxguox ... s.zip?dl=0

Screenshots:
https://www.dropbox.com/s/srwrpdailc933 ... 8.png?dl=0
https://www.dropbox.com/s/gwkh8nwba46m4 ... 4.png?dl=0

Use the project as proof of concept.
Use it as example.
What about to store it on github to build together a nice app...

Best regards, Matthias

ssbmaccom
Cone that earned his stripes
Cone that earned his stripes
Posts: 184
Joined: 26 Nov 2015 15:21
Operating System: Mac OS, iOS, tvOS

Re: Here is a Xcode project for Apple TV 4

Postby ssbmaccom » 20 Dec 2015 11:06

Hi Matthias,

I did the same and the App (vuplusTV) is already submitted to the AppStore for beta test via TestFlight. I guess both projects are really similar.

I also have seen the issue with Play/Pause. For live TV-Streams I just mute the audio, on recordings it works.
Changing the playback head (rewind and fast forward) is also limited. Having the HTTP stream in only one single file does not allow rewind at all and fast forward only works up to 4x, everything beyond is above what WebIF can support (on my vu+ Solo2). Obviously no rewind and fast forward on live TV streams, only on recordings.

So far I have not tried to offer channel selection. I also have seen, that volume changes do not seem to work. For the first version of my App I have disabled this.
I also have disabled Timeshift, except you can watch streams while they are recorded in the recordings overview, but this is not really nice for the built-in drive.

I store the IP address in the preferences of the app, these should persist even when the app is removed form the AppleTV, at least via Cloud Backup. I do not store anything else, EPG data is anyway "volatile" and I only load EPGNow and EPGNext, I never load the full EPG for the next days. I also do not download the PIcons for the TV stations.

I have my project on GitLab, but so far not as public project. But as I have found a sponsor who pays the Apple developer program, the App will be free of charge and I tend to open source it as LGPLv2 like VLCKit. But not at the current moment before the App can be officially launched in the App Store. The beta is currently in App Review, I hope they finish it before intunesconnect is closed during x-Mas holidays.

As your project is also called VU Plus - I assume you are also testing it for the vu+ devices - nice coincidence ;-) Check http://www.vuplus-support.org, I have opened a thread in the iOS App area about my app. Of course I will also be happy to welcome you to test it via TestFlight and we can cooperate on further evolutions in this App - this will really be a more than good reason to make my GitLab repo public. In case you have an account on GitLab, I can add you to the project immediately.
As mentioned - I assume both are more than just similar. With joined efforts we will bring it forward ;-)

Last not least - I submitted a small change that removes at least some warnings when building the MobileVLCKit in Xcode. I was not able to send the patches directly (git sendmail has issues to send via my iCloud account), but Felix submitted one of my 2 suggested patches (the first one was not included, because it would break the code on iOS < 9).

ssbmaccom
Cone that earned his stripes
Cone that earned his stripes
Posts: 184
Joined: 26 Nov 2015 15:21
Operating System: Mac OS, iOS, tvOS

Re: Here is a Xcode project for Apple TV 4

Postby ssbmaccom » 20 Dec 2015 11:09

DIrect link to the thread on the vuplus forum: http://www.vuplus-support.org/wbb3/inde ... adID=85644

matrog
Blank Cone
Blank Cone
Posts: 42
Joined: 27 Sep 2015 08:55

Re: Here is a Xcode project for Apple TV 4

Postby matrog » 21 Dec 2015 15:10

Hi, very good project, I'll try wih my dreambox

Code: Select all

- Selecting of special audio tracks does not work. I have disabled my tries. See also the method (void)pausePlayPressed in VideoViewController.m.
what do you mean? I did a similar project and I'm able to change audio track (aka language..italian, english, original..)

ssbmaccom
Cone that earned his stripes
Cone that earned his stripes
Posts: 184
Joined: 26 Nov 2015 15:21
Operating System: Mac OS, iOS, tvOS

Re: Here is a Xcode project for Apple TV 4

Postby ssbmaccom » 21 Dec 2015 17:35

I will explore this audio channel selection later, after my app passed the review fot beta testing. When this does not happen until tomorrow, then itunesconnect is closed for XMas season. Maybe I will then add this. I alr ady fixed some small stuff with EPG display/update and other small things.
But the next project is pending to start soon.

I havent had a look into Matthias code, as I assume it is really very close to mine.

BTW: the lipo command up in the top post works fine, but it does not allow archiving, as bitcode gets stripped. Use of rhe simulator is anyway pain and has very poor performance, so i only test on my device. So I build the VLCKit for archiving and then use the resulting library.

matrog
Blank Cone
Blank Cone
Posts: 42
Joined: 27 Sep 2015 08:55

Re: Here is a Xcode project for Apple TV 4

Postby matrog » 21 Dec 2015 21:04

I tested the attached project...and doesn't work out of the box (at least on my dreambox).

First, there's a typo in the URL... then It does not zap to channel before playing...maybe it's only a dreambox issue...but Enigma should be the same on all boxes

ssbmaccom
Cone that earned his stripes
Cone that earned his stripes
Posts: 184
Joined: 26 Nov 2015 15:21
Operating System: Mac OS, iOS, tvOS

Re: Here is a Xcode project for Apple TV 4

Postby ssbmaccom » 29 Dec 2015 13:04

@matrog
I currently upload my vuplus TV app to the app store for TestFlight Review. As I only own a vu+ Solo2, more helpers are welcome.
If you like to join the TestFlight team, let me know.

matrog
Blank Cone
Blank Cone
Posts: 42
Joined: 27 Sep 2015 08:55

Re: Here is a Xcode project for Apple TV 4

Postby matrog » 29 Dec 2015 14:06

would be good thanks

gavla
New Cone
New Cone
Posts: 7
Joined: 23 Apr 2016 15:53

Re: Here is a Xcode project for Apple TV 4

Postby gavla » 24 Apr 2016 02:22

Hi there this is a really interesting project as I'm also a developer with several apps in the app store and also have a vu+duo2 with quad tuners. it's a nice job you have done so far but I stumbled on this page by accident as I'm working on another project that requires TVVLCKit preferably with bit code as I'm sure you are aware, archiving any Xcode project without bit code is now impossible for TVOS. Now the issue I am having is that at this moment I can't compile TVVLCKit with or without bit code and I wondered if you would be able to do it as you seemed to manage a compile already, or lend some advice to the same end. I'm that desperate for this i've even created a job opportunity on freelancer website https://www.freelancer.co.uk/projects/M ... t-10306030 so any help you could offer would be great or even accept the freelancer post and bag a few reddies to put into your project.

Keep up the good work Gav

ssbmaccom
Cone that earned his stripes
Cone that earned his stripes
Posts: 184
Joined: 26 Nov 2015 15:21
Operating System: Mac OS, iOS, tvOS

Re: Here is a Xcode project for Apple TV 4

Postby ssbmaccom » 25 Apr 2016 10:17

Hi @gavia, thanks for your request, I replied via board mail ;-)
And feel free to test the vuplusTV App - it is free and the next version is in preparation with a newer version of TVVLCKit included.


Return to “VLC for iOS, iPadOS and Apple TV”

Who is online

Users browsing this forum: No registered users and 62 guests