我已经使用以下代码使用 rtsp 在 android 手机上成功流式传输 ip camera:
public class MainActivity extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
VideoView video= (VideoView) findViewById(R.id.videoview);
String viewSource = "rtsp://192.168.1.........";
video.setVideoURI(Uri.parse(viewSource));
video.setMediaController(new MediaController(this));
video.requestFocus();
video.start();
}
}
我的问题是,是否可以使用使用 ip camera 的 boofcv 在 android 上操作 videoview?因为在 boofcv 样本上,它使用的是安卓手机上的内置摄像头。如果有人在这里好心可以帮助我。