Multimedia

Change Dimensions of Video Player

The dimensions of the embedded video player are defined here: /lib/medialib.php. Code:

if (!defined('CORE_MEDIA_VIDEO_WIDTH')) {
    // Default video width if no width is specified; some players may do something
    // more intelligent such as use real video width.
    // May be defined in config.php if required.
    define('CORE_MEDIA_VIDEO_WIDTH', 600);
}
if (!defined('CORE_MEDIA_VIDEO_HEIGHT')) {
    // Default video height. May be defined in config.php if required.
    define('CORE_MEDIA_VIDEO_HEIGHT', 450);
}

So, you can also change the settings through config.php, by including these constants.

Private Videos through Vimeo

You can't serve private videos through YouTube, you need a Vimeo Plus account (about €50 or $60 a year). In Vimeo, you can select to only serve videos through specific domains, e.g. your Moodle's domain.

Responsive Videos through FitVids.js

By default, videos are not responsive in Moodle. However, if you use e.g. the Essential theme, they will be. In the background, Essential uses FitVids.js to make them responsive.


Personal Tools