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


Permlink Replies: 4 - Pages: 1 - Last Post: 11 Jan 22, 13:47 Last Post By: davidekholm
JeffTucker

Posts: 8,435
Registered: 31-Jan-2006
FixedShapeFilter bugs
Posted: 8 Jan 22, 14:05
 
  Click to reply to this thread Reply
These bugs have been in this filter pretty much forever. It's time to get them fixed.

The first case, that of slide images: https://jefftucker.jalbum.net/fixedshape.zip

Three objects, with original dimensions of 2004x2048, 3017x3601, and 4000x1937. Image bounds set to 1000x1000. User variable:
class=FixedShapeFilter closeups prescale
Conceptually, the filter should crop the images to a 1:1 aspect ratio, which would yield images that are 2004, 3017, and 1937 pixels square. Are you with me so far? Then it should scale them to the image bounds, which would yield final slide images that are all 1000px square. But what I get, instead, are images that are 979, 838, and 484px square.
JeffTucker

Posts: 8,435
Registered: 31-Jan-2006
Re: FixedShapeFilter bugs
Posted: 8 Jan 22, 14:09   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
And now the second case, involving thumbnails: https://jefftucker.jalbum.net/fixedshape2.zip

Same original images. This time, thumbnail bounds of 1000x1000 and slide image bounds of 2000x900. User variable:
class=FixedShapeFilter thumbnails prescale
I should get thumbnails that are all 1000px square, right? The original images are all plenty large enough to do that. But I don't - I get one thumbnail that's 969px square.

Now for the fun part - the result changes if you change the slide image bounds. The slide image bounds, of course, should have no effect whatsoever on the thumbnail images - why would they? But they do. ;)
davidekholm

Posts: 3,620
Registered: 18-Oct-2002
Re: FixedShapeFilter bugs
Posted: 10 Jan 22, 17:32   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
The problem is that the combo "closeup prescale" isn't supported. It reverts to "closeups postscale" but without throwing any error. You can do "all prescale" if you want.

The reason for the 2:nd problem is because jAlbum applies the filters in a pipeline for performance and assumes closeups to be larger than thumbnails (so they are processed first). This could be made more clever I agree.
JeffTucker

Posts: 8,435
Registered: 31-Jan-2006
Re: FixedShapeFilter bugs
Posted: 10 Jan 22, 17:44   in response to: davidekholm in response to: davidekholm
 
  Click to reply to this thread Reply
davidekholm wrote:
The problem is that the combo "closeup prescale" isn't supported. It reverts to "closeups postscale" but without throwing any error. You can do "all prescale" if you want.

Yes, that works. But what if I don't want fixed-shape thumbnails, as well? ;)

The reason for the 2:nd problem is because jAlbum applies the filters in a pipeline for performance and assumes closeups to be larger than thumbnails (so they are processed first). This could be made more clever I agree.

I was thinking that when we start getting into the larger folder thumbnails, this problem could rear its ugly head, especially when coupled with HiDPI. With ordinary thumbnails, it comes up only very rarely, unless you're dealing with a user like mrag, who has long had a preference for humongous thumbnails generated from undersized originals.
davidekholm

Posts: 3,620
Registered: 18-Oct-2002
Re: FixedShapeFilter bugs
Posted: 11 Jan 22, 13:47   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
I think I could address these issues with a software update. If the filtered image is too small to be passed on down the pipeline, jAlbum might as well reuse the original image when producing folder thumbnails and ordinary thumbnails.
Legend
Forum admins
Helpful Answer
Correct Answer

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