1

I'm struggling to understand how the colors work in ImPlot.

Here, I'm plotting bars in groups of 3.

static const char* labels[] = {"X", "Y", "Z"};
if (ImPlot::BeginPlot("Sensor activity"))
{
    ImPlot::PlotBarGroups(labels, &(barData[0]), 3, numGroups, 1.0f, 0, 0);
    ImPlot::EndPlot();
}

I would like the X, Y, and Z bars to be plotted in Red, Green and Blue respectively. How would I do that?

Rocketmagnet
  • 5,656
  • 8
  • 36
  • 47

0 Answers0