Skip to content

Commit

Permalink
iconforge: Use height() for y axis to support non-square icons (#197)
Browse files Browse the repository at this point in the history
  • Loading branch information
tigercat2000 authored Jan 6, 2025
1 parent ac48a18 commit e873712
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/iconforge.rs
Original file line number Diff line number Diff line change
Expand Up @@ -875,7 +875,7 @@ fn transform_image(image: &mut RgbaImage, transform: &Transform) -> Result<(), S
apply_all_transforms(&mut other_image, &icon.transform)?;
};
for x in 0..std::cmp::min(image.width(), other_image.width()) {
for y in 0..std::cmp::min(image.width(), other_image.width()) {
for y in 0..std::cmp::min(image.height(), other_image.height()) {
let px1 = image.get_pixel_mut(x, y);
let px2 = other_image.get_pixel(x, y);
let pixel_1 = px1.channels();
Expand Down

0 comments on commit e873712

Please sign in to comment.