Tearing, but how

Started by
6 comments, last by blaze02 17 years, 9 months ago
Why would my app tear with D3DPRESENT_INTERVAL_DEFAULT? I am keeping a gross amount of textures now, and I am rendering to a texture, then to the frame with one giant quad. But I've had it happen on other apps too. I thought it was because of D3D text functions, but I turned that off in my app and it still happened? The tear is about 1/2cm and another 1cm from the bottom of the window. Both tears are all the way across the screen. Oh, and I just looked at an older version of my current app, and it doesn't happen! So I broke something along the way :( Thanks for any help.
-------Harmotion - Free 1v1 top-down shooter!Double Jump StudiosBlog
Advertisement
how high is the framerate ?

(are you rendering multiple frames within one monitor refresh?)
Also, just as an FYI, setting D3DPRESENT_INTERVAL_DEFAULT doesn't forcefully enable VSYNC. The drivers can override this setting, if they are set to do so.

Hope this helps.
Sirob Yes.» - status: Work-O-Rama.
A little research tnen. The tear does not occur in fullscreen mode. We are using a 800x600 (+borders) window when the tears occur. With the monitor refresh at 60 or 70, the game ran at 60 FPS. Seems like it should not tear, right?
-------Harmotion - Free 1v1 top-down shooter!Double Jump StudiosBlog
Quote:Original post by blaze02
A little research tnen. The tear does not occur in fullscreen mode. We are using a 800x600 (+borders) window when the tears occur. With the monitor refresh at 60 or 70, the game ran at 60 FPS. Seems like it should not tear, right?


Just because the games average FPS is 60 doesn't mean that there aren't bursts above 60 FPS (Depending on how it's programmed of course).
I've profiled the code, there are no "bursts". Has this not happened to anyone before?

EDIT: I'm thinking its my monitor. I've only seen it happen to me :( Thats a little disappointing since its I'm using a ~$700 Sony. I guess its not a problem then because I play in fullscreen.
And I noticed it does not tear in the screenshots. For my screen shots I just save the render target texture (just before its draw to a fullscreen quad on the back buffer).
-------Harmotion - Free 1v1 top-down shooter!Double Jump StudiosBlog
My advice is try it with D3DPRESENT_INTERVAL_ONE instead of D3DPRESENT_INTERVAL_DEFAULT and see if that provides a better v-sync.
Quote:MSDN Entry on D3DPRESENT
D3DPRESENT_INTERVAL_DEFAULT and the D3DPRESENT_INTERVAL_ONE are nearly equivalent

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.

Hope this helps,
ViLiO
Richard 'ViLiO' Thomasv.net | Twitter | YouTube
Quote:Original post by ViLiO
My advice is try it with D3DPRESENT_INTERVAL_ONE instead of D3DPRESENT_INTERVAL_DEFAULT and see if that provides a better v-sync.
Quote:MSDN Entry on D3DPRESENT
D3DPRESENT_INTERVAL_DEFAULT and the D3DPRESENT_INTERVAL_ONE are nearly equivalent

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.

Hope this helps,
ViLiO


I thought they were defined to be the same thing? I've tried it before though, to no avail.
-------Harmotion - Free 1v1 top-down shooter!Double Jump StudiosBlog

This topic is closed to new replies.

Advertisement