[GH-ISSUE #599] preserve-aspect-ratio (par) option has no effect; cannot stretch to exact width/height #216

Closed
opened 2026-02-25 22:34:38 +03:00 by kerem · 0 comments
Owner

Originally created by @sadok-f on GitHub (Jan 12, 2026).
Original GitHub issue: https://github.com/flyimg/flyimg/issues/599

Originally assigned to: @sadok-f on GitHub.

Bug reported here: https://github.com/flyimg/flyimg/discussions/598

Steps to reproduce
Open the demo.
Request an image with a different aspect ratio using both width and height,
https://demo.flyimg.io/upload/w_200,h_300,par_1/https://flyimg.io/demo-images/Citroen-DS.jpg
or
https://demo.flyimg.io/upload/w_200,h_300,par_0/https://flyimg.io/demo-images/Citroen-DS.jpg.
Actual behavior
Returned image size is ~200x173, preserving the original aspect ratio.
Changing par between 0 and 1 has no visible effect.
Expected behavior
par=1 (default): preserve aspect ratio (current behavior).
par=0: do not preserve aspect ratio; stretch image to exactly the requested w×h (e.g. 200x300).

Originally created by @sadok-f on GitHub (Jan 12, 2026). Original GitHub issue: https://github.com/flyimg/flyimg/issues/599 Originally assigned to: @sadok-f on GitHub. Bug reported here: https://github.com/flyimg/flyimg/discussions/598 **Steps to reproduce** Open the demo. Request an image with a different aspect ratio using both width and height, https://demo.flyimg.io/upload/w_200,h_300,par_1/https://flyimg.io/demo-images/Citroen-DS.jpg or https://demo.flyimg.io/upload/w_200,h_300,par_0/https://flyimg.io/demo-images/Citroen-DS.jpg. **Actual behavior** Returned image size is ~200x173, preserving the original aspect ratio. Changing par between 0 and 1 has no visible effect. **Expected behavior** par=1 (default): preserve aspect ratio (current behavior). par=0: do not preserve aspect ratio; stretch image to exactly the requested w×h (e.g. 200x300).
kerem 2026-02-25 22:34:38 +03:00
  • closed this issue
  • added the
    bug
    label
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/flyimg#216
No description provided.