Platforms to show: All Mac Windows Linux Cross-Platform

MFPMediaPlayerMBS class

Type Topic Plugin Version macOS Windows Linux iOS Targets
class Windows Media Foundation MBS WinFrameworks Plugin 20.0 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
Function: The Windows Media Foundation Media Player class.
An alternative movie and audio player for Xojo.
For Windows 7, Windows Server 2008 R2 or newer.

Feedback, Comments & Corrections


Constant Value Description
StateEmpty 0 Initial state. No media items have been set on the player object.
StatePaused 3 Playback is paused.
StatePlaying 2 Playback is in progress.
StateShutdown 4 The player object was shut down. This state is returned after the application calls Shutdown method.
StateStopped 1 Playback is stopped.

Aspect Ratio Modes

Constant Value Description
VideoARModeMask 7 Bitmask to validate flag values. This value is not a valid flag.
VideoARModeNone 0 Do not maintain the aspect ratio of the video. Stretch the video to fit the output rectangle.
VideoARModeNonLinearStretch 4 Apply a non-linear horizontal stretch if the aspect ratio of the destination rectangle does not match the aspect ratio of the source rectangle.

The non-linear stretch algorithm preserves the aspect ratio in the middle of the picture and stretches (or shrinks) the image progressively more toward the left and right. This mode is useful when viewing 4:3 content full-screen on a 16:9 display, instead of pillar-boxing. Non-linear vertical stretch is not supported, because the visual results are generally poor.

This mode may cause performance degradation.

If this flag is set, you must also set the VideoARModePreservePixel and VideoARModePreservePicture flags.
VideoARModePreservePicture 1 Preserve the aspect ratio of the video by letterboxing or within the output rectangle.
VideoARModePreservePixel 2 Correct the aspect ratio if the physical size of the display device does not match the display resolution. For example, if the native resolution of the monitor is 1600 by 1200 (4:3) but the display resolution is 1280 by 1024 (5:4), the monitor will display non-square pixels.

If this flag is set, you must also set the VideoARModePreservePicture flag.

This class has no sub classes.

Some examples using this class:

Blog Entries

Xojo Developer Magazine


The items on this page are in the following plugins: MBS WinFrameworks Plugin.

MFPMediaPlayerExceptionMBS   -   MidiClientMBS

The biggest plugin in space...

MBS Xojo Plugins

Start Chat