Control How Many Size Transformations using jquery.cloudinary.js
If I am using the jquery.cloudinary.js script to automate delivery of the proper width image, like in this example:
`
<img data-src="http://res.cloudinary.com/demo/image/upload/w_auto/smiling_man.jpg" class="cld-responsive">
Is there a way to control how aggressively the script attempts to send a new image transformation? In other words, I don't want a new image being server up every 5 pixels the browser is smaller (to use an exaggerated number).
The "Responsive Breakpoint Generator" has a way of setting the maximum number or image and also the size differentiation between new sizes.
Can this kind of thing be controlled through the URL using the method above? I'm not neccesarily looking for absolute control, but just a way to sort of harness it in a bit.
Thanks!
-
Hi
By default, the breakpoints steps for resizing are calculated for every 100px.
This can be modified by using the
config
method to pass new values for thebreakpoints
andresponsive_use_breakpoints
parameters.it's possible to see detailed explanation and examples in the link below:
http://cloudinary.com/documentation/responsive_images#overriding_default_values
Please sign in to leave a comment.
Comments
1 comment