Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

sdoherty55

Reading the Viewport

This topic is 6194 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

I am getting strange results (very large numbers) when I try to read the viewport in the ResoreDeviceObjectMethod()? Anyone have any problems with reading the viewport under XP and 8.1?
  
	D3DVIEWPORT8 Viewport;
	pd3dDevice->GetViewport(&Viewport);
	cvIceSpriteVertices[0].y  = (float) Viewport.Height - 1;
	cvIceSpriteVertices[2].y  = (float) Viewport.Height - 1;
	cvIceSpriteVertices[2].x  = (float) Viewport.Width - 1;
	cvIceSpriteVertices[3].x  = (float) Viewport.Width - 1;
  
Thanks

Share this post


Link to post
Share on other sites
Advertisement
With further debuging it seems that I am getting the following error when I call GetViewport:

  
Direct3D8: (INFO) :======================= Hal HWVP Pure device selected

Direct3D8: :DoneExclusiveMode
Direct3D8: (INFO) :HalDevice Driver Style 7

Direct3D8: (ERROR) :GetViewport does not work in pure-device

...Error: Get Viewport failed - Invalidcall


Does this mean that my driver is not supporting the call to GetViewport. If I switch to REF mode it seems to work. I am running Windows XP and a Radeon VIVO 64 Meg?

Thanks

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

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

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!