QSV: refactoing.
QSV: DecodeHeader