Closed yiyuezhuo closed 4 years ago
I had a hard time to debug this and figure it out that it's due to avpicture deprecated problem (also see SO quesion). I compared VideoIO with PyAV, which returned the correct result, and finally got a solution. Maybe I will create a pull request to fix this, but it's not that minor though.
A PR would be very welcome!
I found that
read
generates some "noise points" in the right region. More weirdly, it gives different results on Windows and Linux.ffmpeg result (reference, both on Windows and Linux):
VideoIO on linux:![image](https://user-images.githubusercontent.com/12798270/84290555-6491f880-ab76-11ea-9cca-ced4aa8556be.png)
VideoIO on Windows:![image](https://user-images.githubusercontent.com/12798270/84290578-707dba80-ab76-11ea-8ec5-2e2ccc465d69.png)
Test video: https://drive.google.com/file/d/1ThCzT_1PMkspxAktCY1bkvFFsG_IsNHc/view?usp=sharing
ffmpeg command:
VideoIO script:
Do I need some extra options to avoid this? Or is there a "standard" format to make VideoIO work without such problems (The test video self is generated by ffmpeg with default parameter.)?