Added palette support