make bits per pixel configurable