網頁

2016年5月2日 星期一

顯示 rtsp, 含 vlc-log.txt

CStringA logFile = "--logfile=vlc-log-" + GetTimeString() + ".txt";
const char *const vlc_args[] = {
"-I=dummy",
"--network-caching=5000",
"--sub-source=marq{marquee=%Y/%m/%d %H:%M:%S.%l,x=10,y=50}",
"--verbose=2",
"--file-logging", logFile,
};
vlcInstance = libvlc_new(vlc_argc, vlc_args);
const char *psz_mrl = "rtsp://169.254.1.168:554/live2.sdp";
media = libvlc_media_new_location(vlcInstance, psz_mrl);
mp = libvlc_media_player_new_from_media(media);
libvlc_media_player_set_hwnd(mp, GetDlgItem(IDC_VIEWER)->m_hWnd);

libvlc_media_release(media);
libvlc_media_player_play(mp);

vlc-log.txt

沒有留言:

張貼留言