I have an app with videos to play. I want to add a feature to download a file.
I download a mp4 file into the data folder. I am able to run an AVPlayer and view the video in the app. After some time video won’t play. If I enable UIFileSharingEnabled and check if file exists, I can see it’s there but then it won’t play even from accessing it through Files. If I copy the file from iOS to Mac then I can play the video on Mac, but not anymore on iOS.
If I delete the app, install again and download the video while UIFileSharingEnabled and if it’s played in the app it can be played in the Files app, but again after some time it’s not playable again… I can see only first frame. I can even see the length of video. It happens to multiple videos.
Any clues?
downloading app, copying it, copying other files to data folder and trying to play it
play using webkit, play using avkit. movie file is ok but not playable




