I've the following problem, when I open the media, and bind it to the player, I can't retrieve the media width and height values, so I can't get the same output as input. Is there any way to get this?
PD: I've tryed libvlc_video_get_size, but it's not working.
Thanks!
J.Ortola
Code: Select all
libvlc_instance_t* m_pVLCInstance;
libvlc_media_player_t* m_pMediaPlayer;
libvlc_media_t* m_pMedia;
int w, h;
...
m_pMedia = libvlc_media_new_path(m_pVLCInstance, pszMediaPathName);
libvlc_media_player_set_media (m_pMediaPlayer, m_pMedia);
libvlc_video_set_callbacks(m_pMediaPlayer, Lock, Unlock, Display, this);
//libvlc_video_get_size(pMediaPlayer, 0, &w, &h); <-- Doesn't retrieve any value
libvlc_video_set_format(m_pMediaPlayer, "RGBA", 640, 480, 640*4);