Fix png plugin 2d

fix that plugin for invalid direction (z direction) in 2D is not disabled