Hi all. As I have comented in another thread, I am programming a simple photo editor that supports zooming, rotation and selection of rectangular parts of the image to cut or paint them. Well, by now I have the original image in a QImage and I paint it with qPainter (drawImage) and all goes ok. When I change the zoom of the image what I do is simply call the method "scale" of qpainter and draw the image. The problem doing it in this way is that if the user wants to select a part of the image, the coordenates of the selection are respect the scaled image and if I traspose this coordinates at the original image, could appear some error. I've seen that with simple photo editor programs like Paint of Windows if I zoom the image, I can modifiy the zoomed image and never appear any error. I think that's because when the user modify the scale of the image, the size of the orginal image is modified, not only when the image is painted (as I am making it now). But I think that, If everytime that the user zooms an image, the original image is resized could appear loss of information. So I don't know if there's another way to do it. Anyone could explain how could I solve the problem? Thanks.
Bookmarks