Jump to content

AppleTV Plugin Code Sample -> Local Movie Player


  • Please log in to reply
33 replies to this topic

#21
grabberslasher

grabberslasher

    Ekky ekky ekky ekky p'tang zoom-boing <incoherent mumble&

  • Members
  • PipPipPip
  • 161 posts
You must not have movies in the same folder as amok's compiled version is pointing to. The code has the path editable before compilation, so you use that and compile it if you need to change the path.

#22
ibcrootbeer

ibcrootbeer

    InsanelyMac Protégé

  • Members
  • Pip
  • 14 posts

You must not have movies in the same folder as amok's compiled version is pointing to. The code has the path editable before compilation, so you use that and compile it if you need to change the path.


im sorry i keep getting stuck...

i opened the code in xcode and saw the line to change to point to the directory where your movies are kept, so i changed it to "Users/myusername/Movies" and compiled it. placed the frapp into the plugins folder and the same thing happened... it just gave me the option to close ATV. the menu is there the icon is there and it compiled with no errors, all my movies are in the Movies folder on my HD...

am i still doing something wrong?

#23
grabberslasher

grabberslasher

    Ekky ekky ekky ekky p'tang zoom-boing <incoherent mumble&

  • Members
  • PipPipPip
  • 161 posts

im sorry i keep getting stuck...

i opened the code in xcode and saw the line to change to point to the directory where your movies are kept, so i changed it to "Users/myusername/Movies" and compiled it. placed the frapp into the plugins folder and the same thing happened... it just gave me the option to close ATV. the menu is there the icon is there and it compiled with no errors, all my movies are in the Movies folder on my HD...

am i still doing something wrong?


Do you have a forwardslash at the start of that path? "/Users/myusername/Movies/" ?

#24
ibcrootbeer

ibcrootbeer

    InsanelyMac Protégé

  • Members
  • Pip
  • 14 posts

Do you have a forwardslash at the start of that path? "/Users/myusername/Movies/" ?


yeah... it reads: .... = @"/Users/myusername/Movies";

should there not be one?

#25
Sherry Haibara

Sherry Haibara

    InsanelyMac Legend

  • Members
  • PipPipPipPipPipPipPip
  • 699 posts
It works like magic, but it's making some troubles with the Exit plugin, mostly because it turned out that they both use the same Info.plist file. How can we make working both of them?
Sherry Haibara

#26
amok

amok

    InsanelyMac Protégé

  • Members
  • Pip
  • 10 posts
I've deleted my build, seems to have a problem with linking to the Users-folder. Better use this one: http://wiki.awkwardt...g/wiki/ATVFiles

#27
ibcrootbeer

ibcrootbeer

    InsanelyMac Protégé

  • Members
  • Pip
  • 14 posts

I've deleted my build, seems to have a problem with linking to the Users-folder. Better use this one: http://wiki.awkwardt...g/wiki/ATVFiles


it looks like this one would work for me but my user account that i have been working in is named appletv... is there any way we can change the path it points to? ...say to an external drive or a different users Movies folder???

#28
Sherry Haibara

Sherry Haibara

    InsanelyMac Legend

  • Members
  • PipPipPipPipPipPipPip
  • 699 posts
Yes, there is.
Do the following:
cd /Users
ln -s frontrow /Users/yournamehere/Movies
if you want to use your account Movies library, or
cd /Users
ln -s frontrow /Volumes/volumename/folder
if you want to use a Movies folder that's stored on another volume.
Sherry Haibara

#29
ibcrootbeer

ibcrootbeer

    InsanelyMac Protégé

  • Members
  • Pip
  • 14 posts

it looks like this one would work for me but my user account that i have been working in is named appletv... is there any way we can change the path it points to? ...say to an external drive or a different users Movies folder???



Yes, there is.
Do the following:

cd /Users
ln -s frontrow /Users/yournamehere/Movies
if you want to use your account Movies library, or
cd /Users
ln -s frontrow /Volumes/volumename/folder
if you want to use a Movies folder that's stored on another volume.
Sherry Haibara


forgive me, im not very fluent when it comes to the terminal, but what you are saying is that if i type this into the terminal it will change the path that the ATVFiles.frapp is using to point to the specific folder? wouldnt you have to change the code inside that plugin?

#30
Sherry Haibara

Sherry Haibara

    InsanelyMac Legend

  • Members
  • PipPipPipPipPipPipPip
  • 699 posts
Nope. ATVFile.frapp plugin it's coded to point here: /Users/frontrow/Movies, and use it as its Movies folder.
Now, what do we need to do if we wanna let it use our Movies folder?
Because we just can't change the plugin code (aldready tried, but it doesn't seem to work well), we need a trick that create a symbolic link between our /Users/name/Movies folder and /Users/frontrow/Movies folder. Doing in terminal what I wrote in the previous post will deceive the plugin and do that trick, making our "AppleTV" seeing our Movies even if they aren't in /Users/frontrow/Movies :)
I hope it's more clear now,
Sherry Haibara

#31
ibcrootbeer

ibcrootbeer

    InsanelyMac Protégé

  • Members
  • Pip
  • 14 posts
that made it a lot more clear. however, i wasnt able to get it to work. still nothing in the files menu and when i checked the movies folder where i want it linked to i saw a file named front row in there... im assuming that was supposed to be the pointer file?

anyway, i decided to just create another new user named frontrow and put all my movies in that user Movies folder. worked like a charm. so until we get more bugs worked out and more error free ways of working around this ill probly just leave it like this.

thanks for the help!

#32
centic

centic

    InsanelyMac Protégé

  • Retired Developers
  • 55 posts
Hmm.. any idea how to set the image to the right?

#33
stukey

stukey

    InsanelyMac Protégé

  • Members
  • Pip
  • 8 posts
Hi all

I've installed the great ATVFiles plugin and can now see the contents of the /Users/frontrow/Movies folder from my AppleTV. What I'd like to do now is set-up an AFP mount in /Users/frontrow/Movies on the AppleTV to redirect to my iMac's Movies folder. Then I can just access all of my movie files without having to copy them to the AppleTV or sync via iTunes. I've managed to set-up an AFP mount but it mounts my entire iMac's HD.

I just want the mount to go directly to /Users/myusername/Movies on my iMac! Any ideas how I do this?

Also, how can I make the mount persistent between reboots of the AppleTV?

This is what I've done so so far...

1. SSH to AppleTV
2. Make the OSBoot Volume read-write: sudo mount -o remount,rw /dev/disk0s3 /
3. Mount the AFP share: mount_afp -i afp://iMac.Local/Mac\ HD /Users/frontrow/Movies

Many thanks! :)

Stukey

#34
danofun

danofun

    InsanelyMac Protégé

  • Members
  • Pip
  • 17 posts
ibcrootbeer <-love the stuff...

anyway, give this a shot. Once I had ATVfiles working, I was able to change the default location of my movie files by using this code to create a symbolic link.

mkdir /Volumes/volume_name/Users/frontrow/Movies
Creates the folder frontrow. You may get an error saying this folder already exist. If so, this is not a problem so continue.

rm -r /Volumes/volume_name/Users/frontrow/Movies
Removes the Movies folder, and all of it contents, that resides in the frontrow users folder.

ln -s /Volumes/volume_name/Users/your_username/Movies /Volumes/volume_name/Users/frontrow
This creates a symbolic link to your current movie folder.


Now we can mount a shared network folder in your Users Movies folder to access remote network shares. First, on your remote computer, make sure you share the folder containing the video files you wish to watch. Then...

mkdir /Volumes/volume_name/Users/your_username/Movies/new_folder
Use this command to create a new folder in your users Movie folder.

mount -t smbfs //ip_of_shared_computer/shared_folder /Volumes/volume_name/Users/your_username/Movies/new_folder
This will mount the network share to your users Movie folder and will now be accessable from atv.

As always, us at your own risk...





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

© 2017 InsanelyMac  |   News  |   Forum  |   Downloads  |   OSx86 Wiki  |   Designed by Ed Gain  |   Logo by irfan  |   Privacy Policy