我们在家里,所以玩家nexus Intel CPU,以及盾牌nvidia tv。 nexus播放器屏幕中的Vitamio保持黑色,在nvidia go中,但不是全部,但nexus 6 oneplus一个完美。 在zenfone asus中,intel cpu屏幕再次保持黑色。 Vitamio与英特尔不兼容?还是NVIDIA?
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import io.vov.vitamio.LibsChecker;
import io.vov.vitamio.MediaPlayer;
import io.vov.vitamio.widget.MediaController;
import io.vov.vitamio.widget.VideoView;
import android.widget.ProgressBar;
public class Utv extends AppCompatActivity {
private static final String TAG = "MainActivity";
private String path;
//private HashMap<String, String> options;
private VideoView mVideoView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
if (!LibsChecker.checkVitamioLibs(this))
return;
setContentView(R.layout.activity_utv);
mVideoView = (VideoView) findViewById(R.id.vitamio_videoView);
path = "http://80.86.107.169:8100/stream.flv";
/*options = new HashMap<>();
options.put("rtmp_playpath", "");
options.put("rtmp_swfurl", "");
options.put("rtmp_live", "1");
options.put("rtmp_pageurl", "");*/
mVideoView.setVideoPath(path);
//mVideoView.setVideoURI(Uri.parse(path), options);
mVideoView.setMediaController(new MediaController(this));
mVideoView.requestFocus();
mVideoView.start();
mVideoView.setOnPreparedListener(new MediaPlayer.OnPreparedListener() {
@Override
public void onPrepared(MediaPlayer mediaPlayer) {
mediaPlayer.setPlaybackSpeed(1.0f);
}
});
}
}