Я хочу воспроизвести видео с URL-адреса с помощью Vuforia Android Native API.Воспроизвести видео из URL с помощью Vuforia для Android родной?
Я изменил код в образце VideoPlayback, как показано ниже:
VideoPlayback.java
Video from Url
mMovieName[STONES] = "..Youtube Video link..";
mMovieName[CHIPS] = "..Youtube Video link..";
mMovieName[celebVM_LOGO] = "..Youtube Video link..";
я удалил часть кода из VideoPlayerHelper.java, как показано ниже:
for Video from Url, in Load method
AssetFileDescriptor afd = mParentActivity.getAssets().openFd(filename);
mMediaPlayer.setDataSource(afd.getFileDescriptor(),
afd.getStartOffset(), afd.getLength());
afd.close();
mMediaPlayer.setDataSource(filename);
И удаление кода
try {
AssetFileDescriptor afd = mParentActivity.getAssets().openFd(filename);
afd.close();
} catch (Exception e) {
Log.d(LOGTAG, "File does not exist");
mCurrentState = MEDIA_STATE.ERROR;
mMediaPlayerLock.unlock();
mSurfaceTextureLock.unlock();
return false;
}
Это не работает, может кто-нибудь предложить, почему? Пожалуйста, обратитесь к этой ссылке для получения дополнительной информации: https://developer.vuforia.com/forum/android/how-work-video-url-videoplayback
Добавить описание и пояснить. http://meta.stackexchange.com/questions/22186/how-do-i-format-my-code-blocks –