GRASS GIS 8 Programmer's Manual
8.5.0dev(2024)-36359e2344
|
Display Driver - setup. More...
#include <string.h>
#include <grass/gis.h>
#include <grass/raster.h>
#include <grass/display.h>
#include "driver.h"
Go to the source code of this file.
Functions | |
void | D_setup (int clear) |
Graphics frame setup. More... | |
void | D_setup_unity (int clear) |
Graphics frame setup. More... | |
void | D_setup2 (int clear, int fit, double st, double sb, double sl, double sr) |
Sets source coordinate system. More... | |
const char * | D_get_file (void) |
Get driver output file. More... | |
Display Driver - setup.
(C) 2006-2011 by 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.
Definition in file display/setup.c.
const char* D_get_file | ( | void | ) |
Get driver output file.
Definition at line 141 of file display/setup.c.
References COM_Graph_get_file().
void D_setup | ( | int | clear | ) |
Graphics frame setup.
This is a high level D call. It does a full setup for the current graphics frame.
Note: Connection to driver must already be made.
Sets the source coordinate system to the current region, and adjusts the destination coordinate system to preserve the aspect ratio.
Performs a full setup for the current graphics frame:
If clear is true, the frame is cleared (same as running d.erase.) Otherwise, it is not cleared.
clear | 1 to clear frame (visually and coordinates) |
Definition at line 46 of file display/setup.c.
void D_setup2 | ( | int | clear, |
int | fit, | ||
double | st, | ||
double | sb, | ||
double | sl, | ||
double | sr | ||
) |
Sets source coordinate system.
Sets the source coordinate system to its arguments, and if the fit argument is non-zero, adjusts the destination coordinate system to preserve the aspect ratio.
If clear is true, the frame is cleared (same as running d.erase). Otherwise, it is not cleared.
clear | non-zero code to clear the frame |
fit | non-zero code to adjust destination coordinate system |
s_top | |
s_bottom | |
s_left | |
s_right |
Definition at line 114 of file display/setup.c.
References D_erase(), D_fit_d_to_u(), D_get_frame(), D_set_clip_window_to_map_window(), D_set_clip_window_to_screen_window(), D_set_dst(), D_set_src(), D_update_conversions(), DEFAULT_BG_COLOR, and st.
void D_setup_unity | ( | int | clear | ) |
Graphics frame setup.
Sets the source coordinate system to match the destination coordinate system, so that D_* functions use the same coordinate system as R_* functions.
If clear is true, the frame is cleared (same as running d.erase). Otherwise, it is not cleared.
clear | non-zero code to clear the frame |
Definition at line 78 of file display/setup.c.
References D_erase(), D_get_frame(), D_set_clip_window_to_map_window(), D_set_clip_window_to_screen_window(), D_set_dst(), D_set_src(), D_update_conversions(), and DEFAULT_BG_COLOR.