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
Drawing a pixel buffer to the screen #210
Comments
have to discuss with @AlexHarker how we do this in a cross -graphics api way. Here is how you can do it with nanovg:
|
Thanks for the code, works a treat! Certainly curious as to a cross platform method, however :) |
Your pixel buffer is in memory, correct? I think we could add a loader for pixel buffers, but be good to figure out how that behaviour should work exactly. |
Yes, I'm generating it each frame. Before I moved to iPlug2 I was just using raw GL - writing the pixels to a texture every frame and drawing it to a quad |
I have a simple RGBA pixel buffer that I want to render to my UI every frame. My first thought was to create a texture/bitmap, write the pixels to it every frame and call
IGraphics.DrawBitmap
. However I can't work out how to create a bitmap. After a bit of digging I found thatIGraphicsNanoVG.CreateAPIBitmap
exists but it is not exposed, and even then theIBitmap
andAPIBitmap
don't seem to offer a way of setting pixel data. Any suggestions on how to do this?The text was updated successfully, but these errors were encountered: