Closed antkir closed 5 months ago
Sorry, I meant to get to this earlier. Is 32 really required? Does any number >16 and <32 work? I'm just slightly concerned that NVDEC will allocate all those frames up front, and 32 is going to start taking a lot of memory, esp. at 4k resolutions.
The maximum surface index I saw in logs was 24, but I only ever tested a single YouTube video playing for no more than 5 minutes at a time and this number seemed to have a tendency to increase a bit while the video was playing, so I decided 32 would be a safer bet.
Ok, I'll merge this in as-is but we may have to revisit it at some point.
Without this change, nvEndpicture fails in cv->cuvidDecodePicture(nvCtx->decoder, picParams) when Chromium's VaapiVideoDecoder is used.