Skip to content

Commit

Permalink
fix: Use the merged layer when saving
Browse files Browse the repository at this point in the history
  • Loading branch information
jakewvincent committed Jun 19, 2024
1 parent 172dc71 commit 6e108d3
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions scripts/xcf_to_png.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,9 @@ for file in $xcf_files_to_convert; do
gimp -i -b "
(let* (
(image (car (gimp-file-load RUN-NONINTERACTIVE \"$file\" \"$file\")))
(drawable (car (gimp-image-get-active-layer image)))
(merged-layer (car (gimp-image-merge-visible-layers image CLIP-TO-BOTTOM-LAYER)))
)
(gimp-image-merge-visible-layers image CLIP-TO-BOTTOM-LAYER)
(file-png-save RUN-NONINTERACTIVE image drawable \"$output_file\" \"$output_file\" 0 9 0 0 0 0 0)
(file-png-save RUN-NONINTERACTIVE image merged layer \"$output_file\" \"$output_file\" 0 9 0 0 0 0 0)
(gimp-image-delete image)
)
(gimp-quit 0)
Expand Down

0 comments on commit 6e108d3

Please sign in to comment.