Nondestructive thickness measurement of thin films on microstructures