Thread: mplayer vdpau
View Single Post
Old 09-29-09, 12:02 PM   #1207
Registered User
Join Date: Sep 2009
Posts: 45
Default Re: mplayer vdpau

Originally Posted by Stephen Warren View Post
Yes, in some cases, it would be harder to implement. Even if that weren't the case, I still believe that philosophically, the presentation queue internals is the wrong place to make this decision. The application has much better knowledge (e.g. perhaps 3:2 pulldown information) and is the only place that correct frame-dropping decisions can be made.
I don't see any philosophical problem. The presentation queue already has to decide during which and how many display refreshes a frame is shown. The obvious answer is to show it for a refresh if the time of that refresh is later than the earliest presentation timestamp of the frame, and there is no later frame which would also fulfill this condition. This can result in showing the frame for 0, 1, 2 or more refreshes. What reason is there to special-case "0" and disallow that in particular?
That would be a case of the application using the presentation queue API incorrectly.
"Incorrectly"? How? The example only required queuing 8 frames of 50 FPS content. So what's incorrect about that? Placing 8 frames in the queue? Or using the queue to play 50 FPS content? What assumptions exactly are you making if you don't consider that to be "correct" usage? How could the application handle this correctly without having extra information about the display refresh rate?
I don't see why not. Obviously the application needs to be aware which display device is being used so as to operate correctly - i.e. use timing information from the correct display.
Is there an obvious way for the application to be aware of that? In the simplest case the application opens a window, lets the window manager place in wherever (the user could move it later) and then uses the VDPAU API. How can I be sure I get the right values? If VDPAU_NVIDIA_SYNC_DISPLAY_DEVICE actually changes the behavior of the VDPAU implementation how can the application be aware of the changes without being explicitly aware of that particular environment variable and parsing it?
uau is offline   Reply With Quote