Search code examples
c#winformsvideomedia-playerlibvlc

set playback speed in vlc dot net (winforms)


i am using vlc player in winforms. its working fine, but the problem is that its playing faster.
i have videos recorded at 10fps. i think vlcControl is playing at 30fps, that's why video are playing faster. Referred this, but it didn't help. i couldn't find any function like set_play_back_speed function under vlcControl1.Video
I thought vlcControl would automatically figure out fps & play accordingly.
if i open the same video from vlc media player installed on my windows pc, it plays at proper rate. any clue how to fix this?

P.S: if i open any video recorded at 29.97fps, vlcControl in winforms is playing it at proper speed.


Solution

  • Well, there's no function to set FPS to video thru Vlc.DotNet and I am not sure are you using WinForms or WPF application, but best I can help is probably, if you would play with rate settings as in transpone video.

    It's found at vlcControl1.rate (which is float value default is 1.00), if you have 30fps and only want 10fps well, you could try to set:

    vlcControl1.rate = (int)(33 / 100);
    

    Which then would decrease video and audio transpone to 10fps from 30fps (assuming 1.00 = 30fps).