When I decode a frame with NVDEC I want to send it to the FRUC library and interpolate with the previously sent one. Do I have to register it each time I get the decoded frame?
What would be my solution:
- Allocate memory for output frame
- Decode frame
- Register the output and currently decoded and previous frame
- Process
- Copy the result out from the output
- Unregister resources
- Go to 2.
Is the repeated register/unregister cycle OK?
Looking at the NvOFFRUCSample I understand that an option is to:
- Allocate the memory for input frames and output ones
- Register them
- Decode frame and copy it to the registered memory
- Process
- Copy the result out from the output
- Go to 3.
Can I avoid the copies? At least for the input? Just passing the CUdeviceptr of the decoded frame to FRUC?