CV_CAP_PROP_BUFFERSIZE when playing movie

I’m sorry if my words are difficult to understand as this is my first post to such a professional form and I’m not a native speaker of English .

I have three questions about CV_CAP_PROP_BUFFERSIZ.
1>Does X.set(CV_CAP_PROP_BUFFERSIZE,n) also work when X is a movie object, not captures from camera?
2> And if it does, could some of the frames be dropped because of the long time delay?
3>Also, if I call X.set(CV_CAP_PROP_BUFFERSIZE,1) in one thread, does it affect to the other thread using VIdeoCapture?

(My detailed situation)
I’m trying to play a movie while recording with OpenCV and this goal was achieved with three threads, timer thread(controlls timing),recording thread and playing thread which are defined as methods in a class object. When I practice all of them, the playing speed of movie is fast enough to realize the original fps. However when I practice just two thread, timer and playing, its fps comes to 0.9 times of the original one. I’m suspecting the cause of this situation is cap.set(CV_CAP_PROP_BUFFERSIZE,1) in recording thread.

changing a property of one instance of VideoCapture has no effect on other instances of VideoCapture.

it shouldn’t matter from which thread the object’s property is changed. if it does, that would be a bug.

I don’t know if VideoCapture is thread-safe. as long as an instance is only used from one thread at a time, all should be good.

VideoCapture of a video file never drops frames. a buffer size has no meaning in this situation. the implementation either decodes on demand, or keeps a small buffer for performance reasons.

Thank you for your answers.
They are very helpful for me.

~
X.set(CV_CAP_PROP_BUFFERSIZE,1) improved the performance of playing thread, and it realized the original fps!

Thank you.

I have one more question.

When a buffer is tried to get by opencv? Soon after the room’s generation by “read” or when CPU is free?

I don’t know.

if you need to know, you would have to investigate the code that interfaces with FFMPEG:

I see.
Thank you very much!