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

Could .show() be used on a 'render' thread/process #320

Open
timkoers opened this issue Sep 4, 2018 · 1 comment
Open

Could .show() be used on a 'render' thread/process #320

timkoers opened this issue Sep 4, 2018 · 1 comment

Comments

@timkoers
Copy link

timkoers commented Sep 4, 2018

I am trying to run the .show() function from a different process to make the tcp server continue to process streaming data.

Is there any way you could think of that I could render the WS2812 and put new data in at "the same time."?
Ofcourse with locking the strip object when showing or changing data.

@timkoers timkoers changed the title Is it multiprocess safe? Could .show() be used on a 'render' thread/process Sep 4, 2018
@jgarff
Copy link
Owner

jgarff commented Sep 7, 2018

The library is not thread safe. Since the locking mechanism is really specific to the application and its needs, it's left to the user to implement. Unfortunately, double buffering is also something that this library doesn't do, but this seems like something that could be added in the core library to avoid copying. Maybe something along the lines of passing a array pointer to the show command for processing.

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

No branches or pull requests

2 participants