Skip to content

Add pixelbuf for accelerating NeoPixel operations #943

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

Merged
merged 9 commits into from
Jan 22, 2019

Conversation

rhooper
Copy link

@rhooper rhooper commented Jun 18, 2018

This PR adds a PixelBuf class that accelerates byteorder and brightness operations and will have an associated PR for https://github.com/adafruit/Adafruit_CircuitPython_NeoPixel
Relates to issue #884

Further work is needed to:

  • disable for builds it doesn't fit into or make sense for
  • add support for dotstars
  • optimize it further (feedback please!)

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.

Thanks for taking this on! It'll be good to get it sped up. I think this can be simplified by keeping the API smaller and only working on a pixel basis, no raw byte stuff.

@tannewt
Copy link
Member

tannewt commented Oct 1, 2018

@rhooper Are you waiting on me for this? It'd be awesome to get it in 4.0.0. Thanks!

@rhooper
Copy link
Author

rhooper commented Oct 4, 2018

No, i'm not waiting on you, i'm waiting on my time to free up.
I did start on the classes for RGBLED and a Pure python pixelbuf
https://github.com/rhooper/Adafruit_CircuitPython_RGBLED
from which we can make NeoPixel and Dotstar (and others) inherit.

@rhooper
Copy link
Author

rhooper commented Oct 8, 2018

Ideally to wrap this up, we'd pick up and use:

As well as finishing up the RGBLED so we have a fallback for hardware that doesn't fit the pixelbuf class:

The RGBLED class might be better renamed to Pixelbuf. It is needed to be backwards compatible when we do a hard swap of NeoPixel and Dotstar (and others) to use Pixelbuf.

@tannewt
Copy link
Member

tannewt commented Jan 7, 2019

Please let me know when this needs another look. Thanks!

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.

Just a few questions and then it should be good to go. I think we should follow up with making the subclassing of PixelBuf work. The previous errors may have to do with the dunder methods.

tannewt
tannewt previously approved these changes Jan 22, 2019
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.

Looks good! Thank you for all of your hard work on this! I'll update the translations for you and then merge.

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 so much for this!

@tannewt tannewt merged commit cef6e08 into adafruit:master Jan 22, 2019
@rhooper rhooper deleted the pixelbuf branch January 10, 2020 20:30
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.

2 participants