scrnshot.c File Reference

Save a graphical screen shot on Windows systems. More...

#include <windows.h>
#include <stdbool.h>
#include "png.h"


bool SaveWindow_PNG (HWND hWnd, LPSTR lpFileName)
 Extract the "WIN32" flag from the compiler. More...

Detailed Description

Save a graphical screen shot on Windows systems.

Copyright (c) 2011 Brett Reid

This work is free software; you can redistribute it and/or modify it under the terms of either:

a) the GNU General Public License as published by the Free Software Foundation, version 2, or

b) the "Angband licence": This software may be copied and distributed for educational, research, and not for profit purposes provided that this copyright and statement are included in all such copies. Other copyrights may also apply.

Function Documentation

bool SaveWindow_PNG ( HWND  hWnd,
LPSTR  lpFileName 

Extract the "WIN32" flag from the compiler.

Save a window to a PNG file.

Returns true if the PNG file is written, and false if something went wrong.

References bit_depth, data, fp, height, info_ptr, NULL, PNG_COLOR_TYPE_RGB, PNG_COMPRESSION_TYPE_DEFAULT, PNG_FILTER_TYPE_DEFAULT, PNG_INTERLACE_NONE, PNG_LIBPNG_VER_STRING, row_pointers, and width.