QSV frame priority bits are not being marked correctly; their priorities
are always marked either low or disposable, whereas I-frames should be
marked as highest (3), P-frames should be marked as high (2), and other
frames should be marked as either low or disposable. This helps ensure
that the correct frames are dropped when frames need to be dropped.
When using per-encoder rescaling, QSV would overwrite the current
encoder scale value in the get_video_info callback with the base video
width/height instead of using the current encoder width/height.
Currently, multiple QSV encoders cannot be active at the same time
(otherwise it will crash). This is a temporary solution to prevent
crashes from occurring when more than one QSV encoder tries to start up
at the same time.
Additionally, in the future there should be a way for encoders to be
able to communicate with the front-end when an error such as this
occurs.
When using QSV is used on a windows 7 machine with a dedicated card, you
have to fake a monitor connection to your Intel graphics to be able to
use QSV. If you do not, the initialization will fail with an error.
The error for that situation is not handled properly, and a variable
will be used while null. Instead, the function should safely return
after that error is received.
Also, do not call ClearData in the destructor unless QSV has been
properly initialized (if m_pmfxENC is null).