EDIT 2017-05-14 dvb. Issue still active to this very day, see geforce forum link in main question.
Note 3: "Stoltverd" has posted a "fix guide" on geforce forum. It has workarounds for non-OpenGL games.
Note 4: My workaround for OpenGL games: use HDMI output to external monitor. (In my case, the only game I care about is my own, and I use a big cheap HDMI TV for demo.)
EDIT 2016-03-06.
Note 1: Apparently this is a known issue with Nvidia. If you've found here due to same problem, please stoke the collective "please fix it" by filing a "question" at https://nvidia.custhelp.com/app/ask.
Note 2: Doesn't happen on external monitor. Also doesn't happen on internal display if external monitor is mirroring. (Surprise.)
I'm developing my game directly in C++, OpenGL, and SDL2.
On an Alienware 15 R2 laptop with Nvidia GTX 965M, I get screen tearing in a curious diagonal line like shown below. It goes across the window top left to bottom right.
The image below is taken during a screen fade-in, so shows just a brightness line. But it happens between any two different frames.
If my window is full screen, the line goes top-left to bottom-right of the whole screen.
Same code runs fine (no tearing) on: All macs, same laptop on Intel integrated GPU, desktop PC with Nvidia 730.
Same laptop looks fine with other games, Chrome+Shadertoy, &c.
Main loop looks something like:
// setup code
SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);
SDL_GL_SetSwapInterval(1);
flags = SDL_WINDOW_OPENGL;
SDL_CreateWindow(... ,flags);
// main loop
while(1) {
this->checkEvents();
SDL_GL_SwapWindow(this->mainWindow);
this->doGlDrawing();
}
Grepping forums, I've seen reports of some OpenGL games showing this on Alienware & other Dell laptops.
All suggestions welcome! Thanks.
Edit 2016-02-20, some links to similar user-side reports: https://forums.geforce.com/default/topic/903422/geforce-mobile-gpus/diagonal-screen-tearing-issues-on-gtx-860m-870m-960m-965m-970m-980m-/
http://en.community.dell.com/owners-club/alienware/f/3746/t/19658623
https://www.reddit.com/r/Alienware/comments/427ltv/anyone_have_diagonal_screen_tearing_when_playing/