General add-ons

 
 
Picture of Anthony Beardsell
Playing video inside Moodle 2.0
 

I am using Moodle 2.0 and my courses consist of a series of modules that incorporate video and audio files. I am able to supply the audio files to students easily using the built in audio player. However I have not found a suitable solution for playing videos. 

The video player in Moodle only seems to have a very small screen size. I have attenpted to alter the screen size using some guidance from posts in this forum but to no avail.

My videos are detailed and require at least standard Youtube sized video screens to view the content adequately.  

My current solution is to link to an outside url where the video is located, but this means taking the student outside of the Moodle LMS, so it is not satisfactory.

My video files are curently stored on Amazon S3. I am looking for a mediaplayer that  can play videos of at least 640 x 360 in size.

Does anyone know of an in-Moodle solution to this? Maybe there is a media plugin out there that can help?

Thanks
 
Anthony 
 
Average of ratings: -
Brian
Re: Playing video inside Moodle 2.0
Group Particularly helpful Moodlers

Hi - Moodle works fine with Video display - it's just that the default playback size is too small.

Please add the following to your config.php for the website or in the config.php of your Theme.  Note change the numbers to make it the video size you want.


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', 800);
}
if (!defined('CORE_MEDIA_VIDEO_HEIGHT')) {
// Default video height. May be defined in config.php if required.
define('CORE_MEDIA_VIDEO_HEIGHT', 700);
}
if (!defined('CORE_MEDIA_AUDIO_WIDTH')) {
// Default audio width if no width is specified.
// May be defined in config.php if required.
define('CORE_MEDIA_AUDIO_WIDTH', 400);
 
Average of ratings: -
Picture of Anthony Beardsell
Re: Playing video inside Moodle 2.0
 

Hi Brian

Thanks for this. Does this use the default video player on the students machine? Any idea if it works for all browsers, and do the video files need to be of a particular format. Eg My videos are largely m4v format. Would this work ok?  

Thanks again

Anthony

 
Average of ratings: -
Matt Bury
Re: Playing video inside Moodle 2.0
Group Particularly helpful Moodlers

Hi Brian,

The M4V media container is almost identical to MP4 and MOV. In fact, if you change the file extension to .mp4 or .mov, in most cases they'll play without any problems.

In most cases, users will be watching through a Flash Player based video player which supports all popular media containers and CODECs except for MKV, AVI, WMV, and WMA. For playback on devices that don't support Flash Player, it's more complicated and you'll need to encode at least three different versions of each video.

I hope this helps! smile

P.S. I may be releasing an alpha version of a video playback plugin similar to this one: http://code.google.com/p/moodle-mplayer/ but don't hold your breath!

 
Average of ratings: -
Brian
Re: Playing video inside Moodle 2.0
Group Particularly helpful Moodlers

Thanks Matt 

Anthony - don't forget you can also upload video to Youtube and keep it private. http://support.google.com/youtube/bin/answer.py?hl=en-GB&answer=157177

That saves load on your server if you are serving a lot of video, or even a bit of video to people at the same time.

 
Average of ratings: -
Picture of Justin Hunt
Re: Playing video inside Moodle 2.0
Group Particularly helpful Moodlers

The other thing you can do is tag ?d=640x360 to the end of the url of the Moodle uploaded video.

So in the html view of the html editor, it might look like this

<p><a href="http://m2.poodll.com/draftfile.php/5/user/draft/myvid.mp4?d=640x340">myvid.mp4</a></p>

 
Average of ratings: -
Picture of Anthony Beardsell
Re: Playing video inside Moodle 2.0
 

Thanks Justin. Your solution has worked perfectly. The videos show up in Quicktime format on my mac and windows based machines. Any idea if I didn't have Quicktime installed whether they would still play? As I said, they are in m4v format. 

The trouble with using Private YouTube videos as far as I can gather is that you are limited to enabling access to 50 people. Does the Moodle count as 1 user for the entire website, or will each of my students count as an individual users? 

Thanks again for your help.

 

Anthony

 

 
Average of ratings: -
Picture of Justin Hunt
Re: Playing video inside Moodle 2.0
Group Particularly helpful Moodlers

Well there is no meaningful restriction on the number of "public" or "unlisted" videos that you can host and share with YouTube. So if you don't need to lock it down, I would go that way. Or you can pay for a Vimeo Pro account which has lots of features for limiting access and stuff.

I think you need to get away from m4v. Because as Matt says, it is only playing because those machine have quicktime/codec installed. You can't guarantee your users will have that. Convert it to mp4, which should be a simple job from m4v.

Then use Moodle's file chooser thingy from the MoodleMedia plugin on the HTML editor to insert your video. If you enable device detection in Moodle and set it up properly, Moodle will play your videos in flowplayer on PC and in HTML5 players for smartphones and tablets. Then you can be confident that pretty much everyone can see your videos

 
Average of ratings: -
Picture of Anthony Beardsell
Re: Playing video inside Moodle 2.0
 

Thanks Justin.

I think that I'll ask my students to make sure that they download quicktime until we get a plugin that plays all m4v files, since I have 200+ videos on my courses. It would be a big job converting all of them!  

Thanks for all your help anyway.

 
Average of ratings: -
Matt Bury
Re: Playing video inside Moodle 2.0
Group Particularly helpful Moodlers

Hi Anthony,

There's probably no need to recode the videos. Just try renaming the file extensions, e.g. change myvideo.m4v to myvideo.mp4. It should work without any problems.

 
Average of ratings:Useful (1)
Picture of AL Rachels
Re: Playing video inside Moodle 2.0
Group DevelopersGroup Particularly helpful MoodlersGroup Testers

Hi Anthony,

If you do decide to convert the videos, check out Any Video Converter. It is available for any version of Windows as well as having a Mac version. Version 5 was just realeased a few days ago. It comes in a free version that will let you setup a bunch of videos at one time for un-attended conversion. It will let you convert to almost any format for phones, tablets, and computers.

Hope this helps,

AL

 
Average of ratings:Useful (2)