wa2c / cifs-documents-provider

CIFS Documents Provider
MIT License
295 stars 26 forks source link

Probleming seeking on large files on cifs documents provider #20

Open tvdev7805 opened 2 years ago

tvdev7805 commented 2 years ago

Hello, I am developing a video player for android, I want to support SAF and CIFS documents provider. Now I am trying to implement code to play large video files on network drives (Windows 10). But I have problems seeking on these files, the seekto was not successful and an on video completion event on mediaplayer is then fired.

I have already tried the same codes on Nvidia Shield's SMB network drive SAF implementation and got a success. any idea?

tvdev7805 commented 2 years ago

I have finished testing our photo and viewer app that makes use of SAF provider, but since I have not been able to make seeking to work using cifs SAF provider app, I have to disable anything that uses file seeking in my app when working with cifs provider. (That affects getting thumbnails from certain kinds of video files and seeking on video files)

Cifs provider that comes with Android OS is rare but there's one in Nvidia shield TV, if anyone wants to test it, try to get one. It works great and if anyone wants to see a demo, watch this video https://youtu.be/53FmuGFu1sU

I hope the authors of cifs provider can make it better, and I will do my best to promote it.

Always appreciated

YanceyChiew commented 2 years ago

Earlier I caught the same problem, please compile version 1.201.32(update: just now I tested the f-droid built version) and test, this version should not have introduced the seeking issue.

Afterwards, which commit introduced this issue needs to be further investigated. I guess it is caused by some measures to improve the download speed of jcifs.

tvdev7805 commented 2 years ago

Yes, v1.2 worked, I downloaded the apk from release archive. Hope to see it fixed soon. And if I can make a request, I hope it can be published to Google Play store for Android TV too. There is no such app for TV now and it will have a great potential in the future.

tvdev7805 commented 2 years ago

I've made a video tutorial of making use of cifs document provider and a client program to access media files on network share, if anyone is interested please take a look https://youtu.be/5UTSfKH6j34

(I'm not promoting my app but promoting cifs document provider app which I believe is a valuable app)

RebelliousX commented 2 years ago

Try version 1.3.2, I have issues with v1.4.0 reading large files. Specifically, when I open disc images of GameCube console in Dolphin Emulator! In v1.3.2 it works fine. In v1.4.0, it gives the emulator gives read disc errors after the initial loading.

It might be because of the new read buffer code which was presented after v1.3.2. I will open another issue about this.