QGraphicsView which shows clipped left image and clipped right image at the same place based on movable vertical line.
This widget is suitable for displaying images before and after processing.
The QGraphicsScene in this view is resized based on the size of the image that was added, according to the specific purpose of this script.
- PyQt5 >= 5.14
- SplittedImageView - class in the imageView.py
- setFilenameToLeft(filename) - set the image file on the left
- setFilenameToRight(filename) - set the image file on the right
- removeItemOnTheLeft() - remove the image on the left if it exists
- removeItemOnTheRight() - remove the image on the right if it exists
Refer to the main.py to understand how to use it.
Set the image files for each part (left and right) and observe what happens when you move the vertical line left and right.
PyQt.Splitted.Graphics.View.Example.2023-11-20.09-17-18.mp4
Left part is a (1).png, right part is a (2).png. These files are in the repo, so you can use them to test this script, right away.