Enabling vertical sync may be performed by the user in several ways. The simplest method is to open the context menu of the desktop click the right mouse button on the empty table space and select "Screen". Open link Display Properties and click the Settings tab in the dialog box. Use the Advanced button and turn on the desired option in the section Wait for Vertical Sync.
To programmatically enable vertical sync in OpenGL, use code:

void set_vsync (bool enabled) // true
wglSwapInterval = (PFNWGLSWAPINTERVALEXTPROC) wglGetProcAddress ("wglSwapIntervalEXT");
if (wglSwapInterval) wglSwapInterval (enabled ?1 : 0);
Use DirectX 9 to enable vertical sync. To do this, before starting D3DDevice change the value of the parameter
g_d3d9Parameters.On SwapEffect D3DSWAPEFFECT_COPY. Then also set g_d3d9Parameters.PresentationInterval D3DPRESENT_INTERVAL_ONE value.
To enable vertical sync nVidia, open the context menu of the desktop computer by click right mouse button and select "nVidia control Panel". Open menu "View" of the upper service panel of the resulting window and select "Advanced". Expand "Manage 3D settings" in the left tree of the window control panel and specify the Include command in the drop-down list for the string "Vertical sync" in the next dialog box. Save changes by clicking OK and reboot to apply these changes.
Please note that sometimes you may not use the drop down menu and slider. In this case, you must move the slider to the rightmost position.