Skip to content

Little issue #3

@Fossor

Description

@Fossor

Hi there!
Thanks for a great stuff!
I think you have little miscalculation in ImageResizer->calculateInSampleSize

long totalPixels = width * height / inSampleSize;

should be

long totalPixels = width / inSampleSize * height / inSampleSize;

and then

while (totalPixels > totalReqPixelsCap) {
                inSampleSize *= 2;
                totalPixels /= 2;
            }

should be

while (totalPixels > totalReqPixelsCap) {
                inSampleSize *= 2;
                totalPixels /= 4;
            }

After that you can instantiate ImageInternalFetcher with a smaller size (closer to the size of a thumb)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions