DirectX's SDK's DirectDraw samples wanted, and 1 Questions and 2 Troubles on DirectX SDK

DirectX's SDK's DirectDraw samples wanted, and 1 Questions and 2 Troubles on DirectX SDK

Post by Peter Ame » Fri, 04 Jul 2003 18:39:31


Could you please do me a favor by sending me ***ALL DIRECTDRAW'S SAMPLES

I have downloaded DirectX 9 SDK by my poor 56K modem, it took me nearly 20
hours to get it. DirectX 9 SDK does't have any DirectDraw's document and
sample, but I really don't want to take another 10 hours to get the whole
DirectX 7 SDK. :(

I know the relation between DirectDraw and the new DirectGraphics, but I
still do need DirectDraw sometimes...

If I have the fortune to get help from you, I suggest you send me the
DirectDraw's samples included in DirectX 7 or above, zip all of them except
DEBUG folders, and take a meaningful email title to let me know that's not a
rubbish email.

BTW, I have 1 question and 2 troubles on DirectX:

(1) for the CreateDevice() in DirectX 9's D3D

 hr = g_pD3D->CreateDevice( D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, hWnd,
                                      &d3dpp, &g_pd3dDevice )

the CreateDevice() returns error, that means my video card does't hardware
support DirectX 9's D3D, then I have to use D3DDEVTYPE_REF for the second
parameter, every thing is ok, but the render speed is terribly low.

If my video card hardware supports DirectX 7's or 8' D3D, but does't
hardware support DirectX 9's D3D, for the sake of render performance, I
wonder do I have to totally give up DirectX 9's D3D's APIs, even though my
video card partly hardware support DirectX 9's D3D?

(2) DirectX D3D program can be debugged with Visual Studio 6, but for nearly
all DirectX D3D programs (I didn't try DirectX programs other than DirectX
D3D), when end the debugging by exiting the program normally and switch to
Visual Studio 6, an error dialog will appear saying similarly like below:
(translated from language other than English, for I'm not using English
edition of Windows)

 "this program did an invalid operation, will be closed now,
 if there is still the problem, please contact to program's supplier"

then Visual Studio 6 exits abnormally, and some times explorer and other
running programs popup the same error dialogs and exist abnormally.

(3) Any DirectX 8's D3D program can't be run in my DirectX 9 environment,
the CreateDevice() below always return D3DERR_INVALIDCALL

 hr = g_pD3D->CreateDevice( D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, hWnd,
                               &d3dpp, &g_pd3dDevice );

Replacing the second parameter with D3DDEVTYPE_REF is no useful, but for the
same program, if I respectively change each DirectX 8's interface and
function to DirectX 9's one, then the program runs correctly.

Thank you!


DirectDraw's samples in DirectX 7 SDK:

  DDEnum Sample
  DDEx1 Sample
  DDEx2 Sample
  DDEx3 Sample
  DDEx4 Sample
  DDEx5 Sample
  DDOverlay Sample
  Font Sample
  FSWindow Sample
  ModeTest Sample
  Mosquito Sample
  Multimon Sample
  Space Donuts Sample
  Stretch Sample
  Switcher Sample
  Wormhole Sample

My system environment:

  AMD K6-2, 256M
  Riva 128 :(((
  Windows 98se, Visul Studio 6.0 (no Service Pack), DirectX 9.0a