mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-16 21:14:44 +00:00
nvenc: Give more details about errors
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1472>
This commit is contained in:
parent
b7ded51382
commit
3549d59725
2 changed files with 9 additions and 1 deletions
|
@ -1847,7 +1847,8 @@ gst_nv_base_enc_set_format (GstVideoEncoder * enc, GstVideoCodecState * state)
|
|||
|
||||
if (nv_ret != NV_ENC_SUCCESS) {
|
||||
GST_ELEMENT_ERROR (nvenc, LIBRARY, SETTINGS, (NULL),
|
||||
("Failed to %sinit encoder: %d", reconfigure ? "re" : "", nv_ret));
|
||||
("Failed to %sinit encoder: %d- %s", reconfigure ? "re" : "", nv_ret,
|
||||
NvEncGetLastErrorString (nvenc->encoder)));
|
||||
NvEncDestroyEncoder (nvenc->encoder);
|
||||
nvenc->encoder = NULL;
|
||||
return FALSE;
|
||||
|
|
|
@ -79,6 +79,13 @@ NvEncDestroyEncoder (void *encoder)
|
|||
return nvenc_api.nvEncDestroyEncoder (encoder);
|
||||
}
|
||||
|
||||
const char *NVENCAPI
|
||||
NvEncGetLastErrorString (void *encoder)
|
||||
{
|
||||
g_assert (nvenc_api.nvEncGetLastErrorString != NULL);
|
||||
return nvenc_api.nvEncGetLastErrorString (encoder);
|
||||
}
|
||||
|
||||
NVENCSTATUS NVENCAPI
|
||||
NvEncGetEncodeGUIDs (void *encoder, GUID * array, uint32_t array_size,
|
||||
uint32_t * count)
|
||||
|
|
Loading…
Reference in a new issue