hevc: optimize transform_skip
hevc: make dequant a templated function