Hardware Device Error Handling¶
For implementations that accelerate decoding, encoding, and video processing through a hardware device, API functions may return errors or warnings if the hardware device encounters errors. See the Hardware Device Errors and Warnings table for detailed information about the errors and warnings.
Status |
Description |
---|---|
Hardware device returned unexpected errors. oneVPL was unable to restore operation. |
|
Hardware device was lost due to system lock or shutdown. |
|
The hardware does not fully support the specified configuration. The encoding, decoding, or video processing operation may be partially accelerated. |
|
Hardware device is currently busy. |
oneVPL Query, QueryIOSurf, and Init functions return
mfxStatus::MFX_WRN_PARTIAL_ACCELERATION
to indicate that the encoding,
decoding, or video processing operation can be partially hardware accelerated or
not hardware accelerated at all. The application can ignore this warning and
proceed with the operation. (Note that oneVPL functions may return
errors or other warnings overwriting
mfxStatus::MFX_WRN_PARTIAL_ACCELERATION
, as it is a lower priority warning.)
oneVPL functions return mfxStatus::MFX_WRN_DEVICE_BUSY
to indicate that the
hardware device is busy and unable to take commands at this time. Resume the
operation by waiting for a few milliseconds and resubmitting the request.
The following example shows the decoding pseudo-code:
1 2 3 4 5 6 | mfxStatus sts=MFX_ERR_NONE;
for (;;) {
// do something
sts=MFXVideoDECODE_DecodeFrameAsync(session, bitstream, surface_work, &surface_disp, &syncp);
if (sts == MFX_WRN_DEVICE_BUSY) sleep(5);
}
|
The same procedure applies to encoding and video processing.
oneVPL functions return mfxStatus::MFX_ERR_DEVICE_LOST
or
mfxStatus::MFX_ERR_DEVICE_FAILED
to indicate that there is a complete
failure in hardware acceleration. The application must close and reinitialize
the oneVPL function class. If the application has provided a hardware acceleration
device handle to oneVPL, the application must reset the device.