Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Embed an image inside a widget
I want to visualize an entire image inside a widget (for example inside a label) without losing information. I suppose I will need to do a process of deforming the image so that I can enter it completely or I do not know if Qt already brings something to do this kind of tasks.
What do you mean by without losing information ?
If you mean keep the full image but scaled then QImage::scaled is your friend.
@SGaist Thanks for answering. Maybe I have not explained myself completely well. I have an image with a certain size and I need to embed it in a polygon with four vertex without cropping the image. The entire image must be displayed in the polygon.
Gojir4 last edited by
And what QSize I give to the scaled method if the image I have to insert it in a polygon and not in a rectangle? A trapezium for example. I need to distort the image.