vertical sync

these days, I am compelting vertical syncwindows

https://msdn.microsoft.com/zh-cn/library/windows/desktop/bb172585(v=vs.85).aspxless

 

D3DPRESENT_INTERVAL_DEFAULT

This is nearly equivalent to D3DPRESENT_INTERVAL_ONE. See remarks.ide

D3DPRESENT_INTERVAL_ONE

The driver will wait for the vertical retrace period (the runtime will "beam follow" to prevent tearing).Present operations will not be affected more frequently than the screen refresh; the runtime will complete at most one Present operation per adapter refresh period. This is equivalent to using D3DSWAPEFFECT_COPYVSYNC in DirectX 8.1. This option is always available for both windowed and full-screen swap chains. See remarks.ui

D3DPRESENT_INTERVAL_IMMEDIATE

The runtime updates the window client area immediately and might do so more than once during the adapter refresh period. This is equivalent to using D3DSWAPEFFECT_COPY in DirectX 8. Presentoperations might be affected immediately. This option is always available for both windowed and full-screen swap chains. See remarks.3d

there are samples in dx sdkorm

vsync on ---D3DPRESENT_INTERVAL_DEFAULThtm

vsync off ---D3DPRESENT_INTERVAL_IMMEDIATEip

deviceSettings.d3d10.SyncInterval = D3DPRESENT_INTERVAL_IMMEDIATE;rem

hr = pSwapChain ->Present( SyncInterval, dwFlags );get

------------------------------------

垂直同步脈衝(Vertical synchronization, Vsync)是加在兩幀之間。跟水平同步脈衝相似,但它指示着前一幀的結束,和新一幀的開始。 垂直同步脈衝是一個持續時間比較長的脈衝,可能持續一行或幾行的掃描時間,但在這段時間內,沒有像素信號出現。

http://baike.baidu.com/view/399524.htm

http://en.wikipedia.org/wiki/Analog_television#Vertical_synchronization

 

Remarks

Windowed mode supports D3DPRESENT_INTERVAL_DEFAULT, D3DPRESENT_INTERVAL_IMMEDIATE, and D3DPRESENT_INTERVAL_ONE. D3DPRESENT_INTERVAL_DEFAULT and the D3DPRESENT_INTERVAL_ONE are nearly equivalent (see the information regarding timer resolution below). They perform similarly to COPY_VSYNC in that there is only one present per frame, and they prevent tearing with beam-following. In contrast, D3DPRESENT_INTERVAL_IMMEDIATE will attempt to provide an unlimited presentation rate.

Full-screen mode supports similar usage as windowed mode by supporting D3DPRESENT_INTERVAL_IMMEDIATE regardless of the refresh rate or swap effect. D3DPRESENT_INTERVAL_DEFAULT uses the default system timer resolution whereas the D3DPRESENT_INTERVAL_ONE calls timeBeginPeriod to enhance system timer resolution. This improves the quality of vertical sync, but consumes slightly more processing time. Both parameters attempt to synchronize vertically.

相關文章
相關標籤/搜索