It is a requirement from VA-API specification that the VA context got
from vaCreateContext(), for decoding purposes, binds the supplied set
of VA surfaces. This means that if the set of VA surfaces is to be
changed for the current decode session, then the VA context needs to
be recreated with the new set of VA surfaces.
} else if (new_cip->usage == GST_VAAPI_CONTEXT_USAGE_ENCODE) {
if (context_update_config_encoder (context, &new_cip->config.encoder))
reset_config = TRUE;
+ } else if (new_cip->usage == GST_VAAPI_CONTEXT_USAGE_DECODE) {
+ if (reset_surfaces)
+ reset_config = TRUE;
}
if (reset_surfaces)