Skip to content

crunchpaste/hopfer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

93 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Logo

A Python GUI for halftoning

hopfer is a Python-based GUI application that implements a wide range of halftoning algorithms from scratch primarily meant for printmaking purposes.


Demo

Note: Version 1.0 is a complete rewrite in QtQuick. An updated demo is coming soon!

Table of contents

Introduction

hopfer is a digital halftoning tool built with QtQuick for the GUI, while leveraging NumPy and Cython for high-performance halftoning.

Originally developed as part of my PhD research on digital halftoning for analog printmaking techniques, hopfer is designed primarily for this purpose. While it may have applications in image compression and visual effects, these are not its main focus.

At present, hopfer does not support palette-based halftoning or multi-level dithering, and there are no plans to add these features.

Features

  • A variety of halftoning algorithms, including:
    • Fixed threshold
    • Local thresholds
    • Random dithering
    • Bayer dithering
    • Clustered dot halftoning
    • Error diffusion dithering
    • Variable error diffusion dithering
    • EDODF dithering
  • Basic non-destructive image editing tools, such as:
    • Rotation
    • Brightness & contrast
    • Blurring
    • Denoising
    • Sharpening
  • Support for a wide range of image formats, including:
    • PNG, JPEG, BMP, TIFF, WebP and more (anything supported by OpenCV)

Requirements

Not sure yet.

Installation

1. Clone the repository

git clone https://github.com/crunchpaste/hopfer

2. Navigate to the project directory

cd hopfer

3. Install with pip (preferably in a venv)

pip install .

4. Run it

hopfer

Acknowledgments

The project relies on the following awesome open-source libraries. I extend my thanks to their maintainers and contributors!

Core

  • numpy: GitHub Link

    The fundamental package for scientific computing with Python.

  • Cython: Website

    An optimising static compiler for Python.

  • opencv-python: GitHub Link

    Used for image processing and encoding/decoding.

  • requests: GitHub Link

    A simple, yet elegant, HTTP library.

User Interface

  • PySide6: Documentation Link

    The official Python bindings for the Qt framework, used to build the GUI.

System

  • makeself: GitHub Link

    Used for creating the Linux installer.

  • Nuitka: Website

    Used for compiling the application into an executable.

  • platformdirs: GitHub Link

    Used for determining standard, cross-platform directories for storing image and configuration data.

  • setproctitle: GitHub Link

    Allows a process to change its title.


Enjoy halftoning!

About

A simple Qt6 app for halftoning images

Topics

Resources

License

Stars

1 star

Watchers

1 watching

Forks

Contributors