Problem playing media clip with no caching

Help
lordorient
2006-03-07
2013-05-13
  • lordorient
    lordorient
    2006-03-07

    Can anybody help with the following problem:
    I got the page:
    <html>
    <body>
    <embed src="media/cyril.mpeg" type="application/x-mplayer2"
      width="800" height="600"
      ShowControls="false" autostart="true"/>
    <body>
    </html>
    When I play it with nomediacache = 0 everything goes ok: getting playlist, buffering ..., playing ...(I see my favourite clip :) ), stopped
    When I set nomediacache = 1, it fails: getting playlist, playing ... and immediatly - stopped, so no clip is shown.
    Just for the sake of testing I entered the direct link to the clip http://localhost/media/cyril.mpeg - everything went OK!!!
    Whats the problem?

     
    • Kevin DeKorte
      Kevin DeKorte
      2006-03-07

      change "src" to "filename" and see if that works... nomediacache with the src tag is really NOT designed for playing off a web server. It is more designed for streaming off an NFS server.

       
      • lordorient
        lordorient
        2006-03-07

        This does not help :(
        The strange thing is that a direct url to clip works fine with nomediacache = 1.

        PS: for my task webserver is on the same computer or lan.

         
        • Kevin DeKorte
          Kevin DeKorte
          2006-03-08

          Try this...

          <html>
          <body>
          <embed nocache=true width=640 height=480 filename="file:///home/kdekorte/Movies/test.mov">
          </embed>
          </body>
          </html>

          You also might want to grab the CVS version of mplayerplug-in as there is a fix for nomediacache in there that went in a couple of weeks ago. But it is only needed if your device does not tell you the file length (like a video capture card), normal files should be fine.

           
          • lordorient
            lordorient
            2006-03-08

            Thanks. I found the solution.
            Changing from
            <embed src="media/cyril.mpeg" .... />
            to
            <embed src="http://localhost/mysite/media/cyril.mpeg" .... />
            solves the problem.
            Seems like relative URL causes playback problems with nomediacache = 1

             
    • lordorient
      lordorient
      2006-03-08

      But I cannot call this solution a good one :(

       
      • Kevin DeKorte
        Kevin DeKorte
        2006-03-08

        Actually that is correct. Since the url you pass in is passed to mplayer and mplayer does not know of relative URLs. No other fixes will be done.