avfilter/avf_showcqt: optimize gamma calculation