Hello Guest, please login or register.
Did you miss your activation email?
Login with username, password and session length.

Pages: [1]   Go Down

Author Topic: C++ DirectX Window to match the size of the screen  (Read 733 times)

0 Members and 1 Guest are viewing this topic.
C++ DirectX Window to match the size of the scre...
« on: May 05, 2007, 08:44:04 pm »
  • (y)(;>.<;)(y)
  • *
  • Reputation: +0/-0
  • Offline Offline
  • Gender: Male
  • Posts: 3293
Okay, this is something I have never actually seen in any tutorials...

When you create a Windows Window, you decide it's size. However the size you enter includes the border, so to get a 'window space' of 100*100, you'd have to do something like 106*127 (random numbers, most likely wrong). Well, then you try to run the app of another PC, and you'll still have the strangely sized screen, because on some PC's the border sizes are different.

Well, in DirectX when trying to make an app in windowed mode, this causes really annoying and ugly stretching. The only answers I can think of are to:
Run fullscreen
Tweak the window size for every possible setting, or make it editable via .ini

Well, this is obviously going to either cause problems, or make it extremely messy and complicated. Is their anyway to do it differently to this?

So, I have a DirectX window size of 200 * 150, how can I make the actual space in the Desktop Window is 200*150, not counting the border, be availiable on the various XP Border-size settings?

Sorry if this is badly worded.
Logged
Re: C++ DirectX Window to match the size of the ...
« Reply #1 on: May 05, 2007, 08:50:37 pm »
  • *
  • Reputation: +3/-0
  • Offline Offline
  • Gender: Male
  • Posts: 6629
Read up on AdjustWindowRectEx.
Logged
Re: C++ DirectX Window to match the size of the ...
« Reply #2 on: May 06, 2007, 09:22:42 am »
  • (y)(;>.<;)(y)
  • *
  • Reputation: +0/-0
  • Offline Offline
  • Gender: Male
  • Posts: 3293
Wooh! It works! Thanks. That's all I needed to know :)
Logged
Pages: [1]   Go Up

 


Contact Us | Legal | Advertise Here
2013 © ZFGC, All Rights Reserved



Page created in 0.054 seconds with 40 queries.

anything