Destroy cuda context in encoder destructor

This commit is contained in:
Patrick Nicolas
2025-05-22 17:55:35 +02:00
parent d6fb4d6f36
commit a33fae434e
+2
View File
@@ -310,6 +310,8 @@ video_encoder_nvenc::~video_encoder_nvenc()
{
if (session_handle)
fn.nvEncDestroyEncoder(session_handle);
if (cuda)
cuda_fn->cuCtxDestroy(cuda);
}
std::pair<bool, vk::Semaphore> video_encoder_nvenc::present_image(vk::Image y_cbcr, vk::raii::CommandBuffer & cmd_buf, uint8_t slot, uint64_t)