스택 게시물과 블로그를 통해이 글을 읽었을 때 쉽게 읽을 수있을 것 같습니다. 따라서 다른 쌍 (또는 수천 쌍)의 눈이 필요합니다.Android 비디오 재생 '이 비디오를 재생할 수 없습니다.'
현재 레이아웃 :
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
android:id="@+id/LinearLayout01"
android:layout_height="fill_parent"
android:paddingLeft="2px"
android:paddingRight="2px"
xmlns:android="http://schemas.android.com/apk/res/android"
android:paddingTop="2px"
android:paddingBottom="2px"
android:layout_width="fill_parent"
android:orientation="vertical">
<VideoView
android:layout_height="fill_parent"
android:layout_width="fill_parent"
android:id="@+id/VideoView" />
</LinearLayout>
현재 코드 : (정말 조각에 있어야하지만)
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_vid_splash);
videoView = (VideoView)findViewById(R.id.VideoView);
videoView.setVideoPath("vid_splash.mp4");
videoView.start();
}
그냥 뭔가 작업을 시작하기
, 나는이 활동했다. 내 주요 활동은 위 onCreate 호출로 활동을 시작하려는 의도를.습니다.결과는 "이 비디오를 재생할 수 없습니다"라는 작업을 신속하게 개시합니다.
참고 비디오, 다른 스택 오버플로 게시물 인 "documentariesandyou.mp4"등으로 비디오를 테스트했습니다. 비디오를 다시 인코딩하여 h.264 '기준선'프로필인지 확인했습니다. 몇 가지 핸드 브레이크 안드로이드 프로필.
결과는 항상 동일합니다 : "이 비디오를 재생할 수 없습니다". 다음과 같이
는나는 로그 캣에서보고 있어요 유일한 오류는 다음 MediaPlayer를 오류 코드 (1)를 나타 내기 때문에
MediaPlayer Error (1, -2147483648)
당신입니다 비디오의 확인 경로가 올바른지? 이 오류는 경로가 올바르지 않을 때도 발생할 수 있습니다. –