I am using AxWindowsMediaPlayer
component in my WinForm
application. I noticed that when I set URL to file I want to play and call Ctlcontrols.play()
command there is an eg. 250ms delay before movie starts to play.
During this delay area of AxWindowsMediaPlayer
is black. This behavior can be very easily seen when you are changing from one movie to another, or just when you stop currently playing movie and start it again.
My current solution is based on postponed AxWindowsMediaPlayer
visibility set to true when starting to play movie. Player is displayed to user after eg. 500ms when I am sure, movie is actually playing and user will not see black nothing.
I am looking for better way how to avoid black nothing player. Does anyone solved similar issue? Or at least because I am dealing with very empiric values which will be different on different PCs, is there way how create foolproof solution?
Prereq: WinForms, .NET 4.0, WMP 12 for Windows 7
this code change currentPosition to 0 second when video running 0.01 milliseconds so that transition effect of black screen can be avoided. But for short videos additional codes needed.