Can a videoview play a video stored on internal storage?

前端 未结 6 1491
一向
一向 2020-11-29 04:12

I\'m trying to provide my users with the ability to use either external or internal storage. I\'m displaying both images and videos (of a scientific nature). When storing th

6条回答
  •  Happy的楠姐
    2020-11-29 04:30

    You can use:

    videoView.setVideoURI(Uri.parse(file.getAbsolutePath()));
    

    if the file is world readable

    Or you can use a content provider

提交回复
热议问题