Open bburdette opened 1 month ago
On linux, remote https, remote http, and localhost http all work for video and audio:
On android, only remote https works for either video or audio ("remote https" is off the page in this view"):
Hi, You need to add some capabilities to your application. For example like this: https://gitlab.com/loikki/menugenerator/-/blob/master/capabilities/main.json?ref_type=heads
I tried adding that item to capabilities/main.json, but I got this error:
I am using the plugin tauri-plugin-http
. I think it is from there https://github.com/tauri-apps/tauri-plugin-http
I saw that plugin and thought it just gave you some extra JS apis, but wouldn't expect it to affect the webview http. Why would it work on desktop without a plugin but require it for android? But hey at this point I'll try anything lol.
I try to use convertFileSrc method to play local video, but it not work, is there anyway to play local video resource on android platform?
I still haven't gotten a chance to try the tauri-plugin-http. Will report back here with the result.
Discussed in https://github.com/tauri-apps/tauri/discussions/10428
I'm looking to get audio/video working on my page in an android app.
According to https://github.com/tauri-apps/tauri/issues/3725 it appears I need to use a web server to host the files, because of a bug in webkit. I added a web server to my app, and it does work - on linux.
On android the files don't load. I enabled logging on my web server and it seems its never getting the requests. I can adb shell and use curl to access the files just fine, and then I see those accesses in my logs.
From my android app, I can embed links to media files over https. But it doesn't work with an http url.
So my question is, is there some kind of policy on android that blocks an url like this?
http://localhost:8000/file/75d69666-b189-475e-9d8d-827d45ed3838
If so, how can I deactivate that policy?
reproduction:
See the readme
Then make a markdown document that points to an http media file, like
Observe that the https one works while the http one does not.
expected behavior:
Expected that access to urls should be the same on linux and on android, with the same tauri.conf.json
Full
tauri info
output