Limitation of Image Dimension
-
Is there some limitation of image dimensions? I have the following code:
m_pImage = new QImage(m_pcData, nWidth, nHeight, QImage::Format_Grayscale8);
pixmap = QPixmap::fromImage(*m_pImage);Each time I try to load an image where the width is not a multiple of 4 fromImage blows up.
-
Is there some limitation of image dimensions? I have the following code:
m_pImage = new QImage(m_pcData, nWidth, nHeight, QImage::Format_Grayscale8);
pixmap = QPixmap::fromImage(*m_pImage);Each time I try to load an image where the width is not a multiple of 4 fromImage blows up.
-
Is there some limitation of image dimensions? I have the following code:
m_pImage = new QImage(m_pcData, nWidth, nHeight, QImage::Format_Grayscale8);
pixmap = QPixmap::fromImage(*m_pImage);Each time I try to load an image where the width is not a multiple of 4 fromImage blows up.
There is a limitation but it has nothing to do with your code.
Here it is clearly stated:
Constructs an image with the given width, height and format, that uses an existing read-only memory buffer, data. The width and height must be specified in pixels, data must be 32-bit aligned, and each scanline of data in the image must also be 32-bit aligned.