Mesoscale patterning of thin films through template-assisted self-assembly