If you have any thoughts about how I could solve this problem please don't hesitate to share them. HWnd = CreateWindow("My Project","My Project", WS_OVERLAPPEDWINDOW|WS_POP UP,ĬW_USEDEFAULT,CW_USEDEFAUL T,WINDOW_X ,WINDOW_Y, Window.hbrBackground = (HBRUSH)GetStockObject(BLA CK_BRUSH) Window.hCursor = LoadCursor( NULL, IDC_ARROW ) Window.lpszClassName = TEXT("My Project") LpddsFrontBuffer->Blt(&des t, lpddsBackBuffer, &src, DDBLT_WAIT, NULL) LpddsFrontBuffer->Flip(NUL L, DDFLIP_WAIT) ![]() Result = lpDD->CreateSurface(&ddsd, &lpddsBackBuffer, NULL) Result = lpddsFrontBuffer->SetClipp er(lpddCli pper) ĭdsd.dwFlags = DDSD_CAPS|DDSD_HEIGHT|DDSD _WIDTH ĭ = DDSCAPS_OFFSCREENPLAIN ![]() Result = lpDD->CreateClipper(0, &lpddClipper, NULL) ZeroMemory(&ddsd, sizeof(DDSURFACEDESC2)) ĭ = DDSCAPS_PRIMARYSURFACE Result = lpDD->SetCooperativeLevel( hWnd, DDSCL_NORMAL) Result = lpddsFrontBuffer->GetAttac hedSurface (&ddscaps, &lpddsBackBuffer) The Windows port now has an extra 'Hacks' settings dialog that allows enabling some settings to allow older ROM hacks to work. Result = lpDD->CreateSurface(&ddsd, &lpddsFrontBuffer, NULL) ĭdscaps.dwCaps = DDSCAPS_BACKBUFFER //this is the back buffer The biggest changes in this release are some reversions which fix a couple games, some accuracy improvements which fix a couple more games, and some optimizations that speed things up a bit. setting the characteristics of the surfaceĭdsd.dwFlags = DDSD_CAPS|DDSD_BACKBUFFERC OUNT //uses these membersĭ = DDSCAPS_PRIMARYSURFACE|DDS CAPS_FLIP| DDSCAPS_CO MPLEX //uses page flippingĭdsd.dwBackBufferCount = 1 //1 back buffer Result = lpDD->SetDisplayMode(FULLS CREEN_X, FULLSCREEN_Y, COLOUR_DEPTH, 0, 0) Result = lpDD->SetCooperativeLevel( hWnd, DDSCL_EXCLUSIVE|DDSCL_FULL SCREEN) Result = DirectDrawCreateEx(NULL, (void**)&lpDD, IID_IDirectDraw7, NULL) HRESULT DDWrapper::InitializeDirec tDraw(HWND hWnd, bool Fullscreen) ![]() The code for initializing the directdraw environment is Here is a screen shot to illustrate my problem but its not very suggestive, it has not captured the granulating horizontal bars that flicker all the time The screen flickers and the image is corrupted. Although it compiles and runs without any errors or exceptions I can still see a window which has the dimensions used with LPDIRECTDRAW7::SetDisplaym ode(). What happens is I cannot get it to work in fulscreen mode. Hi, I am having a little bit of hard time with properly initializing my direct draw application.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |