Skip to main content
GameDev.net gamedev.net
🔒 Locked

directdraw scaling problem

Started by nirdil Apr 23, 2009 at 3:31 AM 0 replies 1.2k views
Original Post
nirdil
nirdil
Hi all I'm trying to use directdraw to scale a high mega pixel video to a window size, but I fail on certain video cards. The details are as followed: Surface1 holds the original frames, 2144x976, RGB24, offscreen surface, in video memory, not overlayed. Surface2 is the same just with a different resolution of 704x530. When I blit from Surface1 to Surface2 the failure occures. On tested Nvidia/Ati cards it all works fine, but on intel GMA cards I get a not implemented error response. A few remarks: 1) On smaller source resolutions it all works fine and the scaling works as anticipated 2) Initially this blit caused a blue screen on workstations equipped with the intel cards, but after updating their driver, that was resolved 3) Looking through the card's directdraw capabilities I didn't find any relevant imposed scaling limitations or surface sizes limitations 4) Currently the only work around that I can see for this (without waiting for the blit to fail) is to check for the lack of flag NONLOCALVIDMEM and combine this with a certain resolution threshold above which the surfaces will be created in system memory Any thoughts? Thanks in advance Nir
jrmcv
jrmcv
It's a while since i have used direct draw but I had a look around and found this page.

In summary: It might be because the hardware does not support scaling.

Although, I would have thought there would be a fall back software feature - maybe its some of the settings. Sorry I can't be more help but someone else will probably come back with more information.

From that link:
Quote:

"A significant performance penalty may be imposed if the region of surface memory you are copying from is not the same size as the region of surface memory you are copying to. This is because the target video hardware may not support hardware scaling, or it may only support scaling in integer multiples."

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.