12

We're currently trying to optimize our site so the end users get fast response times. One of the areas we are looking at moment is the media served from the Sitecore Media Library.

What settings are available and what techniques can be used to ensure that the media items are both optimized in terms of size?

For example, it's not uncommon for users to upload large high quality 1MB+ images, but the image may only used as a small thumbnail on a related content widget or even when used as a main image on a page, the uploaded image is much larger than the conataining HTML element.

Are there any settings available to "down size" the image for each use or should be instead ensure that the editors upload the correct size image to begin with?

11

You've got a few options:

The Simple Option:

Add a width (see here: Sitecore Image Parameters) - the image sizes will be processed. The disadvantage of this approach is that you get a processing hit the first time the image is resized (it then caches the result I believe).

A more complex option:

You can build something which farms the images out to a CDN and processes the images within the CDN - you'd have to do quite a bit of heavy bespoke work to get this going but it would be pretty cool :)

An enterprise option:

You could use an external DAM to do the heavy lifting for you (something like Picturepark, Asset Bank, EDAM, DigiZuite etc).

12

You could also use this...

https://github.com/kamsar/Dianoga

An automatic image optimizer for the Sitecore media library.

5

I would always make sure that your renderings output images with a max-width that is suitable for that rendering, so that any images larger than this uploaded by your editors isn't rendered onto the page at a size much larger than it needs to be. The beauty of the Sitecore media pipeline is that this processing is done on the fly and the images are cached for their next use, so you don't need to specify that images are "pre-processed" to certain sizes at upload time.

I would also encourage the use of a library like Picturefill if you are using large images on your site in heros, carousels, etc. This allows the page to specify different sized images and the browser will only download the image that is suitable for the screen-width of their device. Again, because Sitecore can generate resized images on the fly, they can all come from a single media source.

Thirdly, and this lies outside of Sitecore image optimization, but you could look at a lazy-loading technique for images on your pages, e.g. not loading images out of view until they are about to be displayed.

0

If your question re DAM selection is still open then I would recommend to consider building your external asset management based on Amazon Web Services and then plugging it into Sitecore.

I have recently released an open source module called "External Asset Management in Sitecore" what does all the integration routine, it is available on GitHub here and I hope that you will find it helpful.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.