libpng boilerplate