Painter path exceeds +/-32767 pixels.



  • Hi all!
    I collided with problem, qt showing this message: "Painter path exceeds +/-32767 pixels". Example code of my window:
    class OpenGLWindow : public QWindow, protected QOpenGLFunctions {...
    What is it? How I can resolve this problem or listerning about it?


  • Lifetime Qt Champion

    Hi,

    Your sample code doesn't tell much. Can you include the implementation ?



  • @SGaist
    Next I use for drawing QPainter.
    I don't know what the code cause this problem.

    void OpenGLWindow::render()
    {
    if (!m_device) {
    m_device = new QOpenGLPaintDevice;
    m_device->setSize(size());

    painter = new QPainter(m_device);
    GraphicComponent::Init(painter);
    painter->setWindow(QRect(QPoint(-5, -10), size()));
    

    }
    glClear(GL_COLOR_BUFFER_BIT);
    render(painter);
    }



  • I found solve. The message showing when we drawing pixel which leaving border of +/-32767 pixels. In my cause it was uninitilization variable.


  • Lifetime Qt Champion

    Good ! What uninitialized variable was it ?

    Since you have it working now, please mark the thread as solved using the "Topic Tool" button so that other forum users may know a solution has been found :)


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.