{"id":18427173,"url":"https://github.com/fjebaker/brimage","last_synced_at":"2026-04-03T18:15:39.347Z","repository":{"id":57416381,"uuid":"250317085","full_name":"fjebaker/brimage","owner":"fjebaker","description":"Glitch art library. ","archived":false,"fork":false,"pushed_at":"2024-03-20T15:50:47.000Z","size":1090,"stargazers_count":6,"open_issues_count":1,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2026-01-13T17:19:22.064Z","etag":null,"topics":["art","fm","frequency-modulation","glitch","glitch-art","glitch-art-library","image","pypi","python"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fjebaker.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-03-26T16:49:43.000Z","updated_at":"2024-03-15T03:23:31.000Z","dependencies_parsed_at":"2022-08-23T16:40:13.147Z","dependency_job_id":null,"html_url":"https://github.com/fjebaker/brimage","commit_stats":null,"previous_names":["dustpancake/brimage"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/fjebaker/brimage","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fjebaker%2Fbrimage","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fjebaker%2Fbrimage/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fjebaker%2Fbrimage/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fjebaker%2Fbrimage/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fjebaker","download_url":"https://codeload.github.com/fjebaker/brimage/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fjebaker%2Fbrimage/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31368162,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-03T17:53:18.093Z","status":"ssl_error","status_checked_at":"2026-04-03T17:53:17.617Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["art","fm","frequency-modulation","glitch","glitch-art","glitch-art-library","image","pypi","python"],"created_at":"2024-11-06T05:09:50.379Z","updated_at":"2026-04-03T18:15:39.271Z","avatar_url":"https://github.com/fjebaker.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"BRImage\" src=\"https://github.com/Dustpancake/BRImage/blob/master/banner-image.jpg\"\u003e\n\u003c/p\u003e\n\n\n# BRImage\n\n\u003cp align=\"center\"\u003e\n\u003ca href=\"https://github.com/dustpancake/BRImage/workflows/Build/\"\u003e\u003cimg alt=\"Build Status\" src=\"https://github.com/dustpancake/BRImage/workflows/Build/badge.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://pypi.python.org/pypi/BRImage/\"\u003e\u003cimg alt=\"PyPi Version\" src=\"https://img.shields.io/pypi/v/brimage.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://pypi.python.org/pypi/BRImage/\"\u003e\u003cimg alt=\"Downloads per Week\" src=\"https://img.shields.io/pypi/dw/brimage.svg\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\nGlitch Art Library and command line tool for generating glitch-art effects inspired by CRT monitors.\n\nOne-liner install:\n```\npip install BRImage \u0026\u0026 brimage -h\n```\n*Note:* requires Python3.7 or higher.\n\n\u003c!--BEGIN TOC--\u003e\n## Table of Contents\n1. [Usage](#toc-sub-tag-0)\n\t1. [Frequency Modulation](#toc-sub-tag-1)\n\t2. [Random Walk](#toc-sub-tag-2)\n2. [Installation](#toc-sub-tag-3)\n\t1. [pypi](#toc-sub-tag-4)\n\t2. [Building from source](#toc-sub-tag-5)\n3. [Changelog](#toc-sub-tag-6)\n\u003c!--END TOC--\u003e\n\n## Usage \u003ca name=\"toc-sub-tag-0\"\u003e\u003c/a\u003e\nBRImage can be used as both a command line interface and python package. The command line tool provides basic access to each algorithm.\n\n```bash\nbrimage -h\n```\n\n### Frequency Modulation \u003ca name=\"toc-sub-tag-1\"\u003e\u003c/a\u003e\nCommand line:\n```\n$ brimage freqmod -h\nusage: BRImage freqmod [-h] [--omega OMEGA] [--phase PHASE] [--lowpass LOWPASS] [--pquantize PQUANTIZE] [-o OUTPUT_FILE] input_image\n\nFrequency modulation algorithm for images. Implicitly converts to greyscale.\n\npositional arguments:\n  input_image           Input image path; most common formats are accepted.\n\noptional arguments:\n  -h, --help            show this help message and exit\n  --omega OMEGA         Frequency omega; controls line spacing. Range: 0.0 to 1.0, \u003e1.0 also works, but ugly. (default: 0.3)\n  --phase PHASE         Controls the phase range that is used to map the pixel values into. Higher values distort the image more. Range: 0.0 to 1.0 (default: 0.5)\n  --lowpass LOWPASS     Set the lowpass filter amount. Lower values blur out fine detail more. Set to 0 disables the filter. Preconfigured to 30Hz sample rate. Range: 0.0 to 1.0. (default: 0)\n  --pquantize PQUANTIZE\n                        Post-quantize number; integer number of colours to quantize image to after frequency modulation. Range: \u003e=0. Value of 0 disables post-quantize (default: 0)\n  -o OUTPUT_FILE, --output_file OUTPUT_FILE\n                        Output image path. (default: output.jpg)\n```\nExample:\n\nInput Image            |  Output Image\n:-------------------------:|:-------------------------:\n![](https://github.com/Dustpancake/BRImage/blob/master/examples/sample-image.jpg)  |  ![](https://github.com/Dustpancake/BRImage/blob/master/examples/freqmod.jpg)\n\n### Random Walk \u003ca name=\"toc-sub-tag-2\"\u003e\u003c/a\u003e\nCommand line:\n```\n$ brimage randomwalk -h\nusage: BRImage randomwalk [-h] [--lines LINES] [--greyscale] [-o OUTPUT_FILE] input_image\n\nRandom walk algorithm for images. Most values are still hardcoded in a header file, which requires recompilation. Later release will make this available through python.\n\npositional arguments:\n  input_image           Input image path; most common formats are accepted.\n\noptional arguments:\n  -h, --help            show this help message and exit\n  --lines LINES         Number of individual line paths to draw. (default: 500)\n  --greyscale           Process image as greyscale. (default: False)\n  -o OUTPUT_FILE, --output_file OUTPUT_FILE\n                        Output image path. (default: output.jpg)\n```\nExample:\n\nInput Image            |  Output Image\n:-------------------------:|:-------------------------:\n![](https://github.com/Dustpancake/BRImage/blob/master/examples/sample-image.jpg)  |  ![](https://github.com/Dustpancake/BRImage/blob/master/examples/randomwalk.jpg)\n\n## Installation \u003ca name=\"toc-sub-tag-3\"\u003e\u003c/a\u003e\n\n### pypi \u003ca name=\"toc-sub-tag-4\"\u003e\u003c/a\u003e\nI've made the project available with `pip` (you can view the project [here](https://pypi.org/project/BRImage/)):\n```bash\npip install BRImage\n```\n\nand run with\n```bash\nbrimage\n```\n\n### Building from source \u003ca name=\"toc-sub-tag-5\"\u003e\u003c/a\u003e\n- Requires [SWIG](http://swig.org/).\n\nFirst, clone the repository\n```bash\ngit clone https://github.com/Dustpancake/BRImage \u0026\u0026 cd BRImage\n```\n\nGenerate the SWIG files; for this we require `numpy.i`:\n```bash\ncurl \"https://raw.githubusercontent.com/numpy/numpy/master/tools/swig/numpy.i\" \u003e BRImage/clib/numpy.i\n```\nThen we generate the `.py` and `.cxx` files with\n```bash\nswig -c++ -python -py3 BRImage/clib/algorithms.i\n```\nThe next stage can be done in a few different ways:\n\n- Isolated `build` directory\n\nBuild the project with the `--target` pip flag, to prevent it from being installed into the environment:\n```bash\npip install --target build .\n```\nalternatively, use the develop mode\n```\npip install -e .\n```\n\n- Install dependencies and build inplace:\n\nInstall the required modules with\n```bash\npip install -r requirements.txt\n```\nThen to only build the external C++ modules, use\n```bash\npython setup.py build_ext --inplace\n```\nRun with\n```bash\npython BRImage\n```\n\n## Changelog \u003ca name=\"toc-sub-tag-6\"\u003e\u003c/a\u003e\n\n- 0.2.2: Fixed segfault related bugs; cleaned code and implemented random walk for video feeds.\n- 0.2.1: Finished the video input feeds, and implementation for the frequency modulation part of video glitches. No CLI options for this available yet.\n- 0.2.0: Major refactor, favouring Feed derived classes as abstraction for image input.\n- 0.1.11: Staged some video I/O wrappers.\n- 0.1.10: Introduced `numdevs` contrasting parameter in frequency modulation.\n- 0.1.9: Updated CLI for all algorithms.\n- 0.1.8: RGB support added for random walk.\n- 0.1.7: Added random walk algorithm (greyscale only).\n- 0.1.6: Changed home-baked to SWIG wrapper.\n- 0.1.5: Home-baked C++ backend for the frequency modulation algorithm.\n\n---\n\nUses [ffmeg](https://github.com/kkroening/ffmpeg-python) for Video I/O, [pillow](https://github.com/python-pillow/Pillow) for Image I/O, [numpy](https://github.com/numpy/numpy) as the workhorse and [black](https://github.com/psf/black) for formatting.\n\n---\n\n\nTodo:\n\n- phase damping option on frequency modulation\n- seed points for random walk","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffjebaker%2Fbrimage","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffjebaker%2Fbrimage","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffjebaker%2Fbrimage/lists"}