TestDisk is a powerful free data recovery program! It was primarily designed to recover lost partitions, repair FAT/NTFS boot sector, NTFS MFT and Ext2/Ext3 superblock and/or make non-booting disks bootable again when these symptoms are caused by faulty software, certain types of viruses or human error (such as accidentally deleting your Partition Table).
PhotoRec is a File Recovery program designed to recover lost files; including video, documents and archives from Hard Disks, CDRom and lost pictures from digital camera memory (thus, its Photo Recovery name). PhotoRec ignores the filesystem and goes after the underlying data, so it can still find files even if your media's filesystem has been severely damaged or re-formatted (overwritten data, of course, can not be recovered).
These details are provided for information only. No information here is legal advice and should not be used as such.