Author Topic: [solved] SaveScreenShot is just bmp? [answer: no]  (Read 1157 times)

eri0o

was looking SaveScreenShot in the manual today... I noticed it says one can choose either .pcx or .bmp .
I think it's only .bmp, but I am not sure, since it appears it just saves the buffer directly to file. Just wanted to fix it, since I think .pcx only exists in the engine for preload.pcx image (but I can be wrong).
« Last Edit: 25 Sep 2018, 02:51 by eri0o »

Re: SaveScreenShot is just bmp?
« Reply #1 on: 25 Sep 2018, 02:12 »
I think it's only .bmp, but I am not sure, since it appears it just saves the buffer directly to file.

It does not save the buffer to file, if you refer to the name of a "buffer" variable in SaveScreenShot function then the type of that variable is Bitmap class pointer, and Bitmap saves itself using Allegro's save_bitmap function.
Quote
Writes a bitmap into a file, using the specified palette, which should be an array of 256 RGB structures. The output format is determined from the filename extension: at present this function supports BMP, PCX and TGA formats.
Whether Allegro does its work is something that may be tested.
« Last Edit: 25 Sep 2018, 02:15 by Crimson Wizard »

eri0o

Re: SaveScreenShot is just bmp?
« Reply #2 on: 25 Sep 2018, 02:50 »
ah ok! I am sorry, from the name I assumed bitmap only - as in .bmp only.