This question is answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 28 - Pages: 2 [ 1 2 | Next ] - Last Post: 7 Feb 17, 09:57 Last Post By: Dschuwi Threads: [ Previous | Next ]
ccrim

Posts: 29
Registered: 18-Dec-2013
Add support for animated GIFs (without linking all originals)
Posted: 16 Dec 16, 02:28
 
  Click to reply to this thread Reply
It's been a couple of years since I first requested this and I'd like to try again:

I'd like to ask for support of animated gifs to be carried through to the linked slides, but without having to select "Link original files" and bring over all the full-size originals. My previous suggestion from this multi-topic thread is quoted below along with jGromit's response of suggesting of a new context menu item.

Another possibility would be a project-wide option to carry over all animated gifs intact rather than scaling them as png or jpg. I see from a forum search that I'm not alone in wanting to occasionally include animated gifs in a gallery. After all why would you ever include an animated gif and want it to be converted to a static image? It would be similar to converting videos to static images for display by default – not so desirable.

Thanks in advance. (fingers crossed)

ccrim on 17-Sep-2014 21:16:

– “Include Original” Option Doesn't Use Original GIFs
When I select the “Include original” option on animated gif files, I end up with png files being generated (rather than jpg) and it doesn’t use the original gif file as the slide/scaled version. I have to edit the index.html file and manually change the path on these images from, for example, “slides/image-001.png” to “full-size/image-001.gif” to get the original animated gif to show up. (I don’t mind not showing the animated gif in the thumbnail.)


jGromit on 18-Sep-2014 08:14:

This is a misunderstood option. If you select Link to scaled-down images only under Album > Settings > Pages, then every image will end up as a JPG or a PNG in the slides directory. Choosing Include original for one object doesn't change the linking - the slide image is still going to be converted, and clicking on the thumbnail is still going to display the converted image. That choice simply copies the original to the output. It's the equivalent of choosing Link to original via scaled image for that one item. So, the slide image is a JPG, but if the skin provides something like a download link, that will point to the original GIF.

Edit: A couple of years ago, in response to a very different use case, I suggested changing the behavior of this option. But that would run the risk of breaking some existing skins/albums. Maybe what's needed is a new context menu item: Link to original for this object.

JeffTucker

Posts: 8,104
Registered: 31-Jan-2006
Re: Add support for animated GIFs (without linking all originals)
Posted: 16 Dec 16, 03:15   in response to: ccrim in response to: ccrim
 
  Click to reply to this thread Reply
All three of my skins - Gromit, Matrix, and MatrixSlide - offer the option of using original GIF's regardless of what "linking" option you've chosen for the rest of the album.
davidekholm

Posts: 3,719
Registered: 18-Oct-2002
Re: Add support for animated GIFs (without linking all originals)
Posted: 16 Dec 16, 08:48   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
Sorry this hasn't been addressed. Would any of jGromit's skins do the trick for you?
There is currently no possibility to write processed animated GIFs from jAlbum, but I see the point of automatically detecting an animated GIF and include that one instead of an image from it.
JeffTucker

Posts: 8,104
Registered: 31-Jan-2006
Re: Add support for animated GIFs (without linking all originals)
Posted: 16 Dec 16, 14:13   in response to: davidekholm in response to: davidekholm
 
  Click to reply to this thread Reply
My skins tackle this in a pretty simple way. In postdir.bsh, if the skin's "use original GIF's" option has been selected, I just copy any GIF files to the output directory:
if(originalGIF) {
	for(AlbumObject ao : currentFolder.getChildren()) {
		if(!ao.isFolder() && ao.isIncluded() && ao.getName().toLowerCase().endsWith(".gif")) {
			IO.copyFile(ao.getFile(), outputDirectory);
		}
	}
}
The JPG's or PNG's produced by jAlbum are still sitting in the slides directory, but when putting together the slide page (or its equivalent - Matrix has no slide pages), the skin simply points to the original GIF that's now sitting in the root of the output.

The skin doesn't know the difference between an animated GIF and an ordinary GIF - it's just looking at the file extension.
JeffTucker

Posts: 8,104
Registered: 31-Jan-2006
Re: Add support for animated GIFs (without linking all originals)
Posted: 16 Dec 16, 14:21   in response to: davidekholm in response to: davidekholm
 
  Click to reply to this thread Reply
This is tangentially related to an old feature request of mine: http://jalbum.net/forum/thread.jspa?threadID=42125

That wandered off into XBorderFilter issues, but the underlying request is worth keeping on "the list," I think.

In short, one can now choose to include the original for just one album object. It would be nice to have the option to use the original for just one album object.

Including the original mimics Link to original via scaled image - you get both, and imagePath points to the scaled image. Using the original would mimic Link to original, with no scaled image produced, and imagePath pointing to the original in the root.

That would take care of the GIF's, and also any other image that the user, for whatever reason, wanted to remain unscaled. Almost any skin would then grab the correct image (scaled or original) for the slide page, without any code change.
ccrim

Posts: 29
Registered: 18-Dec-2013
Re: Add support for animated GIFs (without linking all originals)
Posted: 18 Dec 16, 17:50   in response to: davidekholm in response to: davidekholm
 
  Click to reply to this thread Reply
davidekholm wrote:
Sorry this hasn't been addressed. Would any of jGromit's skins do the trick for you?

I took a look at them, but I think the Turtle skin is still a better fit for my web site.

There is currently no possibility to write processed animated GIFs from jAlbum, but I see the point of automatically detecting an animated GIF and include that one instead of an image from it.

Hopefully the discussion I see here and in jGromit's related thread will result in some sort of change to pass through animated GIF's. For now, I have to edit the resulting html file to correct the slide link to point to the original GIF file.

Thanks all.
davidekholm

Posts: 3,719
Registered: 18-Oct-2002
Re: Add support for animated GIFs (without linking all originals)
Posted: 24 Jan 17, 16:53   in response to: ccrim in response to: ccrim
 
  Click to reply to this thread Reply
Attachment texts.properties (67.6 KB)
I've added support to use an original file as "closeup image" instead of a scaled/processed version to the upcoming jAlbum 13.10 now. This is perfect for making animated GIF images animate within slide pages. To try it out, ensure you're running jAlbum 13.9, then replace lib/jalbum-core.jar with this beta . You can also replace your texts/texts.properties file with the attached one.

Once done, right-clicking an image will reveal the new "Use original" option. Just click it and make the album again. Note, animated GIFs aren't supported by jAlbum's embedded web browser so you have to open the final album in an external web browser to see the animation.

Skin developers:
The implementation of this feature was straight forward. If "Use original" is checked, "Include original" is deselected and vice versa. If checked, the "Image linking" option for that specific image is simply set to "Link to originals"

JeffTucker

Posts: 8,104
Registered: 31-Jan-2006
Re: Add support for animated GIFs (without linking all originals)
Posted: 24 Jan 17, 17:20   in response to: davidekholm in response to: davidekholm
 
  Click to reply to this thread Reply
Seems to work as advertised, though a user has to be alert to the side effects (in Matrix, for example, scaled images get an XBF drop-shadow, but originals don't).

Now, do I remove the "use original GIF's" option from my skins, added in August, since it mimics the new capability, though in a more automated fashion? Hmmmmm......

And I can almost predict the next piece of the feature request. Most animated GIF's are small, so I can easily imagine a user wanting to use them for the thumbnails, as well. ;)

Dschuwi

Posts: 237
Registered: 12-Nov-2003
Re: Add support for animated GIFs (without linking all originals)
Posted: 24 Jan 17, 22:13   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
jGromit wrote:
And I can almost predict the next piece of the feature request. Most animated GIF's are small, so I can easily imagine a user wanting to use them for the thumbnails, as well. ;)

For now, they would have to use Classic Aligned 2 - this feature is available ;-)

(Settings > Classic Aligned 2 > Appearance > Index Pages)
JeffTucker

Posts: 8,104
Registered: 31-Jan-2006
Re: Add support for animated GIFs (without linking all originals)
Posted: 24 Jan 17, 23:36   in response to: Dschuwi in response to: Dschuwi
 
  Click to reply to this thread Reply
Dschuwi wrote:
For now, they would have to use Classic Aligned 2 - this feature is available ;-)

For the present, I suspect CA2 is alone in that regard. I've never seen it in another skin. But it's certainly on my short list for Gromit and Matrix - the coding for it is fairly straightforward.

Edit: Just one little problem in CA2. If I choose to crop the thumbnails to a fixed shape, the skin squeezes the GIF. That's a tricky problem to deal with!

EditEdit: It takes a little CSS. Fixed-size div, set overflow to hidden, put the image in the div.

EditEditEdit: Better solution eventually will be object-fit and object-position, but it's still not supported in IE11 or Edge, and only partly supported in Safari.
ccrim

Posts: 29
Registered: 18-Dec-2013
Re: Add support for animated GIFs (without linking all originals)
Posted: 25 Jan 17, 02:16   in response to: davidekholm in response to: davidekholm
 
  Click to reply to this thread Reply
davidekholm wrote:
I've added support to use an original file as "closeup image" instead of a scaled/processed version to the upcoming jAlbum 13.10 now. This is perfect for making animated GIF images animate within slide pages. To try it out, ensure you're running jAlbum 13.9, then replace lib/jalbum-core.jar with this beta . You can also replace your texts/texts.properties file with the attached one.

Once done, right-clicking an image will reveal the new "Use original" option. Just click it and make the album again. Note, animated GIFs aren't supported by jAlbum's embedded web browser so you have to open the final album in an external web browser to see the animation.


Thanks! I look forward to not having to remember to manually edit the html when I include a GIF.

And to jGromit, I'm happy without animated thumbnails. I think it would be distracting – and it reminds me of the early web, covered with animated GIF's and flashing text.
JeffTucker

Posts: 8,104
Registered: 31-Jan-2006
Re: Add support for animated GIFs (without linking all originals)
Posted: 25 Jan 17, 02:23   in response to: ccrim in response to: ccrim
 
  Click to reply to this thread Reply
What, you mean you don't miss the beloved <blink> tag? ;)
Dschuwi

Posts: 237
Registered: 12-Nov-2003
Re: Add support for animated GIFs (without linking all originals)
Posted: 25 Jan 17, 08:45   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
jGromit wrote:
Dschuwi wrote:
For now, they would have to use Classic Aligned 2 - this feature is available ;-)

Edit: Just one little problem in CA2. If I choose to crop the thumbnails to a fixed shape, the skin squeezes the GIF. That's a tricky problem to deal with!


From what I remember, this was by design to fit them into the fixed-shape layout.
JeffTucker

Posts: 8,104
Registered: 31-Jan-2006
Re: Add support for animated GIFs (without linking all originals)
Posted: 25 Jan 17, 08:48   in response to: Dschuwi in response to: Dschuwi
 
  Click to reply to this thread Reply
But there's a checkbox to choose between squeezing the thumbnail or cropping it. With a GIF, it won't crop, no matter what you choose. I understand why, since you can't feed the GIF through the jAlbum fixed-shape filter, which would produce a JPG.
Dschuwi

Posts: 237
Registered: 12-Nov-2003
Re: Add support for animated GIFs (without linking all originals)
Posted: 25 Jan 17, 08:51   in response to: ccrim in response to: ccrim
 
  Click to reply to this thread Reply
ccrim wrote:

And to jGromit, I'm happy without animated thumbnails. I think it would be distracting


It's not only about animated GIFs. The purpose is, to pass through images without further processing, e.g. to avoid JPEG artefacts, maybe for a collection of screenshots saved as BMP or PNG etc.
Legend
Forum admins
Helpful Answer
Correct Answer

Point your RSS reader here for a feed of the latest messages in all forums