grass  7.8.6
About: GRASS (Geographic Resources Analysis Support System) is a raster- and vector-based GIS, image processing system, graphics production system and spatial modeling system.
  Fossies Dox: grass-7.8.6.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

graph_set.c File Reference

GRASS png display driver - set graphics processing. More...

#include <string.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/mman.h>
#include <grass/gis.h>
#include <grass/colors.h>
#include <grass/glocale.h>
#include "pngdriver.h"
Include dependency graph for graph_set.c:

Go to the source code of this file.


static void map_file (void)
int PNG_Graph_set (void)
 Start up graphics processing. More...
const char * PNG_Graph_get_file (void)
 Get render file. More...


struct png_state png

Detailed Description

GRASS png display driver - set graphics processing.

(C) 2003-2014 by Glynn Clements and the GRASS Development Team

This program is free software under the GNU General Public License (>=v2). Read the file COPYING that comes with GRASS for details.

Per Henrik Johansen (original contributor)
Glynn Clements

Definition in file graph_set.c.

Function Documentation

◆ map_file()

static void map_file ( void  )

◆ PNG_Graph_get_file()

const char * PNG_Graph_get_file ( void  )

Get render file.

file name

Definition at line 180 of file graph_set.c.

References png_state::file_name, and png.

Referenced by PNG_Driver().

◆ PNG_Graph_set()

int PNG_Graph_set ( void  )

Start up graphics processing.

Anything that needs to be assigned, set up, started-up, or otherwise initialized happens here. This is called only at the startup of the graphics driver.

The external variables define the pixle limits of the graphics surface. The coordinate system used by the applications programs has the (0,0) origin in the upper left-hand corner. Hence, screen_left < screen_right screen_top < screen_bottom

Definition at line 82 of file graph_set.c.

References _, png_state::background, png_state::clip_bot, png_state::clip_left, png_state::clip_rite, png_state::clip_top, DEFAULT_FG_COLOR, FILE_NAME, png_state::file_name, G_debug(), G_gisinit, G_str_to_color(), G_strcasecmp(), G_verbose_message(), getenv(), png_state::grid, png_state::has_alpha, png_state::height, map_file(), png_state::mapped, png_state::modified, png, PNG_Erase(), png_get_color(), png_init_color_table(), read_image(), screen_height, screen_width, png_state::true_color, png_state::width, and write_image().

Referenced by PNG_Driver().

Variable Documentation

◆ png