{"id":21150806,"url":"https://github.com/cedargrovestudios/circuitpython_palettefader","last_synced_at":"2026-02-27T23:15:56.368Z","repository":{"id":58834560,"uuid":"533529381","full_name":"CedarGroveStudios/CircuitPython_PaletteFader","owner":"CedarGroveStudios","description":"A CircuitPython color palette and list brightness setter and normalizer tool.","archived":false,"fork":false,"pushed_at":"2023-11-02T03:19:09.000Z","size":2134,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-27T02:43:30.895Z","etag":null,"topics":["circuitpython","circuitpython-community-bundle","palette-brightness"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CedarGroveStudios.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2022-09-06T23:07:58.000Z","updated_at":"2024-10-14T14:12:07.000Z","dependencies_parsed_at":"2023-01-30T04:31:04.842Z","dependency_job_id":"41d390f5-e3b2-446a-ae11-192f1e62df80","html_url":"https://github.com/CedarGroveStudios/CircuitPython_PaletteFader","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CedarGroveStudios%2FCircuitPython_PaletteFader","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CedarGroveStudios%2FCircuitPython_PaletteFader/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CedarGroveStudios%2FCircuitPython_PaletteFader/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CedarGroveStudios%2FCircuitPython_PaletteFader/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CedarGroveStudios","download_url":"https://codeload.github.com/CedarGroveStudios/CircuitPython_PaletteFader/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248706076,"owners_count":21148636,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["circuitpython","circuitpython-community-bundle","palette-brightness"],"created_at":"2024-11-20T10:08:26.910Z","updated_at":"2026-02-27T23:15:51.336Z","avatar_url":"https://github.com/CedarGroveStudios.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Introduction\n============\n\n\n\n.. image:: https://img.shields.io/discord/327254708534116352.svg\n    :target: https://adafru.it/discord\n    :alt: Discord\n\n\n.. image:: https://github.com/CedarGroveStudios/CircuitPython_PaletteFader/workflows/Build%20CI/badge.svg\n    :target: https://github.com/CedarGroveStudios/CircuitPython_PaletteFader/actions\n    :alt: Build Status\n\n\n.. image:: https://img.shields.io/badge/code%20style-black-000000.svg\n    :target: https://github.com/psf/black\n    :alt: Code Style: Black\n\n*A CircuitPython color palette and list brightness setter and normalizer tool.*\n\nPaletteFader is a CircuitPython class for brightness-adjusting color lists and displayio palettes. Normalization (scaling all palette values relative to the brightest palette color) is optionally applied to the palette prior to brightness and gamma adjustments. Transparency index values are preserved and associated with the adjusted palette. Creates an adjusted displayio color palette object (``displayio.Palette``) property that can also be read as a color list.\n\nTwo versions of PaletteFader are contained in the ``cedargrove_palettefader`` package folder, ``palettefader`` and ``palettefader_ulab``. The faster of the two is ``palettefader_ulab``, requiring CircuitPython with ``ulab`` as a built-in module. Certain CircuitPython distributions and versions may not support ``ulab``; check your specific implementation. For example, ``ulab`` is not included in MatrixPortal distributions after CircuitPython version 7.3.2. A list of built-in modules are listed for each distribution on the https://circuitpython.org/downloads page.\n\n\nDependencies\n=============\nThis driver depends on:\n\n* `Adafruit CircuitPython \u003chttps://github.com/adafruit/circuitpython\u003e`_\n\nPlease ensure all dependencies are available on the CircuitPython filesystem.\nThis is easily achieved by downloading\n`the Adafruit library and driver bundle \u003chttps://circuitpython.org/libraries\u003e`_\nor individual libraries can be installed using\n`circup \u003chttps://github.com/adafruit/circup\u003e`_.\n\nInstalling to a Connected CircuitPython Device with Circup\n==========================================================\n\nMake sure that you have ``circup`` installed in your Python environment.\nInstall it with the following command if necessary:\n\n.. code-block:: shell\n\n    pip3 install circup\n\nWith ``circup`` installed and your CircuitPython device connected use the\nfollowing command to install:\n\n.. code-block:: shell\n\n    circup install cedargrove_palettefader\n\nOr the following command to update an existing version:\n\n.. code-block:: shell\n\n    circup update\n\nUsage Example\n=============\n\n.. code-block:: py\n\n    # For CircuitPython distributions without ulab (such as the MatrixPortal)\n    from cedargrove_palettefader.palettefader import PaletteFader\n\n    # Instantiate PaletteFader\n    faded_object = PaletteFader(source_palette=object_palette, brightness=0.5)\n\n.. code-block:: py\n\n    # For CircuitPython distributions with ulab\n    from cedargrove_palettefader.palettefader_ulab import PaletteFader\n\n    # Instantiate PaletteFader\n    faded_object = PaletteFader(source_palette=object_palette, brightness=0.5)\n\n``palettefader_simpletest.py`` and other examples can be found in the ``examples`` folder.\n\nDocumentation\n=============\n`PaletteFader API Class Description \u003chttps://github.com/CedarGroveStudios/CircuitPython_PaletteFader/blob/main/media/pseudo_rtd_cedargrove_palettefader.pdf\u003e`_\n\n.. image:: https://github.com/CedarGroveStudios/CircuitPython_PaletteFader/blob/main/media/PaletteFader_Class_description.jpeg\n\n.. image:: https://github.com/CedarGroveStudios/CircuitPython_PaletteFader/blob/main/media/PaletteFader_Class_internals.jpeg\n\n\nContributing\n============\n\nContributions are welcome! Please read our `Code of Conduct\n\u003chttps://github.com/CedarGroveStudios/Cedargrove_CircuitPython_PaletteFader/blob/HEAD/CODE_OF_CONDUCT.md\u003e`_\nbefore contributing to help this project stay welcoming to everyone.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcedargrovestudios%2Fcircuitpython_palettefader","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcedargrovestudios%2Fcircuitpython_palettefader","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcedargrovestudios%2Fcircuitpython_palettefader/lists"}