A powerful Python GUI application for batch image processing with support for local and cloud-based optimization.
- Batch Processing: Process multiple images simultaneously with progress tracking
- Multiple Optimization Options:
- Local compression using Pillow
- Cloud compression using TinyPNG API
- Image resizing with configurable dimensions
- Format conversion (JPEG, PNG, BMP, GIF, TIFF, WebP)
- Asset Cleaning: Built-in asset cleaner with Cocos Creator integration
- Flexible Output Modes:
- Overwrite original files
- Create new folder with processed images
- Custom output directory
- Real-time Preview: Visual feedback before processing
- Configurable Settings: API keys, compression quality, processing preferences
Coming soon
- Python 3.7 or higher
- pip package manager
- Clone the repository:
git clone https://github.com/your-username/ImageForge.git
cd ImageForge- Create and activate a virtual environment:
python3 -m venv venv
# On Windows:
venv\Scripts\activate
# On Linux/macOS:
source venv/bin/activate- Install dependencies:
pip install -r requirements.txtEdit config.ini to set up your TinyPNG API key and customize processing settings:
[tinypng]
api_key = your_tinypng_api_key_here
[processing]
default_compression = 0.8
max_file_size_mb = 10
supported_formats = jpeg,png,bmp,giff,tiff,webppython main.py- Select Images: Use the file browser to select one or multiple images
- Choose Processing Type:
- Compress: Reduce file size while maintaining quality
- Resize: Change image dimensions
- Compress + Resize: Combine both operations
- Configure Settings: Adjust compression level, output format, and dimensions
- Set Output Directory: Choose where to save processed images
- Process: Click the process button and monitor progress
The included asset cleaner tool helps optimize images for game development:
cd tools/asset-cleaner-cocos
python main.pyImageForge/
├── core/ # Core business logic
│ ├── config.py # Configuration management
│ ├── file_manager.py # File operations
│ ├── image_processor.py # Main processing logic
│ └── logger.py # Logging system
├── gui/ # User interface
│ ├── main_window.py # Main application window
│ ├── asset_cleaner_panel.py # Asset cleaning UI
│ └── managers/ # UI component managers
├── utils/ # Utility modules
│ ├── pillow_wrapper.py # Local image processing
│ ├── tinypng_client.py # TinyPNG API client
│ └── asset_cleaner/ # Asset cleaning utilities
├── tools/ # Additional tools
│ └── asset-cleaner-cocos/ # Cocos Creator asset cleaner
├── main.py # Application entry point
├── config.ini # Configuration file
└── requirements.txt # Python dependencies
- ImageProcessor: Main orchestrator for image processing operations
- PillowWrapper: Local image processing with fallback support
- TinyPNGClient: Cloud-based compression using TinyPNG API
- FileManager: File handling and directory operations
- GUI Managers: Modular UI components (MainView, ProcessControl, etc.)
- Input: JPEG, PNG, BMP, GIF, TIFF, WebP
- Output: JPEG, PNG, BMP, GIF, TIFF, WebP
- Pillow: Image processing and manipulation
- Wand: ImageMagick wrapper for advanced processing
- requests: HTTP client for API communication
- tkinter: GUI framework (included with Python)
- configparser: Configuration file management
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Initial release with batch image processing
- TinyPNG API integration
- Asset cleaning functionality
- GUI with real-time preview
- Support for multiple image formats
- TinyPNG for providing the compression API
- Pillow for image processing capabilities
- Cocos Creator for game development framework
For issues and questions:
- Create an issue on GitHub
- Check the troubleshooting section in the documentation
- Review the CLAUDE.md file for development guidance