Skip to main content

A simple GUI tool to pixelate images by averaging colors within a user-defined grid.

Project description

AdaptivePixelizer

PyPI version License: MIT

AdaptivePixelizer is a simple GUI tool to pixelate images by averaging colors within a user-defined grid. It's designed for easily converting high-resolution pixel art or photos into a low-resolution, dot-art style.

Features

  • Interactive Grid Editing: Manually add, delete, and move grid lines directly on the image using mouse clicks and drags.
    • Shift + Left Click: Add vertical line
    • Shift + Right Click: Add horizontal line
    • Ctrl + Click: Delete line under cursor
    • Drag line: Move line
    • Delete/Backspace: Delete line under cursor
  • Zoom and Pan: Easily navigate large images. (Mouse wheel, Alt+Drag)
  • Multiple Color Averaging Methods: Choose between Average, Median, or Mode color calculation for pixelation.
  • Real-time Preview: See the pixelated result instantly (can be toggled on/off).
  • Undo/Redo: Supports undo/redo for grid modifications.
  • Simple Interface: Lightweight and easy to use.

Installation

You can install AdaptivePixelizer using pip:

pip install grid-pixelator

Optional Dependencies:

For potentially faster median color calculation, NumPy is recommended:

pip install grid-pixelator[numpy]

or just "pip install numpy" separately

Usage

  1. Launch the application by typing the following command in your terminal:

    grid-pixelator

  2. Click "画像ファイルを開く" (Open Image File) to load an image.

  3. Adjust the grid lines on the left panel (original image):

    • Use the initial grid spinboxes, or
    • Use Shift+Click, Ctrl+Click, Drag, or Delete/Backspace key as described in Features.
  4. Select the desired color calculation method (Average, Median, Mode).

  5. The pixelated preview will update automatically on the right panel (if "プレビュー自動更新" is checked). Click "プレビュー更新 / 実行" to manually update.

  6. Once satisfied, save the processed image using "ファイル" > "名前を付けて保存...".

Requirements

  • Python 3.8 or later
  • PyQt6
  • Pillow
  • NumPy (Optional, recommended for Median calculation)
  • OS: Primarily tested on macOS, should work on Windows/Linux.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contributing / Issues

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

grid_pixelator-0.1.0.tar.gz (23.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

grid_pixelator-0.1.0-py3-none-any.whl (22.9 kB view details)

Uploaded Python 3

File details

Details for the file grid_pixelator-0.1.0.tar.gz.

File metadata

  • Download URL: grid_pixelator-0.1.0.tar.gz
  • Upload date:
  • Size: 23.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for grid_pixelator-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d7113cbacd7be8991eb3929b5c328526e461961da8152faf98ed6c7f9cc1fd26
MD5 37bb72fdd3f7b138fed50de4be8115a9
BLAKE2b-256 c7a5e059090581a0c6a215002a09bf81f24e747a45c4e80bbd013a5504cf912e

See more details on using hashes here.

File details

Details for the file grid_pixelator-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: grid_pixelator-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 22.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for grid_pixelator-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d614b2e96027c1ab2c46edbdb486886de1505d2461ad24f13eb683ee82d42400
MD5 6f766eba8b5291dee08bf7975cb70349
BLAKE2b-256 1ae6a31de2a1cd17222d8887fa87555e5522c0ffdb6b8ed231eab94ac70cead8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page