MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / rebuildHistoryImage

Method rebuildHistoryImage

app/src/UI/Widgets/Waterfall.cpp:560–569  ·  view source on GitHub ↗

* @brief Allocates the spectrogram image based on FFT size and history depth. */

Source from the content-addressed store, hash-verified

558 * @brief Allocates the spectrogram image based on FFT size and history depth.
559 */
560void Widgets::Waterfall::rebuildHistoryImage()
561{
562 const int width = qMax(1, m_size / 2);
563 const int height = qMax(1, m_historySize);
564 m_image = QImage(width, height, QImage::Format_RGB32);
565 m_image.fill(sampleColorMap(m_colorMap, 0.0));
566 m_topRow = 0;
567 m_writeRow = 0;
568 m_filledOnce = false;
569}
570
571/**
572 * @brief Writes a new spectrum row into the ring: the newest row's physical position is

Callers

nothing calls this directly

Calls 1

fillMethod · 0.45

Tested by

no test coverage detected