Skip to main content
JHyka.1
Associate
June 20, 2020
Question

Circular buffer support for Dynamic Bitmap

  • June 20, 2020
  • 2 replies
  • 838 views

Applications such as a spectrum “waterfall�? display involve a moving image where old rasterline data is pushed down for a new line at the top. I tried direct framebuffer access and other approaches without success. (Too many data movements, too slow)

I want to try a circular buffer approach to minimize data movement, with the challenge of then having to split image refresh into two portions to track the moving location of the image in the buffer and to manage the wraparound.

is it feasible to create a custom Widget that can manipulate Buffer pointers ‘on the fly’ (ie within the same frame refresh) when redrawing a dynamic bitmap?

This topic has been closed for replies.

2 replies

JHyka.1
JHyka.1Author
Associate
June 21, 2020

Solved!

the ScrollableContainer with a dynamic bitmap twice the size for spectrum data proved to be a perfect solution. Not quite a circular buffer solution but almost as efficient and out-of-the-box. Very smooth scrolling with very little code.

Romain DIELEMAN
ST Employee
June 22, 2020

not 100% sure I understood what you tried to do but glad it works :grinning_face_with_sweat: