[libng16] Added palette-index checking while writing.

Relocated palette-index checking function from pngrutil.c to pngtrans.c
10 files changed