SaveImage - attempt to make it faster
#2
Let me introduce you to SaveImage:  Save Image v2.3d (qb64phoenix.com)

It saves full screens.  Partial screens.  Text or Graphic screens.  In BMP, PNG, GIF, or JPG format.  You can set 256 Color Images to "Best Palette" or "QB64 Palette".  It's fast, efficient, easy to use, and has passed the test of time on all platforms.  

What more do you need from a SaveImage library?

Usage is more or less as simple as:

Code: (Select All)
'$INCLUDE:'SaveImage.BI
'draw stuff to whatever screen you want
SaveFullImage filename$
'$INCLUDE:'SaveImage.BM'

The extension you specify for your filename is enough for the library to decided what file type to save for you.   "My Pic.JPG" saves a jpg file.  "My Pic.BMP" saves it in BMP format.  Same for GIF or PNG..

If you only need to save part of the screen, or a different image than the one that is the current _SOURCE, then just call:

result = SaveImage(file$, imagehandle, x1, y1, x2, y2)

The SaveImage function works with screen portions, as well as specified screens/images, and returns success/failure results through the Function for you, in case there's some issue where the image won't save properly for you.
Reply


Messages In This Thread
RE: SaveImage - attempt to make it faster - by SMcNeill - 12-09-2022, 11:17 AM



Users browsing this thread: 3 Guest(s)