-
Notifications
You must be signed in to change notification settings - Fork 5.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add RTSP features to cudacodec::VideoReader #3247
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me in general, besides force
flag in init. I propose to remove it at all.
Tested on Ubuntu 18.04 with CUDA 10.2, NVIDIA Video Codec SDK 11.1.
No you are correct. Force is not used and can be removed because it could be dangerous to have the facility to initialize a frameque object twice. It may be better if required in the future to have a specific reinitialization routine which performs safety checks, if the size of the que needs to be altered mid-decode. |
…t is for, which should be left up to the documentation.
…fe if another thread and/or object is using it.
9a2ad10
to
95fd837
Compare
…eature Add RTSP features to cudacodec::VideoReader * Add live video source enhancements, e.g. rtsp from ip camera's Add error logs. * Fix type. * Change badly named flag. * Alter live source flag everywhere to indicate what it does not what it is for, which should be left up to the documentation. * Prevent frame que object from being reinitialized which could be unsafe if another thread and/or object is using it.
Add the below two features to
cudacodec::VideoReader
to help when streaming from live sources.nextFrame()/grab()
is less than the source FPS. Although this is something which a user would eventually accomodate for themselves (by reading at the appropriate rate and choosing which packets to discard) it would be a useful for this to be "automatic" until they have implemented that functionality.Testing - currently the additional tests only check that the new parameters have been set inside
VideoReader
and do not verify the functionality of (1) and (2). This is because testing (1) requires a new test video file (I am not sure if that is overkill for this small feature) and testing (2) require a live RTSP source. I can easily include an extra test file if required but I am not sure how I can simulate an live RTSP source?Patch to opencv_extra has the same branch name.