Results 1 to 3 of 3

Thread: DirectDraw Resolution Problem

  1. #1

    Thread Starter
    New Member
    Join Date
    Dec 2002
    Posts
    1

    DirectDraw Resolution Problem

    I am using directdraw for programming a graphics game, I have 2 characters. I have a problem as when I use resoultionb of 1024 * 768, the game still shows up at 800 * 600, but to make make up for the excess screen there is a white band of flashing screen around the game . So in other words the game screen is reduced and dosent take up the whole screen. Also when I use 800 * 600 resoultion it works fine. 640 * 480 works too but anything greater than 800 *600 dosent work. Anyone know what the problem is?

  2. #2
    Addicted Member
    Join Date
    Aug 2002
    Location
    Baltimore, MD
    Posts
    230
    Maybe if you showed us the relevant code we could offer some advice.

  3. #3
    Ex-Super Mod'rater Electroman's Avatar
    Join Date
    Sep 2000
    Location
    Newcastle, England
    Posts
    4,349
    Could just be ur PC, but if you can run windows in 1024*768 there shuldn't be a problem. Have you tried this to check its a valid display mode:

    VB Code:
    1. Private DModes As DirectDrawEnumModes
    2. Private rModeCount as Long
    3. Private rModes() as string
    4.  
    5. Dim Temp As DDSURFACEDESC2
    6.     Set DModes = DDraw.GetDisplayModesEnum(DDEDM_DEFAULT, Temp)
    7.    
    8.     rModeCount = DModes.GetCount
    9.     ReDim rModes(1 To rModeCount)
    10.     For i = 1 To rModeCount
    11.         DModes.GetItem i, Temp
    12.         rModes(i) = CStr(Temp.lWidth) & "x" & CStr(Temp.lHeight) & "*" & CStr(Temp.ddpfPixelFormat.lRGBBitCount)
    13.     Next

    Hope that will help you.
    When your thread has been resolved please edit the original post in the thread ()
    and amend "-[RESOLVED]-" to the end of the title and change the icon to , Thank you.

    When posting Code use the [VBCode]Code Here[/VBCode] tags to be able to use the code highlighting.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width