[vbox-dev] How to access host vertical blanking intervals

Steve Longerbeam slongerbeam at gmail.com
Thu Sep 13 18:30:38 GMT 2018


Hello Klaus,


On 09/13/2018 10:58 AM, Klaus Espenlaub wrote:
> Hello Steve,
>
> this "do what I want" request is tons more effort than what you think.

This wasn't a request that it be implemented, only a general
question as to whether there was a current API for it. :)

> 1. What is "the host display"? By default the VM is shown in a window,
> which can span multiple physical screens.

Ok.

>   Also, what should happen in
> the headless VM case when the screen is accessed using an RDP client?

Ah yes, good point.

> 2. Getting the vsync state is extremely host OS dependent, so it'd need
> a whole machinery for abstracting this enough. Likely this would need to
> bypass Qt and then life gets very hard.

Agreed.

>
> 3. While page flipping is minimizing tearing, it also means that on
> every flip the entire VM screen content will be updated (no easy way to
> figure out what actually changed). This means the screen updating will
> be less efficient than when doing the updates in place.
>
> All of this is fixable. After all we're talking about software. It's a
> cartload of work for very little gain, though.

Thanks for clarifying the difficulties. I don't have the bandwidth or
expertise in all the supported hosts to work on this myself, so chalk
it up as a possible TODO if tearing is indeed observed on page flips
in the future.

Steve

> Just my 2c,
> Klaus
>
> On 03.09.2018 10:26, Michael Thayer wrote:
>> Hello Steve,
>>
>> Nothing at the moment I'm afraid.  It might be something we could
>> consider adding some time (though it would be far from trivial, since we
>> have four supported and additional unofficial host ports to make it work
>> on).  It is also something we might accept a patch for.  One of the
>> relevant code-owners is not available for the next week, so I can't say
>> for sure.
>>
>> Regards
>> Michael
>>
>> 31.08.2018 22:54, Steve Longerbeam wrote:
>>> Hello VBOX developers,
>>>
>>> I recently contributed a patch to in-kernel vboxvideo DRM driver which
>>> adds support for page flip. However the implementation does not
>>> make any attempt to sync page flip with host vertical blanking
>>> interval, so it's possible a DRM page flip will result in tearing
>>> artifacts.
>>>
>>> So is there a call that can be made into the hypervisor that would allow
>>> receiving an event when host display has entered a vblank interval?
>>> Something in the VBOX Main API perhaps?
>>>
>>> Thanks in advance,
>>> Steve--
> _______________________________________________
> vbox-dev mailing list
> vbox-dev at virtualbox.org
> https://www.virtualbox.org/mailman/listinfo/vbox-dev




More information about the vbox-dev mailing list