Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Windows Media Player

Windows Media Player

Scheduled Pinned Locked Moved C#
questionvisual-studio
6 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    antoine orchus tech
    wrote on last edited by
    #1

    Hi I am using VS 2003 with the latest windoze media player. I want to hide a video in a dll. Then I want the media player to access it. How do I do that? Thanks! Antoine This by our hands that dream, "I shall find a way or make one!"

    H S 2 Replies Last reply
    0
    • A antoine orchus tech

      Hi I am using VS 2003 with the latest windoze media player. I want to hide a video in a dll. Then I want the media player to access it. How do I do that? Thanks! Antoine This by our hands that dream, "I shall find a way or make one!"

      H Offline
      H Offline
      Heath Stewart
      wrote on last edited by
      #2

      You can't, not without implementing your own native pluggable protocol handler for windows (like that which handles http(s), ms-help, its, res, etc.). Windows Media Player uses monikers to bind to streams and there is not - at this time - a plugglable protocol handler for streaming embedded resources. Also, embedded a video in an assembly is extremely wasteful. You'll increase the load times of the assembly incredibly. Just distribute it as a separate file and point the URL property of WMP to the file when you need to play it.

      Microsoft MVP, Visual C# My Articles

      A 1 Reply Last reply
      0
      • H Heath Stewart

        You can't, not without implementing your own native pluggable protocol handler for windows (like that which handles http(s), ms-help, its, res, etc.). Windows Media Player uses monikers to bind to streams and there is not - at this time - a plugglable protocol handler for streaming embedded resources. Also, embedded a video in an assembly is extremely wasteful. You'll increase the load times of the assembly incredibly. Just distribute it as a separate file and point the URL property of WMP to the file when you need to play it.

        Microsoft MVP, Visual C# My Articles

        A Offline
        A Offline
        antoine orchus tech
        wrote on last edited by
        #3

        Yeah, OK. thanks for the answer. didn't thought about the loss of loading time. Do you know of a way to keep the videos secure? Digital Rights Managment seems a way to go -is it??? ;) Cheers Antoine This by our hands that dream, "I shall find a way or make one!"

        H 1 Reply Last reply
        0
        • A antoine orchus tech

          Yeah, OK. thanks for the answer. didn't thought about the loss of loading time. Do you know of a way to keep the videos secure? Digital Rights Managment seems a way to go -is it??? ;) Cheers Antoine This by our hands that dream, "I shall find a way or make one!"

          H Offline
          H Offline
          Heath Stewart
          wrote on last edited by
          #4

          Yes, DRM would be something to look into. Beside, if you think storing the file as an embedded resource (or even in the .rsrc section of the PE/COFF executable itself) would keep it secure, you'd be sorely surprised. ildasm.exe, for example, can easily extract anything in an assembly. One could throw together a simple .NET app to do this as well. Resources in native DLLs can easily be extracted, too (though writing the code for it is a big harder, but plenty of apps - including Visual Studio - can make quick and easy work of that by just loading the .rsrc section and providing extraction capabilities). If you did want to embed it stil, you'd have to extract it anyway in order for WMP to play it. At that point someone could also mess with it. DRM is really about your only protection, if it is really that necessary.

          Microsoft MVP, Visual C# My Articles

          A 1 Reply Last reply
          0
          • H Heath Stewart

            Yes, DRM would be something to look into. Beside, if you think storing the file as an embedded resource (or even in the .rsrc section of the PE/COFF executable itself) would keep it secure, you'd be sorely surprised. ildasm.exe, for example, can easily extract anything in an assembly. One could throw together a simple .NET app to do this as well. Resources in native DLLs can easily be extracted, too (though writing the code for it is a big harder, but plenty of apps - including Visual Studio - can make quick and easy work of that by just loading the .rsrc section and providing extraction capabilities). If you did want to embed it stil, you'd have to extract it anyway in order for WMP to play it. At that point someone could also mess with it. DRM is really about your only protection, if it is really that necessary.

            Microsoft MVP, Visual C# My Articles

            A Offline
            A Offline
            antoine orchus tech
            wrote on last edited by
            #5

            Thanks for the input! Ok So the request forms are all sent out. I just I wont need to shell out money by the windows. :) Cheers Antoine This by our hands that dream, "I shall find a way or make one!"

            1 Reply Last reply
            0
            • A antoine orchus tech

              Hi I am using VS 2003 with the latest windoze media player. I want to hide a video in a dll. Then I want the media player to access it. How do I do that? Thanks! Antoine This by our hands that dream, "I shall find a way or make one!"

              S Offline
              S Offline
              Stephane Rodriguez
              wrote on last edited by
              #6

              Lookup MSDN and Google with "res://"

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups