- When wxMediaCtrl stops, either by the @c EVT_MEDIA_STOP not being vetoed, or by manually
- calling Stop(), where it actually stops is not at the beginning, rather, but at the beginning
- of the stream. That is, when it stops and play is called, playback is gauranteed to start at
- the beginning of the media. This is because some streams are not seekable, and when stop is
- called on them they return to the beginning, thus wxMediaCtrl tries to keep consistant for all types
- of media.
-
- Note that when changing the state of the media through Play() and other methods, the media may not
- actually be in the @c wxMEDIASTATE_PLAYING, for example. If you are relying on the media being in
- certain state catch the event relevant to the state. See wxMediaEvent for the kinds of events that
- you can catch.
-
- @section class_mediactrl_video_size Video size
-
- By default, wxMediaCtrl will scale the size of the video to the requested amount passed to either
- its constructor or Create(). After calling Load or performing an equivilant operation, you can
- subsequently obtain the "real" size of the video (if there is any) by calling GetBestSize().
- Note that the actual result on the display will be slightly different when ShowPlayerControls is
- activated and the actual video size will be less then specified due to the extra controls provided
- by the native toolkit. In addition, the backend may modify GetBestSize() to include the size of
- the extra controls - so if you want the real size of the video just disable ShowPlayerControls().
-
- The idea with setting GetBestSize() to the size of the video is that GetBestSize() is a wxWindow-derived
- function that is called when sizers on a window recalculate. What this means is that if you use sizers
- by default the video will show in its original size without any extra assistance needed from the user.
-
- @section class_mediactrl_player_controls Player controls
-
- Normally, when you use wxMediaCtrl it is just a window for the video to play in. However, some toolkits
- have their own media player interface. For example, QuickTime generally has a bar below the video with
- a slider. A special feature available to wxMediaCtrl, you can use the toolkits interface instead of making
- your own by using the ShowPlayerControls() function. There are several options for the flags parameter,
- with the two general flags being @c wxMEDIACTRLPLAYERCONTROLS_NONE which turns off the native interface,
- and @c wxMEDIACTRLPLAYERCONTROLS_DEFAULT which lets wxMediaCtrl decide what native controls on the interface.
- Be sure to review the caveats outlined in Video size before doing so.
-
- @section class_mediactrl_choosing_backend Choosing a backend
-
- Generally, you should almost certainly leave this part up to wxMediaCtrl - but if you need a certain backend
- for a particular reason, such as QuickTime for playing .mov files, all you need to do to choose a specific
- backend is to pass the name of the backend class to Create().
+ When wxMediaCtrl stops, either by the @c EVT_MEDIA_STOP not being vetoed, or
+ by manually calling Stop(), where it actually stops is not at the beginning,
+ rather, but at the beginning of the stream. That is, when it stops and play
+ is called, playback is gauranteed to start at the beginning of the media.
+ This is because some streams are not seekable, and when stop is called on
+ them they return to the beginning, thus wxMediaCtrl tries to keep consistant
+ for all types of media.
+
+ Note that when changing the state of the media through Play() and other methods,
+ the media may not actually be in the @c wxMEDIASTATE_PLAYING, for example.
+ If you are relying on the media being in certain state catch the event relevant
+ to the state. See wxMediaEvent for the kinds of events that you can catch.
+
+
+ @section mediactrl_video_size Video size
+
+ By default, wxMediaCtrl will scale the size of the video to the requested
+ amount passed to either its constructor or Create().
+ After calling wxMediaCtrl::Load or performing an equivilant operation,
+ you can subsequently obtain the "real" size of the video (if there is any)
+ by calling wxMediaCtrl::GetBestSize(). Note that the actual result on the
+ display will be slightly different when wxMediaCtrl::ShowPlayerControls is
+ activated and the actual video size will be less then specified due to the
+ extra controls provided by the native toolkit.
+ In addition, the backend may modify wxMediaCtrl::GetBestSize() to include
+ the size of the extra controls - so if you want the real size of the video
+ just disable wxMediaCtrl::ShowPlayerControls().
+
+ The idea with setting wxMediaCtrl::GetBestSize() to the size of the video is
+ that GetBestSize() is a wxWindow-derived function that is called when sizers
+ on a window recalculate.
+ What this means is that if you use sizers by default the video will show in
+ its original size without any extra assistance needed from the user.
+
+
+ @section mediactrl_player_controls Player controls
+
+ Normally, when you use wxMediaCtrl it is just a window for the video to play in.
+ However, some toolkits have their own media player interface.
+ For example, QuickTime generally has a bar below the video with a slider.
+ A special feature available to wxMediaCtrl, you can use the toolkits interface
+ instead of making your own by using the ShowPlayerControls() function.
+ There are several options for the flags parameter, with the two general flags
+ being @c wxMEDIACTRLPLAYERCONTROLS_NONE which turns off the native interface,
+ and @c wxMEDIACTRLPLAYERCONTROLS_DEFAULT which lets wxMediaCtrl decide what
+ native controls on the interface.
+ Be sure to review the caveats outlined in @ref mediactrl_video_size before doing so.
+
+
+ @section mediactrl_choosing_backend Choosing a backend
+
+ Generally, you should almost certainly leave this part up to wxMediaCtrl -
+ but if you need a certain backend for a particular reason, such as QuickTime
+ for playing .mov files, all you need to do to choose a specific backend is
+ to pass the name of the backend class to wxMediaCtrl::Create().