This is one of applications of hand tracking module.
To run:
python3 virtual_mouse.py
The project uses the Autopy library, in addition to MediaPipe and OpenCV. Using the hand tracking module and autopy, one can guide the mouse pointer and click.
When the index finger is up the cursor moves along with it and when the index finger and middle finger are pointed up, a click event is performed.