Jump to content
  • Advertisement
Sign in to follow this  
Nukleon

Problem switching to Fullscreen [ERR_INVALIDCALL]

This topic is 4623 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello everyone. I finally managed to set up my terrain engine and render from a mesh. The problem is, that when i try to switch into Fullscreen Mode via SampleFramework.ToggleFullSCreen() i get an invalidcall error. I had this before and fixed it by disposing the sprite resources in the OnLostDevice Callback. No i do the same for my terrain object, but the failure remains.
public void Terrain::Dispose() 
	{
		if ( m_vb != null )
		{
			m_vb.Dispose();
			m_vb = null;
		}
		if ( m_ib != null )
		{
			m_ib.Dispose();
			m_ib = null;
		}
		if ( m_texture != null )
		{
			m_texture.Dispose();
			m_texture = null;
		}
		
		if(m_verts!=null)
			m_verts=null;
		if(m_indices!=null)
			m_indices=null;
		if(m_height!=null)
			m_height=null;
		
		if(mesh!=null)
		{
			mesh.Dispose();
			mesh=null;
		}
	}
Does anybode know what else i have to remind when Losing and resetting a device? Thank you very much in advance Nukleon

Share this post


Link to post
Share on other sites
Advertisement
If you're using D3DXFont (or any similar resource) it will need to be handled as well. You should also check the Debug Output (see the Forum FAQ for more details) and see if it gives you any hints on what the problem is.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!