Closed (fixed)
Project:
Scald: Media Management made easy
Version:
7.x-1.x-dev
Component:
Miscellaneous
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
6 Mar 2013 at 21:09 UTC
Updated:
4 Jan 2014 at 02:58 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
jcisio commentedNot yet, but I think it's a good idea. Scald Image can be easily extended to support Picture module.
Comment #2
flocondetoileI tried to modify in scald_image.module the function which load image style line 49
I simply add in this function an another foreach to load picture group
I obtain this
Seems to work fine. the picture group are well present in the select list transcoder.
But the image rendered is then broken. There is yet some work to do.
Comment #3
jcisio commentedPicture groups are not image styles, so I think we need a different prefix (like "group-") for Picture groups. Also, yes, render function needs to be changed too.
Comment #4
jcisio commentedComment #5
nagy.balint commentedOkey here is my first try.
I incorporated the code snippet by flocondetoile with the fix you mentioned.
Since the purpose of the module is to be able to define image styles for certain breakpoints, I only implemented mode=atom and in all other cases the function just returns. So I did not populate the transcoded properties on the atom object.
I determine the fallback image style the same way as the picture module does it when it is set to Automatic.
(Basically just taking the first image style we find)
Comment #6
jcisio commentedNice try. Really.
I was thinking of using properly the transcoder: the transcoder return a structured array of transcoded urls, with their properties (multiplier/breakpoint), then the player will do the rest. Advantage is that we can use the HTML5 figure/figcaption player (that encapsulates the 'picture', with a nice caption), but then it would be more complex: image players have to take care of multiple transcoded urls (easy part, because they can simply take the fallback url if they do not support RWD), and have to clone code from Picture module (subtle part!). I haven't look at that part of Picture to see if there are many lines of code.
Keep the status as NR because I think I'll be back when I have more time investigate the Picture module.
Comment #7
jcisio commentedHere is a recent patch. The same principle, but I arranged code a little and let the HTML5 player support Picture, too.
Comment #8
jcisio commentedI'll reroll the patch.
Comment #9
jcisio commentedOk, I rerolled it, tested a bit and decided to commit! Thanks all.