Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix OnDiskBitmap pixel_shader #41

Merged
merged 3 commits into from
Jul 12, 2021
Merged

fix OnDiskBitmap pixel_shader #41

merged 3 commits into from
Jul 12, 2021

Conversation

FoamyGuy
Copy link
Contributor

These changes are needed to support the new behavior of OnDiskBitmap from this PR: adafruit/circuitpython#4823

Without these changes it causes IconAnimated and IconWidget to not be able to show the icons properly if they have on_disk=True parameter.

Copy link
Contributor

@lesamouraipourpre lesamouraipourpre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested on PyPortal with 6.3.0 and 7.0.0-alpha.4 and it works correctly.

tile_grid = TileGrid(image, pixel_shader=ColorConverter())
tile_grid = TileGrid(
image, pixel_shader=getattr(image, "pixel_shader", ColorConverter())
)
else:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding the following comment after the tile_grid = ... line

            # TODO: Once CP6 is no longer supported replace the above line with below.
            # tile_grid = TileGrid(image, pixel_shader=image.pixel_shader)

Copy link
Member

@tannewt tannewt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@tannewt tannewt merged commit fda9020 into adafruit:main Jul 12, 2021
adafruit-adabot added a commit to adafruit/Adafruit_CircuitPython_Bundle that referenced this pull request Jul 23, 2021
Updating https://github.com/adafruit/Adafruit_CircuitPython_CircuitPlayground to 4.4.1 from 4.4.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_CircuitPlayground#107 from adafruit/remove-gamepad-from-mock-imports

Updating https://github.com/adafruit/Adafruit_CircuitPython_EPD to 2.9.5 from 2.9.4:
  > Merge pull request adafruit/Adafruit_CircuitPython_EPD#51 from icegoat9/master

Updating https://github.com/adafruit/Adafruit_CircuitPython_MONSTERM4SK to 0.2.0 from 0.1.4:
  > Merge pull request adafruit/Adafruit_CircuitPython_MONSTERM4SK#8 from lesamouraipourpre/max-size

Updating https://github.com/adafruit/Adafruit_CircuitPython_SSD1325 to 1.3.0 from 1.2.5:
  > Merge pull request adafruit/Adafruit_CircuitPython_SSD1325#11 from lesamouraipourpre/max-size

Updating https://github.com/adafruit/Adafruit_CircuitPython_ST7735R to 1.5.0 from 1.4.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_ST7735R#25 from lesamouraipourpre/max-size

Updating https://github.com/adafruit/Adafruit_CircuitPython_AdafruitIO to 5.5.0 from 5.4.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_AdafruitIO#78 from ryanplusplus/patch-1

Updating https://github.com/adafruit/Adafruit_CircuitPython_DisplayIO_Layout to 1.10.1 from 1.10.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_DisplayIO_Layout#41 from FoamyGuy/fix_odb

Updating https://github.com/adafruit/Adafruit_CircuitPython_PortalBase to 1.9.1 from 1.9.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_PortalBase#44 from lesamouraipourpre/ondiskbitmap-changes

Updating https://github.com/adafruit/Adafruit_CircuitPython_PYOA to 2.4.0 from 2.3.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_PYOA#24 from lesamouraipourpre/ondiskbitmap-changes

Updating https://github.com/adafruit/Adafruit_CircuitPython_Requests to 1.10.0 from 1.9.9:
  > Merge pull request adafruit/Adafruit_CircuitPython_Requests#77 from mogenson/redirect-support
  > Moved default branch to main
  > Moved CI to Python 3.7
  > Added help text and problem matcher
  > Added pull request template

Updating https://github.com/adafruit/Adafruit_CircuitPython_Slideshow to 1.6.0 from 1.5.7:
  > Merge pull request adafruit/Adafruit_CircuitPython_Slideshow#36 from lesamouraipourpre/ondiskbitmap-changes
  > Moved default branch to main
  > Moved CI to Python 3.7
  > Added help text and problem matcher
  > Added pull request template
  > "Increase duplicate code check threshold "

Updating https://github.com/adafruit/Adafruit_CircuitPython_T to 0.9.2 from 0.9.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_T#1 from adafruit/fix-no-monotonic-ns

Updating https://github.com/adafruit/Adafruit_CircuitPython_Bundle/circuitpython_library_list.md to NA from NA:
  > Added the following libraries: Adafruit_CircuitPython_Ticks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants