MCPcopy Create free account
hub / github.com/GenericMappingTools/gmt / gmtplot_map_symbol_ns

Function gmtplot_map_symbol_ns

src/gmt_plot.c:1896–1910  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1894}
1895
1896GMT_LOCAL void gmtplot_map_symbol_ns (struct GMT_CTRL *GMT, struct PSL_CTRL *PSL, double lon, char *label, double south, double north, bool annot, unsigned int level, unsigned int form) {
1897 unsigned int i, k, nc;
1898 struct GMT_XINGS *xings = NULL;
1899 bool flip = (gmt_M_type (GMT, GMT_IN, GMT_X) == GMT_IS_LON && gmt_M_type (GMT, GMT_IN, GMT_Y) != GMT_IS_LAT && GMT->current.proj.scale[GMT_Y] < 0.0);
1900 /* flip deals with the problem when x is lon and geographic annotation machinery is used but y is Cartesian and upside down */
1901 nc = gmtlib_map_loncross (GMT, lon, south, north, &xings);
1902 for (i = 0; i < nc; i++) {
1903 if (flip) for (k = 0; k < xings[i].nx; k++) { /* Must turn sides 0 and 2 into sides 2 and 0 */
1904 if ((xings[i].sides[k] % 2) == 0) xings[i].sides[k] = 2 - xings[i].sides[k]; /* Flip up and down sides */
1905 }
1906 //gmtplot_map_symbol (GMT, PSL, xings[i].xx, xings[i].yy, xings[i].sides, xings[i].angle, label, xings[i].nx, 0, annot, level, form);
1907 gmtplot_map_symbol (GMT, PSL, &(xings[i]), label, 0, annot, level, form);
1908 }
1909 if (nc) gmt_M_free (GMT, xings);
1910}
1911
1912GMT_LOCAL void gmtplot_z_gridlines (struct GMT_CTRL *GMT, struct PSL_CTRL *PSL, double zmin, double zmax, int plane, unsigned int mode3d, int quadrant) {
1913 unsigned int k, i, nz, n, item[2] = {GMT_GRID_UPPER, GMT_GRID_LOWER};

Callers 1

gmtplot_map_annotateFunction · 0.85

Calls 2

gmtlib_map_loncrossFunction · 0.85
gmtplot_map_symbolFunction · 0.85

Tested by

no test coverage detected