[png] do not generate png header when not needed