DiamondLovesYou / vlc-nacl

Port of VLC to PNaCl/NaCl. Mirror of
https://code.videolan.org/videolan/vlc-nacl
4 stars 3 forks source link

Can't get anything to play... #1

Open Bite-A-Rock opened 7 years ago

Bite-A-Rock commented 7 years ago

After much consternation, I managed to get a build to finish.

I now have the ppapi-control.js, vlc-release.nmf, vlc.pexe, and a index.html file in my web root.

the contents of the vlc-release.nmf is { "program": { "portable": { "pnacl-translate": { "url": "vlc.pexe" } } } }

The index.html file references the ppapi-control.js, has a div with an id of 'video', and contains the restart functionality.

Everything looks fine until I try to play something. I enqueue a file on my local server and I get:

[module ppapi_access] [header unknown] [object access]: the server doesn't support range requests [module core] [header unknown] [object input source]: cannot access http://localhost:8080/VLCWeb/C0004.mp4 [module core] [header unknown] [object input]: Your input can't be opened [module core] [header unknown] [object input]: VLC is unable to open the MRL 'http://localhost:8080/VLCWeb/C0004.mp4'. Check the log for details.

I thought maybe I needed to use a video tag instead of a div, but when I do that the VlcInstance never gets initialized.

I have tried to go against other servers out there and I get similar results.

Any ideas?

DiamondLovesYou commented 7 years ago

Sorry for the delay. I noticed this issue right before Thanksgiving but due to travel, I've been off the grid till now.

Yeah, this is an issue with ppapi-access.cpp. When I was working on this, I tested it against flv files, which apparently are very tolerant of my incompetence (I mean the container handles corruption well). During this past summer, I started work on a testing layer by implementing a few of the ppapi apis to help find these issues, but I haven't finished it due to time constraints. See the tests subfolder if you'd like to take a look. The ppapi api is mostly complete (URL_Loader is unfinished though, which is one of the more important apis to ppapi-access.cpp), and the VLC apis don't have any Rust safe wrappers.

If you'd like to work on this, send me PRs and I'll make sure they land in the VideoLAN repo (which for some reason is private currently).

Bite-A-Rock commented 7 years ago

Thanks for your response. I will try streaming using the flv container and see how that goes.

I am completely new to ppapi, so much of what you wrote went over my head.

I have a need to replace the VLC plugin in chrome, since chrome no longer supports it. In detail, I have a need to play a UDP/Multicast stream in a web page. I have googled my fingers away looking for a suitable replacement, but everything I have found will not do multicast. Unfortunately, multicast solves a critical problem for my organization so I really need to go that direction.

This plugin looked like it would solve my problem, so that is what brought me here.

It seems, the folks over at VLC were working on a new plugin, but it has been de-prioritized to the point of little information to be found.

It would be great to get this plugin working. I am off to try flv. :-)

Thanks!

DiamondLovesYou commented 7 years ago

I have a need to replace the VLC plugin in chrome, since chrome no longer supports it. In detail, I have a need to play a UDP/Multicast stream in a web page. I have googled my fingers away looking for a suitable replacement, but everything I have found will not do multicast. Unfortunately, multicast solves a critical problem for my organization so I really need to go that direction.

Well, that's a problem in itself. I'm pretty sure no multicasting is possible on top of HTTP (let alone UDP). The pepper API as available from PNaCl only offers CORS filtered http(s) access. NaCl/Chrome store won't have that issue, if given the proper permissions, and if you go that route, you won't need to use my buggy access module (ie the usual VLC modules to read from UDP sockets will work as is). But that will require a store app and all the machinery that would go along with it.

Also, some modification would need to be made to ppapi-access to disable its caching, which is silly for streams. I can advise, if desired.

It seems, the folks over at VLC were working on a new plugin, but it has been de-prioritized to the point of little information to be found.

Yeah, sorry about that. The folks from VLC you refer to is really only me (I'm not affiliated with VLC though)! It's hard to find the time to work on this, due to financial reasons, hence the ghost town feel of the project.