cv::cudacodec::VideoWriter not working with only NVCUVID

You are correct–I was using the OpenCV’s commit 5 days ago and it doesnt show the info, and I just did another git pull, I can see the output you mentioned now:

-- Found NVCUVID: /usr/lib/x86_64-linux-gnu/libnvcuvid.so
-- NVCUVENC: Library not found, WITH_NVCUVENC requires the Nvidia encoding shared library libnvidia-encode.so from the driver installation or the location of the stub library to be manually set with CUDA_nvidia-encode_LIBRARY i.e. CUDA_nvidia-encode_LIBRARY=/home/user/Video_Codec_SDK_X.X.X/Lib/linux/stubs/x86_64/libnvidia-encode.so
-- CUDA detected: 12.3
-- CUDA: NVCC target flags -gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_52,code=sm_52;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_61,code=sm_61;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_75,code=sm_75;-gencode;arch=compute_80,code=sm_80;-gencode;arch=compute_86,code=sm_86;-gencode;arch=compute_89,code=sm_89;-gencode;arch=compute_90,code=sm_90;-D_FORCE_INLINES;-gencode;arch=compute_90,code=compute_90

Just added the CUDA_nvidia-encode_LIBRARY as prompted, compiling OpenCV again now. Will come back when the compilation is done.