How to play mp4 videos in moodle

How to play mp4 videos in moodle

by Amer Child -
Number of replies: 31

I just installed and started playing with Moodle and like what I see, but I was wondering if anyone can tell me which module works best with mp4 video and how I can secure the content so it cannot be downloaded.  I am also wondering if there is a good tutorial on theming Moodle?  

Thanks in Advance 
Amer

Average of ratings: -
In reply to Amer Child

Re: How to play mp4 videos in moodle

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

There are many approaches.  I like to bundle my videos into an RSS feed.  I show these videos to students using a link to my own Flash player, like this.  But this is my unique way to do this.  What I like about my method, is that I can use Moodle's RSS feed block to also display these videos, for downloading (or streaming on iPad/iPhone).

I know of no way to prevent downloading, or copying of video files.  If something can be seen on a computer screen, it can be copied.  My opinion, of course.

In reply to Rick Jerz

Re: How to play mp4 videos in moodle

by Justin Hunt -
Picture of Particularly helpful Moodlers Picture of Plugin developers

I agree with Rick. You can't really prevent copying if a person is committed to doing so. Moodle does though secure access to the link to the file, so that passing around a link won't work. 

The standard flowplayer now plays MP4 via the multimedia plugins filter(installed by default) so if you are on Moodle 2.5 you are good to go.  just upload the file and select it from a repository.

You can adjust various playback settings for that multi media plugins filter in site admin -> appearance -> media embedding. 

In reply to Justin Hunt

Re: How to play mp4 videos in moodle

by Amer Child -

Thank you both.  I have tried to upload an mp4 but my local install tells me is not supported.  What I was hoping to do was to possibly embed a link to a video in an S3 bucket with a signed url and only allow playback.  Here is a link from JWPlayer that explains what I would like to do (tried to paste link) google: jwplayer securing-your-content should be first result.

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Justin Hunt -
Picture of Particularly helpful Moodlers Picture of Plugin developers

Amer

It is definitely supported. (What version of Moodle are you on?)I will go into the reasons from now, but if you stick with it I am 99.75% sure you can get MP4 working.  

One mistake people often make is to use the wrong icon, the one for uploading images, to upload videos. That fails. I attached a screenshot with the correct icon "moodle media" to press . (If that is what you are already doing, sorry.) Another gotcha is that the preview window says it can't play the file, because it trys to do so using quicktime. But once it is inserted in the HTML area and displayed, flowplayer will play it for you.

The other problem you may run into is your file upload size limit being set too small. You can fix that too very easily. Just try small videos first to make sure it works.

The reason I don't like your proposed solution so much is:

i) this is a common requirement, and you don't really need a roll your own solution. Just do it "the Moodle way" and you can avoid a whole lot of technical this and that, and can easily pop back to the forums to request help.

ii) The JW player is not the out of the box Moodle media player (it is not GPL) so every time you embed you will need to do some funkiness.

iii) Moodle already protects your URLs, because it has its own authentication system behind which all your files lie. So you can just use that. 

iv) Doing it the Moodle way makes backing up and restoring your courses complete with files possible. Well this is a two edged sword because your backups get massive, but one of the edges is a plus anyway.

Having said all that if you have zillions of videos, a CDN does make some kind of sense. You would save bandwidth and disk space for starters.

Hope that helps.

Attachment スクリーンショット_071113_044457_PM.jpg
In reply to Justin Hunt

Re: How to play mp4 videos in moodle

by Mohammed Abdulaziz -

I would like also to add one point, and that MP4 compression (file conversions) could cause moodle sometimes to say its not compatible.

I have tried all sort of compressions with MP4 and as I remember, they all seem to work fine except for one compression.   try to convert your file to another MP4 compression.

MP4 is a well known video format, and works really well with Moodle, especially that I have tested this with all versions of moodle 2.x. 

The following link can give you information about MP4 Compressions: 

http://www.ehow.com/how_5895079_compress-mp4-files.html

In reply to Justin Hunt

Re: How to play mp4 videos in moodle

by Amer Child -

OK that makes sense.  I guess I should explain what my goal is, the way we currently structure our classes is to record our session into blocks and we would like to give trainees the ability to access a "course" watch the video complete the demo and post questions of issue to a "training support" forum.  That being said the main course material is the video.  I guess my question is how do I setup a course to meet that goal?

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Amer Child -

I was able to get the video loaded with out an issue other then QT needing to be run.  As stated before the only place I can see where to include a video was during the creation of the course.  Another small side note is it possible to add screencast to the list of resources when attaching a file?

Attachment video-sc.png
In reply to Amer Child

Re: How to play mp4 videos in moodle

by Christian Herman -

As already shown, you can embed a video into nearly everywhere with text editor.  Once your course is created, you can also add your videos using the file resource, setting it to embed. 

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Justin Hunt -
Picture of Particularly helpful Moodlers Picture of Plugin developers

Anywhere you have an HTML area you will have the "MoodleMedia" icon, allowing you to choose a video. You won't see that HTML area until after you have chosen to add a new activity/resource (eg assignment, quiz, label, lesson,page). You add the activity in edit mode, after you have entered your course. Then in the settings for the activity you will see it.

Turn off quicktime and hopefully flowplayer will handle your videos. Go to Site Administration -> appearance -> media embedding and uncheck Quicktime Player under legacy players.  If not , why not tell us your Moodle version so we can really figure it out?

As for your course layout, there are people around here much more capable than me at helping you. The best thing is really to play around yourself and look at other peoples courses.

But I would create a course using the "Topics Format." Each topic would be one of your lessons. The first activity in each topic would be a "Page" resource into which you would put the video and explanation etc. After that you could put quizzes and assignments relating to that video in the same section. 

You can add a forum anywhere, but perhaps you want a single forum at the top of the course (in the summary/topic 0 area).  

 

 

Average of ratings: Useful (1)
In reply to Justin Hunt

Re: How to play mp4 videos in moodle

by Amer Child -

Thank you.  Those bits are very helpful and helps me to get started with creating my first course to really test Moodle and see if this is something we use.  

Once I get this first course built I am sure I will more questions thanks again.  

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Amer Child -

Disabling QT worked and I now have the flowplayer.  Except I am back to my original issue.  When presenting the video in flowplayer the user now has the ability to right-click on the video and save it.  My goal is to force users to register for these classes as part of the Partner membership I need to block the ability to allow them to download the video.  Anyone have any suggestions?

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Amer Child -

New information:  I did some Googling on flowplayer and there is way to secure the video:  http://flash.flowplayer.org/plugins/streaming/secure.html, however I am using apache and I am not that great with PHP, but there is a way to do it, so I thought I would post my finds here is see if anyone and give me some direction on what I would edit to give this a try: http://stackoverflow.com/questions/9860868/flowplayer-secure-streaming-with-apache

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Even if one could stop a download, as long as someone can play a video on their computer they can use screen capture software to copy anything.

In reply to Rick Jerz

Re: How to play mp4 videos in moodle

by Amer Child -

Rick,

I agree but at least putting in some sort of security to help protect our videos is better then none at all.   

In reply to Justin Hunt

Re: How to play mp4 videos in moodle

by Barry Smith -

Justin,

You said that 'Another gotcha is that the preview window says it can't play the file, because it trys to do so using quicktime. But once it is inserted in the HTML area and displayed, flowplayer will play it for you.'

Could you elaborate on this please to explain the steps to achieve the insertion in the HTML area?  I am having a problem with Quicktime.

Thanks.

In reply to Barry Smith

Re: How to play mp4 videos in moodle

by Justin Hunt -
Picture of Particularly helpful Moodlers Picture of Plugin developers

Hi Barry

You just select the mp4 file as usual from whichever repository you are using and ignore any errors/warnings on the preview page and the link when inserted into the page will display (or not) depending on your settings for displaying videos via either the multimedia plugins filter or the poodll filter.

For the multimedia plugins filter, you can turn off quicktime handling of mov/mp4 at 

site administration -> appearance -> media embedding

You can also there elect to play mp4 in an html5 player. That is good only if you know that your students have html5 video capable browsers. That is most browsers these days .... I think ....

If you use PoodLL you can tell it to handle mp4/mov. It will show it in a flowplayer if the device has flash, or an html5 player if it doesn't. 

That is at site administration -> plugins -> filters -> poodll

 

In reply to Rick Jerz

Re: How to play mp4 videos in moodle

by Douglas Broad -

Rick,

Excellent Moodle intro site, fast paced and polished.  Thanks for sharing.  It looks like you are using Camtasia 8 to create your videos?  Have you started using its closed caption features?

In reply to Douglas Broad

Re: How to play mp4 videos in moodle

by Amer Child -

Douglas,

I use Camtasia for all our video recording needs and have used the CC feature, it provides you will a very good base line, but in experience you will need to do some editing. 

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Amer, Camtasia is the product that I use whenever I need to capture a part of someone's video that I cannot easily download.

In reply to Rick Jerz

Re: How to play mp4 videos in moodle

by Amer Child -

I fully get that my videos can be captured by anyone who I allow access to the system.  However the requirement I must meet is to secure the videos.  

If anyone can tell me where is the code to implement the changes I have found that would be a big step in allowing me to get the approval to implement this system for our customers and VAR's.  If I cannot get these "secure" then I can not move forward, and complete building a test system to show the functionality of Moodle.  So far I love it and I think it will meet my requirements and I believe it will allow a registered user to purchase ad hoc training whenever they want.  In addition it think it will give me the ability to schedule classes more frequently so users can register without having to contact sales or myself.

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Justin Hunt -
Picture of Particularly helpful Moodlers Picture of Plugin developers

OK, well there are a few approaches you might take. But perhaps you need to define "secure" for us. It is already secure, as you stated, such that you are able to restrict who accesses the videos. So just passing around the link won't work if someone wants to share the video.

Obfuscating the link though doesn't seem to serve much purpose because the videos are already behind a login requirement. Even if they could predict the link it couldn't be downloaded without logging in. 

I guess then you mainly want to stop students downloading the video and putting it somewhere where non paying people can get it. First point, after you turned off quicktime, you could play the MP4s. Yay, but there is no "download as" link on the flowplayer right click. So I think it is being played via HTML5, which does (at least on chrome) give you a "save as" option. 

I write and use the PoodLL set of plugins. Part of its function is to provide an alternative to the standard multimedia plugins filter in Moodle. It does play MP4 via flowplayer out of the box. If you do use that, then the flowplayer will be used and that "save as" link won't  show. However it is still pretty easy to download the file if you are a little savvy.

If you really want to secure it from downloading, you will need to work with a streaming server(Wowza) and the secure streaming plugin from Flowplayer. Basically what those links you posted are talking about.

I would not start by hacking a few lines of core Moodle, because it will be a pain to maintain and might be harder than you would think. I think you would be better to start with the RTMP plugin, and add all your logic in there.

https://moodle.org/plugins/view.php?plugin=filter_rtmp

You will no longer be using the Moodle file system. Instead you will need to store your videos somewhere the streaming server has access to them and use special links that point to them, eg rtmp://wowza.myinst.org/edvideos/gettingpaid.flv

That means that the videos will no longer behind Moodle's login wall, and that links could be passed around. But from the info on the docs you sent, perhaps that would be quite difficult. You should also check if those videos will play back on mobile devices, and if not whether that is a showstopper for your project.

Finally just to go way off on a tangent and cause head scratching. If you really want to secure it, you could can the whole mp4/flowplayer  business altogether. I put together a few video tutorials/intros using sliderocket. I reasoned that rather than putting 15 sequential minutes into a single video, it would be better to integrate a menu connecting 5 or so shorter videos. So people could stop, rewind , jump to where they want etc. Since it is not a video file it can't be downloaded. Tada. Here are two links, but I suppose its a bit off base:
 http://poodll.com/screencasts/poodll-2-for-moodle-2-1/installing-red5-1-0-rc1-with-poodll/

http://poodll.com/audio-recording-sdk/

Good luck

In reply to Justin Hunt

Re: How to play mp4 videos in moodle

by Amer Child -

Justin,

Thanks for the great information.  I was taking a look at poodll and that may do the trick.  Basically the higher ups do not want an obvious way to download our content.  From looking at your source it couldn't find the URL to the source video so that seems like the best solution for me in order to use moodle.  I will download and install poodll and see if I can get up and running today and start testing.  Thanks Again.

In reply to Douglas Broad

Re: How to play mp4 videos in moodle

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

I actually strive for "fast paced and polished" because students can always replay these.  Thanks for the compliment.  I did use Camtasia 8 for the screen video captures, and then I edited them in Premiere CS6.

I now have Camtasia 2.4 for the Mac.

No, I have not tried the CC features because these (the CC) would not import into Premiere, which is where I do my final editing.  CC is going to take a lot more work, and my school believes that this is an IT duty, not a professor duty (however, they have never really faced the issue, and I am sure IT would have second thoughts about this if they did.)

Are you using CC?

I am not against CC, I just don't have an easy way to do this right now.  I produce all of my own videos, and I also only have so much time.  Being hearing disabled myself, I know how beneficial CC would be.

In reply to Rick Jerz

Re: How to play mp4 videos in moodle

by Pamela Dooley -

I use Camtasia and do all my editing in Camtasia. Why do you move it to Premiere to edit? Camtasia has great features for capturing screen video including panning, callouts and CC.

In reply to Pamela Dooley

Re: How to play mp4 videos in moodle

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Very good question, Pamela.  I have used Camtasia for over 10 years, and it continues to get more and more powerful.  Historically, Premiere was much more capable, but maybe today, one could get by with only Camtasia.

I have found that Premiere provide much better editing and composing tools.  Once learned, it make the editing process much easier.  Premiere also seems to be able to import many more types of media.  It offers many more ways to output (produce) videos, but this is not as big a factor anymore since mp4s are becoming "standard."  Premiere allows me to tweak the mp4 settings better.  It also has many more "effects" for both audio and video.  Camtasia only recently added more tracks for media.

I really like both products.  I have nothing bad at all to say about Techsmith.  Their support is excellent.

For most folks just getting started with video creation, I would have to suggest to them to see how far they can go with Camtasia first.  Then, as they get better and maybe (maybe) want to expand their capabilities, then they should look at Premiere.

I have never used the Mac software (iMovie or others), but I now own a Mac and still use Premiere (I actually own the Creative Cloud suite.)

 

In reply to Rick Jerz

Re: How to play mp4 videos in moodle

by Douglas Broad -

I have begun using CC because I believe that we may be required soon to use it and I do not want to need to redo my work.  I don't know practically how IT could edit your Camtasia files and keep you in the loop. This is my sequence: I

  1. train Camtasia to recognize my voice.  This is preliminary prep not related to a particular project.
  2. write a script before or after the non-audio screen capture.
  3. read technical words from the script into the voice training of CC.  This improves the CC voice to text translation later.  
  4. create the presentation, usually screen demos without audio
  5. record  the audio by reading the script. 
  6. do the editing by aligning the audio tracks and video tracks in the Camtasia editor(extending frames, cutting and moving audio tracks, adding callouts etc.
  7. After everything else is finished I add the CC captions.
  8. Review the captions and compare with the script.  Cut and paste from the script if necessary to fix.
  9. Produce.

Once nice unexpected benefit of the CC feature was a search feature where the viewer could navigate by key word search. For a short 5 to 10 minute video, it does take about half an hour to complete the CC.

In reply to Douglas Broad

Re: How to play mp4 videos in moodle

by Amer Child -

We use Camtasia for 99% of our videos.  We do a bi-weekly technical session and have been using it for 4 years to record, edit and produce the videos.  We use the built in voice recognition for the initial pass on the CC then comeback through and edit where it is necessary.  Since we have moved our library to youtube.com/basis we are testing out their auto CC function, and have not uploaded all our current CC to the site.

In reply to Rick Jerz

Re: How to play mp4 videos in moodle

by Douglas Broad -

Sorry for the delay in responding.  Yes, I am using CC for many of my videos.  It makes the video text searchable.  Takes about 30% more time to add it and it helps to have a written script to cut and paste from .  Its important to speak clearly but the speech recognition gets technical words wrong quite often.

In reply to Amer Child

Re: How to play mp4 videos in moodle

by Ian Kris Banawa -

is this for real? is something like playing mp3 here in moodle is possible? its new to my ear. sorry for being an ignorant.