DirectDraw
If I wanted to save a DirectDraw surface as a BMP file, wuld I have to manually extract the raw surface data and write a BMP file myself, or are there GDI or DD functions to do this or make it easier?
Thanks in advance,
Shaw Mishrak
i havend came accross any bmp writing fnuctions yet...
writing your own would be simple - you just have to know the format of a bmp file - check www.wotsit.org for details on the bmp file format.
writing your own would be simple - you just have to know the format of a bmp file - check www.wotsit.org for details on the bmp file format.
There is an example in the platform SDK help file under Graphics and Multimedia Services -> GDI -> Using Bitmaps -> Storing a Bitmap.
To get a bitmap off a surface simply GetDC the surface and do a StretchBlt to a bitmap structure in memory. You can create the bitmap area in memory with CreateBitmap.
Edited by - Hootie on July 7, 2000 9:26:28 PM
To get a bitmap off a surface simply GetDC the surface and do a StretchBlt to a bitmap structure in memory. You can create the bitmap area in memory with CreateBitmap.
Edited by - Hootie on July 7, 2000 9:26:28 PM
I thought I saw an article about how to do this posted on gamedev''s main page. It was about using the GDI to capture a DirectDraw surface to a .BMP I can''t find it on the previously featured articles section, and it''s really bothering me! If anyone knows the whereabouts of this lost article, post a reply!
-----------------------------
My Geekcode: "GCS d s: a14 C++$ P+(++) L+ E-- W+++$ K- w++(+++) O---- M-- Y-- PGP- t X
R- tv+ b++ DI+(+++) D- G e* h!"
Decode my geekcode!
Geekcode.com
Visit our web site:
Asylum Entertainment
-----------------------------
My Geekcode: "GCS d s: a14 C++$ P+(++) L+ E-- W+++$ K- w++(+++) O---- M-- Y-- PGP- t X
R- tv+ b++ DI+(+++) D- G e* h!"
Decode my geekcode!
Geekcode.com
Visit our web site:
Asylum Entertainment
Is this the article you were thinking of by chance?
http://www.tasteofhoney.freeserve.co.uk/screenshot.html
http://www.tasteofhoney.freeserve.co.uk/screenshot.html
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement