When I try to build multiple QCP controls and open opengl rendering, an error will be reported. Has anyone encountered this problem? Can you give me some solutions?

QPainter::begin(): QOpenGLPaintDevice's context needs to be current
QPainter::begin(): Returned false
QPainter::setRenderHint: Painter must be active to set rendering hints
void __cdecl QCPLayer::drawToPaintBuffer(void) paint buffer returned inactive painter