A fairly simplistic method would be to take the file system's reported files sizes, dates (as integer values), and file names in a given directory and calculate a checksum you could then associate with that directory. You would still need to perform this calculation on all of the directories using file system data but you wouldn't have to go in depth (opening files to check for differences) unless a checksum reported a difference.
For tracking specific changes at the file level you would store checksums based on individual file attributes, and of the course the presence of or absence of files and subdirectories since the last scan.
This wouldn't necessarily guarantee that changes have not occurred as there are file system utilities for altering all manner of attributes though it would be a good first step for a basic scan.
You may find the source code for
fswatch helpful.