Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 05-10-09, 07:41 AM   #1
bwheaton
Registered User
 
Join Date: Nov 2008
Location: California
Posts: 59
Send a message via AIM to bwheaton
Default VSync Failing under load?

I have a fairly complex OpenGL based app, and after some struggling, I have a working vsync setup. I can increase the number of frames between swaps and see it, and I have a white flash test pattern that shows a good sync when my app starts. The problem is when I start to run video - I start to get tearing in the center of the screen.

In my app, I do have:
a thread per screen,
a shared context that does nothing,
a thread per video I play.

The video threads, which I use to upload frames so that any screen can use them, and to stop shader recompilations etc. (as the video type changes) affecting the screen threads, use a fence so I know when they have completed drawing a frame, at which point they become available to the screen threads.

The exact same situation appears if I only have one screen running, full screen on one display of a twinview pair.

As I say, it seems that the load is making the vsync fail. This is with driver 180.44 on a current Arch Linux based system, and a built in laptop 9300 or an 8200 on a Mini-ITX mobo, or 8800 cards.

Any clues? I'm a bit under the gun on this issue.

Bruce
bwheaton is offline   Reply With Quote
Old 05-10-09, 01:10 PM   #2
bwheaton
Registered User
 
Join Date: Nov 2008
Location: California
Posts: 59
Send a message via AIM to bwheaton
Default Re: VSync Failing under load?

Here's the compulsory bug report for my development machine - maybe it shows the failure, don't know.

But meanwhile, on a hunch, I made my 'fullscreen' object fill the whole twinview display as opposed to the single display it's meant to be on. Then it seemed that both displays - even though one is an internal LCD I've had no luck setting 59.95 Hz on and the other is/should be outputting 720p at 59.94 seemed to be clean of any tearing.

This is a bit of problem for me. I guess the notes on flipping should have said that only a single fullscreen OpneGL app filling the whole TwinView screen would flip? Even on another system with two - theoretically - identical outputs (displays) running as separate threads with their own swap buffer calls we get tearing. Is this a limitation of tearing and TwinView?

So, what's the solution? Can I use two X Screens now? I was having trouble sharing contexts between two screens before - is that supported on 180.xx drivers? Or is the flipping limitation not present on other drivers (hopefully later?)

Regards,

Bruce Wheaton
Attached Files
File Type: zip nvidia-bug-report.log.zip (32.0 KB, 77 views)
bwheaton is offline   Reply With Quote
Old 05-10-09, 05:04 PM   #3
AaronP
NVIDIA Corporation
 
AaronP's Avatar
 
Join Date: Mar 2005
Posts: 2,487
Default Re: VSync Failing under load?

Flipping on GeForce GPUs does indeed require your window to fill the entire framebuffer (including both displays in TwinView). You should be able to have your screens flip independently with separate X screens, but I can never remember what the sharing rules are between OpenGL contexts on different screens.

Quadro GPUs can do flipping in a window as long as only one OpenGL window is active at a time.
AaronP is offline   Reply With Quote
Old 05-11-09, 10:27 AM   #4
bwheaton
Registered User
 
Join Date: Nov 2008
Location: California
Posts: 59
Send a message via AIM to bwheaton
Default Re: VSync Failing under load?

OK, thanks for that confirmation Aaron. I can rework some of my screens to do shared swapping, but I'm curious - is there a way around this on a TV out? How does TV out vsync swapping work? Is that different than flipping in a way we can exploit?

Bruce
bwheaton is offline   Reply With Quote
Old 05-11-09, 02:24 PM   #5
AaronP
NVIDIA Corporation
 
AaronP's Avatar
 
Join Date: Mar 2005
Posts: 2,487
Default Re: VSync Failing under load?

TV-out shouldn't be any different from any other output type as far as flipping and vsync are concerned.
AaronP is offline   Reply With Quote
Old 05-13-09, 05:03 AM   #6
bwheaton
Registered User
 
Join Date: Nov 2008
Location: California
Posts: 59
Send a message via AIM to bwheaton
Default Re: VSync Failing under load?

Thanks for your help.

Just before I go too crazy with a switch-around, can I ask two more questions:

Is there a compositor that uses OpenGL enough that I could have a window with one OpenGL view on one screen (of a twinview pair) and the other display fullscreen?

Could I roll my own triple-buffering? Is that what alternate solutions are doing (SDL)? I my case I would do all my drawing to a back back buffer then use a non-vsynced swap. I presume that's what compositors and Mac OS X do?

Bruce
bwheaton is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
173.14.34 -- Xorg 1.12.1 & 1.11.4, glx module fails to load mereset NVIDIA Linux 17 06-10-12 01:24 AM
Lucid rt kernel can't load latest nvidia driver module, but generic does. marcod NVIDIA Linux 0 05-02-12 06:23 AM
VSYNC issue? counterveil NVIDIA Linux 3 10-16-02 08:19 AM
Can't load NVdriver jojotux123 NVIDIA Linux 4 09-18-02 06:15 AM
1400x1050 res on Inspiron (RH7.2) ? lionelb NVIDIA Linux 2 09-10-02 01:42 PM

All times are GMT -5. The time now is 06:21 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.