[英]Android Emulator says can't play this video
每當我編寫此代碼時,就會發生此錯誤:無法播放此文件。
Uri uri=Uri.parse("android.resource://"+getPackageName()+"/"+R.raw.my);
VideoView videoView =(VideoView)findViewById(R.id.idVideoView);
videoView.setVideoURI(uri);
videoView.start();
Raw文件夾支持視頻文件。 但請注意它是哪種格式。 檢查一下。
https://developer.android.com/guide/appendix/media-formats.html#core
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.