Implement palette in decoder