Image optimiser

Filters ::: filter_imageopt
Maintained by Guy Thomas
Resize images to a configurable maximum size. Delay the loading of images until visible in the viewport.
Latest release:
511 sites
158 downloads
39 fans
Current versions available: 5

Image optimiser filter

The image optimiser filter is intended to solve the issue of high resolution images slowing down (and blocking) page loads.

Features:

  • Resize images that are greater than a maximum width and preserve aspect ratios and original images.
  • Resizes images in all filterable text - course content, user profile description, etc.
  • Allow for delayed loading of images (load when visible) with the option of specifying how many images should be loaded immediately before images are placeheld and loaded when in the view port and the page has fully loaded (eliminates blocking for other resources, e.g. javascript in the footer).

Example scenarios:

  • Course designer doesn't know how to resize images prior to upload and uploads a 6 mega pixel image when they don't require this resolution. The filter solves this issue by automatically resizing images to a specified maximum width (aspect ratios are preserved).

  • Course designer uploads 100s of images into a course label The filter can solve this issue by place holding images and making them load only when scrolled into the viewport.

  • Students using mobile data plans are finding their course page to be sluggish due to unnecessarily large images uploaded to their course. The filter can solve this issue by both placeholding images until scrolled into the viewport and then resizing the image which is served to the user.

Configuration

For the filter to work, it must be enabled via Site administration / Plugins / Filters / Manage filters.

The filter settings area available via Site administration / Plugins / Filters / Image optimiser.

By default, the optimiser both place holds (load when visible) and resizes (maximum image width) to 800px.

Videos

Load on visible feature - images are place held and then loaded when visible in the view port.

Non destructive resizing - resampling is always done against the original image

Mobile page load speed WITHOUT the image optimiser

Mobile page load speed WITH the image optimiser (over twice as fast)

Note, the page is ready in half the time when the filter is enabled!

Copyright

(c) Guy Thomas 2017

Licence

http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Author

Developed by Guy Thomas.



Note - for an up to date description of this plugin - please visit:


https://github.com/gthomas2/moodle-filter_imageopt/blob/master/README.md

Screenshots

Screenshot #0
Screenshot #1

Contributors

Guy Thomas (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • I Teach With Moodle
    Wed, Mar 7, 2018, 2:39 PM
    Hi Guy,
    Sorry I had not noticed your reply a few months back. Thanks for fixing the issue.
    Cheers,
    Fred
  • Thu, Mar 14, 2019, 8:41 PM
    Hey Guy,

    This plugin sounds great!
    I just have some questions before using it.

    What is its future?
    Is it safe to use for production on a Moodle 3.5 and later versions?
    Was it created while you were working on Snap?
    Are you still maintaining it? Otherwise, does it exist alternatives?

    Thanks wink
    Patrice
  • Fri, Mar 15, 2019, 5:12 PM
    @Pat Sej. I will check it out with Moodle 3.5 and 3.6 later today. Yes I created it around the same time I was working on Snap but I did it as a personal project. I will continue to maintain it.
  • Fri, Mar 15, 2019, 5:13 PM
    @Pat Sej - there is already a Moodle 3.5 version if you click on 'versions'. Will check it with Moodle 3.6 later today.
  • Fri, Feb 14, 2020, 2:57 PM
    Hello Guy,
    It looks like a great plugin. Will it work with Moodle 3.7?
  • Mon, Apr 20, 2020, 6:44 PM
    @Vishal E. Sorry for the late reply. Best to just try it. I've released a version on github that works with Moodle 38 yesterday. The branch is MOODLE_38_STABLE.
  • Mon, Apr 27, 2020, 12:00 AM
    @Guy Thanks for your answers above (I did not see them earlier ...)
    I see that the Install button is not active for Moodle 3.8
    I suppose that when your branch MOODLE_38_STABLE will have been tested by the community, the button will be active, right?
    Thanks for your work BTW wink
  • Sat, May 2, 2020, 5:48 PM
    @Pat - If you could test it and let me know if you find any bugs I will fix them. If not let me know if its working OK and I will publish a version to this page.
  • Mon, Jun 29, 2020, 10:03 PM
    Hi, can I ask whether this plugin has yet been approved for V3.8? The comments above seem to indicate it's OK, but we are reluctant to install plugins that are not verified as working for our Moodle version
  • Fri, Oct 2, 2020, 4:23 AM
    Hi , dose it work with Moodle 3.7?
  • Mon, Oct 26, 2020, 7:41 PM
    @Steve Radford - 3.8 version available on github https://github.com/gthomas2/moodle-filter_imageopt/tree/MOODLE_38_STABLE
  • Mon, Oct 26, 2020, 7:41 PM
    @Mohammad Nabil - the 3.8 version will probably work OK with 3.7. Not test it though.
  • Wed, Dec 23, 2020, 8:24 PM
    Hi @Guy, will you be publishing versions to the Plugins database here? At the moment it's looking unsupported, although I can see you've got a version for Moodle 3.8 in Github. This is such a useful plugin. It's a shame it isn't part of Moodle Core...
  • Tue, Mar 2, 2021, 10:10 AM
    This is a great plugin! I hope this will work on Moodle 3.10.
    Thanks for making and sharing this plugin.
  • Tue, Mar 2, 2021, 11:07 AM
    Agree--this is a great plugin and eventually should be part of the Moodle core since many teachers and students won't necessarily take the time to upload images that are sized correctly or to resize them, and this plugin brilliantly takes care of that automatically. Also does lazy loading, which only loads the image when it's scrolled to--genius!!
1 2 3
Please login to post comments