Is there a software I could use for this? Currently I'm using guvcview but it doesn't have the functionality afaik.
There is a tool called motion.
sudo apt-get install motion
when installed you could possibly run it with
It saves lots of jpg files in your personal folder, when there is motion detected in front of your webcam.
You can configure motion under /etc/motion/motion.conf to save an mpeg movie of the movement, instead or in addition to the jpegs...
sudo gedit /etc/motion/motion.conf
Here is a link to the Config Options, just in case: http://www.lavrsen.dk/foswiki/bin/view/Motion/ConfigFileOptions