Skip to main content
GameDev.net gamedev.net
🔒 Locked

(solved) Present possible? loader texts d3d

Started by cozzie Dec 23, 2012 at 2:34 PM 0 replies 1.3k views
Original Post
cozzie
cozzie

Hi, I'm trying to show some initialization texts while starting my d3d engine, loadings meshes, shaders etc.. When I run in windowed mode, my drawtext (LP3DXFONT) all works fine and the result is visiblhe through "present" calls. However when I do the same fullscreen, I get either: - no texts shown - and/or D3D debug errors saying assertion failed with bPresentSubmitted (probably because I'm trying to present something while not ready yet). It looks like initizing fullscreen (device) takes longer then windowed, causing this to happen. I tried to add a check for TestCooperativeLevel before 'printing' and presenting the load texts, this didn't help. What I know is that adding a sleep(100) somehere in the startup, solves the problem. But that's the cheap way I guess. Do you have experience with this/ and or do you know if there's a d3d function to check if calling dev->present will bring something on screen? (testcooperativelevel seems to give D3D_OK anyway, even when the screen ísn't presenting anything/ able to present) It by the way also happens when I load my meshes into d3dpool_managed instead of systemmem. Found it that adding a Sleep(20) in my render function, right before present, also solved it here. Probably missing something as check before 'presenting' the BackBuffer. Any help would be appreciated, it might be quite simple but for now very annoying...

Crealysm game & engine development: http://www.crealysm.com

Looking for a passionate, disciplined and structured producer? PM me
cozzie
cozzie

Most likely found it, i'm passing through the d3d device as * (pointer) in several functions, which is basically a pointer to a pointer.

This would explain why using systemmemory pool is working OK and GPU ram isn't.

Will try it out.

Crealysm game & engine development: http://www.crealysm.com

Looking for a passionate, disciplined and structured producer? PM me

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.