Overview
This skill can batch-process PNG images in a directory to make them suitable for use as WeChat emoji stickers. Through an automated workflow that includes background processing, cropping, normalization, and resizing, it ensures the final generated emoji stickers have a consistent appearance and size.
Keywords: WeChat emoji, emoji stickers, image processing, PNG, ImageMagick
When to use this skill
- When you have a series of PNG images and want to quickly convert them into images that meet WeChat emoji sticker standards.
- When the source images have inconsistent background colors and need uniform processing.
- When you need to automatically crop blank areas from images and add standard padding.
Workflow
To perform this task, follow these steps:
- Preparation: Confirm that your system has installed
ImageMagick。 - Execution: Call the
run.shscript, and pass the path of the directory containing PNG images as an argument./bin/bash <path_to_skill>/scripts/run.sh <图片目录路径> - Interactive check: Before completing, the script will pause and prompt you to check the intermediate results in the
mid3-borderdirectory. This is a good opportunity for manual fine-tuning. After checking, press Enter to continue. - Completion: After the script finishes executing, the final results will be saved in the
ressubdirectory under the target directory.
Best practices
- Input: Make sure the input directory contains only the PNG images you want to process.
- Check: When the script pauses, be sure to check the images in the
mid3-borderdirectory to ensure the cropping and border effects meet expectations.
Common pitfalls
- Missing dependency: Not installing
ImageMagickwill cause the script to fail. - Path error: Providing an incorrect directory path or one that does not contain PNG files will cause an error.
For a typical example, refer to https://cafe3310.github.io/chocho-miemie-album/posts/chocho-stickers.html 。