Movie streaming from iTunes to iPhone?

Discussion in 'iOS Apps' started by spriter, Sep 21, 2008.

  1. spriter macrumors 65816

    spriter

    Joined:
    May 13, 2004
    #1
    As topic... is there an app that can do this over wifi? :confused:
     
  2. plinden macrumors 68040

    plinden

    Joined:
    Apr 8, 2004
    #2
    Not via iTunes, but you can do this via Apache. I've done this, and you can access anything in iTunes via the links displayed. Except, anything that's DRM'ed can't be played. Start web sharing from Preferences/Sharing and put a soft link (an alias won't work) to your Movies folder in your Sites folder. Then go to your Mac in Safari.

    To create a soft link, open Terminal and do the following:
    Code:
    cd ~/Sites
    mv index.html index.html.bak
    ln -s ~/Music/iTunes/iTunes\ Music/Movies .
    To access this, type "http://<your mac's name>/~<your account name>" in Safari. You'll get a list of the files in ~/Sites. Select Movies and you see a list of your movies. Edit: example - I would type "http://plindens-computer.local/~plinden"

    This is a bit basic if you're used to rich UIs, so you could write a web page to display links to whatever you want to access in your iTunes library.

    Hmm. This might be a little project of mine - an AJAX web page to parse iTunes Library.xml and display a nice UI - but album art would be a problem. I'll need to think about this.
     
  3. spriter thread starter macrumors 65816

    spriter

    Joined:
    May 13, 2004
    #3
    Great :D I'll give this a try. Thanks plinden.
     
  4. plinden macrumors 68040

    plinden

    Joined:
    Apr 8, 2004
    #4
    I forgot something. By default Apache won't show the soft link. You need to modify /etc/apache2/users/<your account>.conf to be like this, telling it to follow sym links:
    Code:
    <Directory "/Users/<your account>/Sites/">
        Options Indexes MultiViews FollowSymLinks
        AllowOverride None
        Order allow,deny
        Allow from all
    </Directory>
    
    And disable/re-enable web sharing.
     
  5. rockstarjoe macrumors 6502a

    rockstarjoe

    Joined:
    Jun 2, 2006
    Location:
    washington dc
    #5
    :D I sure wish someone would make an app that did this... I would pay for it, for sure (hint hint developers!). Wifi only would be fine with me, too... I'm sure frame rates would suck over 3g/cellular.
     
  6. BergerFan macrumors 68020

    BergerFan

    Joined:
    Mar 6, 2008
    Location:
    Mos Eisley
    #6
    I see no reason why the Remote app couldn't do this, when you consider it's secured on your own network. :confused:
     
  7. Apple Ink macrumors 68000

    Apple Ink

    Joined:
    Mar 7, 2008
    #7
    As far as a remote app is concerned viz: WiFi.... 802.11g is hardly capable of pushing out big videos forget HD!
     
  8. rockstarjoe macrumors 6502a

    rockstarjoe

    Joined:
    Jun 2, 2006
    Location:
    washington dc
    #8
    Really? I thought it would work ok... doesn't AppleTV stream stuff fine over 802.11g?
     
  9. plinden macrumors 68040

    plinden

    Joined:
    Apr 8, 2004
    #9
    The Apache method I outlined above works fine for video. But the video must be iPod compatible, just as video you sync to the device must be. So HD video won't work anyway, even if the connection pipe were big enough.

    Also, a native iPhone/iPod Touch app won't fly ... I'm 100% convinced Apple would reject it, so it would have to a client/server app with the server running on the Mac, with access via MobileSafari.

    As for my project ... I suspected that MobileSafari wouldn't be able to handle a reasonably sized iTunes Music Library.xml file (mine is 14MB) which I confirmed with a quick test yesterday evening. I had to reset my iPhone after waiting 10 minutes for MobileSafari to parse the XML.

    I have a few ideas I'm going to play about with when I have the time. If I ever get my ideas to work, I'll post the source code on MacRumors for free.
     
  10. rockstarjoe macrumors 6502a

    rockstarjoe

    Joined:
    Jun 2, 2006
    Location:
    washington dc
    #10
    You're awesome, thanks for looking into this. I'll try your above method once I wrap my head around it... I've never done anything like that before though so I was a bit intimidated.
     
  11. spriter thread starter macrumors 65816

    spriter

    Joined:
    May 13, 2004
    #11
    plinden, I managed to get it working fine thanks to your help. It's cool :D

    Some notes for others if you try too...

    A fix to a known error in Leopard giving a 403 error when accessing your sites folder:
    http://docs.info.apple.com/article.html?artnum=306884

    Easy way to create softlink (symbolic link)
    http://seiryu.home.comcast.net/~seiryu/symboliclinker.html
    Download, install, right-click on your item and go to More > Make Symbolic link (then put this into your Sites folder).

    Finally, if your sites folder has index.html in it, rename it to something else or your iPhone will see that page instead of a list of what's inside your Sites folder. ;)

    Just follow plinden's instructions and you can stream iPod compatible movies just like me :) I have my iTunes library (and movies) on an external drive and it works perfectly.
     
  12. immigrantsong macrumors newbie

    Joined:
    Sep 23, 2008
    Location:
    Macon, GA
    #12
    plinden,

    Thanks for all the info about doing this, but...are there any other additional settings needed to make this work? No matter what, the symbolic link file ("Movies") never appears on the page for the site url (when I browse to it).

    I suspect it is some kind of additional permissions issue because...

    1. It does not appear in the list of files for that folder in the browser
    2. If I try to go directly to it, via adding the "Movies" filename to the url, I get an error page that says I "don't have permission to view that folder".


    I can put other files there in the folder, even an mp4 file, and they all show up on the page when I browse to it, but it will not display any symbolic link file whatsoever. (I have done this multiple times....both using the "ln -s" command as well as the utility mentioned by spriter....same result either way.)

    BTW, my iTunes Movies folder in the default location, same as in your original example for creating the symlink to it ("~/Music/iTunes/iTunes\ Music/Movies").

    Also, I'm on 10.5.5 Leopard.

    Thanks
    Bill
     
  13. rockstarjoe macrumors 6502a

    rockstarjoe

    Joined:
    Jun 2, 2006
    Location:
    washington dc
    #13
    EDIT: Nevermind! Just had a rights issue. This is a great little trick! Thanks :)
     
  14. rasputin666 macrumors member

    rasputin666

    Joined:
    Mar 1, 2009
    #14
    can you tell me how you fixed your rights issue? i'm having the same issue. i copied/paste the individual files and the list shows up but the folder doesn't show up. not the worst thing, i put copies of all my iphone friendly movies in my site folder and browse to it in safari on my phone and pick from the list.

    Thx
     
  15. rockstarjoe macrumors 6502a

    rockstarjoe

    Joined:
    Jun 2, 2006
    Location:
    washington dc
    #15
    Boy it has been a long time so it is tough to remember what my issue was and how I solved it. I think it was just a matter of changing the rights on one of the files / folders involved so that everyone had read access... maybe on the symlink itself? When I'm back home I'll take a look and see if I can recreate my problem.
     
  16. sammich macrumors 601

    sammich

    Joined:
    Sep 26, 2006
    Location:
    Sarcasmville.
    #16
    I'm getting a 'Forbidden Error' even though I've changed 'Everyone's access to Read Only and applied to all files below.
     
  17. plinden macrumors 68040

    plinden

    Joined:
    Apr 8, 2004
    #17
  18. darwiniandude macrumors member

    Joined:
    Mar 20, 2008
    #18
    Just spent a good hour and a half trying to nut this one out. My problem was that the Symbolic Link wasn't showing up on the web page. It seems the parent folders of your iTunes folder need permission.

    Do this in terminal
    Code:
    chmod a+wx ~/Music
    Then restart web sharing.

    Works for me! :)
     
  19. dukebound85 macrumors P6

    dukebound85

    Joined:
    Jul 17, 2005
    Location:
    5045 feet above sea level
  20. m3coolpix macrumors 6502a

    m3coolpix

    Joined:
    Dec 24, 2007
    #20
    Air Video will also do this without the movies being formatted for iTunes or the iPhone....

    It is a $2.99 app though, and requires the free server app to be on your Mac.

    I've not found a movie it won't play, as long as it's on a hard drive connected to my Mac, it shows up on my iPhone.

    It even has a setup for video streaming over the cell network. I've tried in on 3G with not many hiccups.

    No affiliation, just a happy user. :)
     
  21. dukebound85 macrumors P6

    dukebound85

    Joined:
    Jul 17, 2005
    Location:
    5045 feet above sea level
    #21
    also works over 3g, which i am surprised apple and att allowed

    it is a sweet app. live trans-coding is nice if its not iphone formatted

    is there a way to do the same (being stream to) with a laptop instead of an iphone?
     
  22. m3coolpix macrumors 6502a

    m3coolpix

    Joined:
    Dec 24, 2007
    #22
    My setup is a MacBook Pro (with multiple hard drives attached) streaming to iPhone.

    So you are talking about going from a Mac laptop to another Mac laptop?

    If that's it....just network sharing would work (whether cabled or via wifi).

    Maybe I'm misunderstanding something in your explanation of how you want the video stream to work.
     
  23. dukebound85 macrumors P6

    dukebound85

    Joined:
    Jul 17, 2005
    Location:
    5045 feet above sea level
    #23
    essentially i want streaming from my desktop to my laptop when i am on seperate networks

    in other words, airvideo streams from computer to iphone with seperate networks

    i want to stream from computer to computer when on seperate networks
     
  24. afd macrumors 6502a

    Joined:
    Apr 12, 2005
    Location:
    Scotland
    #24
    I can't get this to work at all, I keep getting 403 Forbidden messages, the symlink I made works fine in finder but not in safari. The permissions for the drive where video is saved is set for everyone able to read.

    Any ideas?
     
  25. afd macrumors 6502a

    Joined:
    Apr 12, 2005
    Location:
    Scotland
    #25
    Got it working. I had symlink in the sites folder inside my user account. I put one into the private/etc/apache2/documents folder and it worked. Was surprised to see it worked with iTunes content too. Does safari on iPhone check to see phone is linked to my iTunes account, or will any iTunes content work?
     

Share This Page