Dear all,
I'm developing a real time video player by DirectDraw.
Here is a part of my code:
DDSURFACEDESC2 sSurfaceDesc;
ZeroMemory(&sSurfaceDesc, sizeof(DDSURFACEDESC2));
sSurfaceDesc.dwSize = sizeof(DDSURFACEDESC2);
sSurfaceDesc.dwFlags = DDSD_CAPS | DDSD_HEIGHT | DDSD_WIDTH;
sSurfaceDesc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN;
sSurfaceDesc.dwWidth = iW;
sSurfaceDesc.dwHeight = iH;
HRESULT hRes = pDD->CreateSurface(&sSurfaceDesc, &lpBackSurface, NULL);
On Radeon HD 6800 series, if iW is larger than the width of monitor resolution.
I will get DDERR_INVALIDPARAMS from CreateSurface.
EX.
monitor resolution is 1440 x 900
iW = 1600 iH = 1200 -> hRes = DDERR_INVALIDPARAMS
iW = 1280 iH = 1024 -> hRes = DD_OK
Since the display card is with DDCAPS2_WIDESURFACES in GetCaps.
It supposes to be able to create a wider surface than the monitor.
Any suggestions?
Thank you for your help.
Anders