• Advertisement

Archived

This topic is now archived and is closed to further replies.

Flip (rotate) a surface 90 degrees (using DirectDraw)

This topic is 5875 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

How do I do it? I''m using DirectX 7.0a if it is of any interest. I''d prefer to do it in hardware but if the display adapter doesnt have the capability, will directdraw flip it for me (in software)? Johan Torp - http://www.destruction.nu

Share this post


Link to post
Share on other sites
Advertisement
Thanks for the tip but i just can''t get it working.... This is the code I use. What''s wrong (The blit doesn''t seem to take place if i use the DDBLT_DDFX flag)?


RECT destRect={x,y,
x + rcRect.right-rcRect.left,
y + rcRect.bottom-rcRect.top};

ZeroMemory(&ddbltfx, sizeof(ddbltfx));
ddbltfx.dwSize = sizeof(ddbltfx);
ddbltfx.dwDDFX=rot;
(*Destination)->Blt(&destRect, (*BlitSource), &rcRect, DDBLT_WAIT | DDBLT_KEYSRC | DDBLT_DDFX , &ddbltfx);

Btw, how do you guys get the colors when including a code piece in a message?


Johan Torp - http://www.destruction.nu

Share this post


Link to post
Share on other sites
I figured out how to get colors so here is my code again, slighlty easier to read:

  RECT destRect={x,y,
x + rcRect.right-rcRect.left,
y + rcRect.bottom-rcRect.top};
ZeroMemory(&ddbltfx, sizeof(ddbltfx));
ddbltfx.dwSize = sizeof(ddbltfx);
ddbltfx.dwDDFX=rot;
(*Destination)->Blt(&destRect, (*BlitSource), &rcRect, DDBLT_WAIT | DDBLT_KEYSRC | DDBLT_DDFX , &ddbltfx);


Though my still question remains...

Johan Torp - http://www.destruction.nu

Share this post


Link to post
Share on other sites

  • Advertisement