GRASS Programmer's Manual
6.5.svn(2014)-r66266
|
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include <unistd.h>
#include <rpc/types.h>
#include <rpc/xdr.h>
#include <grass/gis.h>
#include "G3d_intern.h"
Go to the source code of this file.
Functions | |
int | G3d_writeCats (const char *name, struct Categories *cats) |
Writes the categories stored in the cats structure into the categories file for map name in the current mapset. See G_write_cats (Raster_Category_File) for details and return values. More... | |
if (G__name_is_fully_qualified(name, xname, xmapset)) | |
sprintf (buf2,"%s", G3D_CATS_ELEMENT) | |
if (!fd=G_fopen_old(buff, buf2, mapset)) | |
for (cat=0;;cat++) | |
fclose (fd) | |
switch (read_cats(name, mapset, pcats)) | |
G_warning ("category support for [%s] in mapset [%s] %s", name, mapset, type) | |
Variables | |
char | buff [1024] |
char | buf2 [200] |
char | xname [512] |
char | xmapset [512] |
CELL | cat |
DCELL | val1 |
DCELL | val2 |
int | old |
long | num = -1 |
else | |
return | |
error | __pad0__ |
fclose | ( | fd | ) |
Referenced by bin_install(), check_dependencies(), check_extension(), db_read_dbmscap(), db_shutdown_driver(), depstr(), deregister_entries_gisman(), deregister_entries_gisman2(), deregister_extension(), deregister_html(), dump_ascii(), dump_html(), dump_plain(), err(), font_exists(), G3d_readHistory(), G3d_writeAscii(), G3d_writeCats(), G3d_writeHistory(), G__get_window(), G__put_window(), G__quant_export(), G__quant_import(), G__raster_misc_read_line(), G__raster_misc_write_line(), G__read_cats(), G__write_cats(), G_ask_datum_name(), G_ask_ellipse_name(), G_ask_proj_name(), G_copy_file(), G_debug(), G_get_3dview(), G_get_cell_title(), G_get_cellhd(), G_get_dig_title(), G_get_gdal_link(), G_get_reclass(), G_is_reclass(), G_is_reclassed_to(), G_myname(), G_put_3dview(), G_put_cell_title(), G_put_cellhd(), G_put_reclass(), G_read_histogram(), G_read_history(), G_read_key_value_file(), G_read_range(), G_vasprintf(), G_write_colors(), G_write_histogram(), G_write_histogram_cs(), G_write_history(), G_write_key_value_file(), G_write_range(), get_package_name(), GK_print_keys(), GPJ_ask_datum_params(), GPJ_get_datum_transform_by_name(), GS_write_ppm(), GS_write_zoom(), I_get_control_points(), I_get_group(), I_get_group_title(), I_get_subgroup(), I_get_target(), I_list_groups(), I_list_subgroups(), I_put_control_points(), I_put_group(), I_put_group_title(), I_put_subgroup(), I_put_target(), list_extensions(), main(), make_location(), make_mapset(), parse_freetypecap(), PS_Graph_close(), R_parse_monitorcap(), read_bmp(), read_datum_table(), read_ellipsoid_table(), read_file(), read_pgm(), read_png(), read_ppm(), register_entries_gisman(), register_entries_gisman2(), register_extension(), register_html(), restore_entries_gisman(), restore_html(), S_read(), SADFClose(), SimpleErrorMessage(), source_install(), su(), test_install(), V1_close_nat(), V1_open_new_nat(), V2_close_ogr(), V2_open_old_ogr(), V__dump_window(), Vect__open_old(), Vect__read_head(), Vect__write_head(), Vect_cidx_open(), Vect_cidx_save(), Vect_close(), Vect_open_spatial_index(), Vect_open_topo(), Vect_read_dblinks(), Vect_save_spatial_index(), Vect_save_topo(), Vect_write_dblinks(), write_bmp(), write_file(), write_pgm(), write_png(), and write_ppm().
Definition at line 140 of file g3dcats.c.
References G_getl(), G_set_cat(), G_set_raster_cat(), and tools::label.
Referenced by avl_delete(), avl_probe(), free_slice_buff(), G3d_getBlockNocache(), G_site_get(), gvl_file_start_read(), I_cluster_begin(), I_cluster_reclass(), I_cluster_sum2(), N_les_integrate_dirichlet_2d(), N_les_integrate_dirichlet_3d(), NetA_flow(), shift_slices(), tavl_delete(), V_clear(), and Vect_line_reverse().
int G3d_writeCats | ( | const char * | name, |
struct Categories * | cats | ||
) |
Writes the categories stored in the cats structure into the categories file for map name in the current mapset. See G_write_cats (Raster_Category_File) for details and return values.
name | |
cats |
Definition at line 26 of file g3dcats.c.
References buf, buf2, fclose(), fd, G__name_is_fully_qualified(), G_fopen_new(), G_get_ith_d_raster_cat(), G_quant_nof_rules(), G_trim_decimal(), NULL, sprintf(), val1, val2, xmapset, and xname.
Referenced by class_equiprob(), clean_dir(), close_g3d_file(), db__copy_table(), db_delete_table(), db_get_column(), db_get_table_number_of_rows(), db_select_CatValArray(), db_select_int(), db_select_value(), db_start_driver_open_database(), db_table_exists(), db_table_to_sql(), dig__read_head(), dig_add_area(), dig_add_isle(), dig_cidx_del_cat(), dig_del_area(), dig_file_load(), dig_Rd_Plus_head(), dig_Rd_spindx_head(), dig_read_cidx_head(), dig_read_frmt_ascii(), dig_write_plus_file(), E_edit_cellhd(), err(), F_generate(), G3d_readWindow(), G__check_for_auto_masking(), G__check_fp_type(), G__check_gisinit(), G__check_null_bit(), G__open_cell_old(), G__open_null_write(), G__quant_import(), G__random_d_initialize_0(), G__random_f_initialize_0(), G__raster_misc_read_line(), G__raster_misc_write_line(), G__read_row_ptrs(), G__write_fp_format(), G__write_null_bits(), G_adjust_Cell_head(), G_adjust_Cell_head3(), G_ask_colors(), G_ask_datum_name(), G_check_input_output_name(), G_command_history(), G_copy_file(), G_debug(), G_distance_point_to_line_segment(), G_get_3dview(), G_get_cellhd(), G_get_projinfo(), G_get_projunits(), G_get_reclass(), G_is_null_value(), G_math_cholesky_decomposition(), G_math_pivot_create(), G_math_solver_cholesky(), G_open_cell_old(), G_parser(), G_plot_area(), G_plot_polygon(), G_put_3dview(), G_put_cell_title(), G_put_cellhd(), G_put_reclass(), G_quantize_fp_map(), G_quantize_fp_map_range(), G_raster_map_is_fp(), G_raster_map_type(), G_read_colors(), G_read_fp_range(), G_read_histogram(), G_read_history(), G_read_range(), G_read_raster_cats(), G_read_vector_cats(), G_round_fp_map(), G_set_fp_type(), G_set_null_value(), G_set_quant_rules(), G_set_window(), G_site_get(), G_site_get_head(), G_site_put_head(), G_sites_open_new(), G_system(), G_truncate_fp_map(), G_write_fp_range(), G_write_history(), G_write_quant(), G_write_range(), get_command(), gk_make_framesfromkeys(), gk_make_linear_framesfromkeys(), GK_update_frames(), Gp_load_sites(), Gp_set_color(), GPJ_ask_datum_params(), GPJ_get_datum_transform_by_name(), GPJ_grass_to_osr(), GPJ_osr_to_grass(), Gs_build_256lookup(), gs_err(), Gs_get_cat_label(), Gs_load_3dview(), GS_load_att_map(), Gs_loadmap_as_bitmap(), Gs_loadmap_as_char(), Gs_loadmap_as_float(), Gs_loadmap_as_int(), Gs_loadmap_as_short(), gs_malloc_lookup(), Gs_numtype(), Gs_pack_colors(), Gs_pack_colors_float(), gs_put_label(), GS_write_ppm(), GS_write_tif(), GS_write_zoom(), gsd_init_mpeg(), gsd_put_legend(), gsd_rot(), gsd_wall(), gsdrape_set_surface(), Gv_load_vect(), Gvl_load_colors_data(), I_fopen_group_file_append(), I_fopen_group_file_new(), I_fopen_group_file_old(), I_fopen_sigset_file_new(), I_fopen_sigset_file_old(), I_fopen_subgroup_file_append(), I_fopen_subgroup_file_new(), I_fopen_subgroup_file_old(), I_get_control_points(), I_get_target(), I_put_control_points(), IL_grid_calc_2d(), IL_interp_segments_2d(), IL_output_2d(), IL_vector_input_data_2d(), LIB_main(), wxnviz.Nviz::LoadSurface(), wxnviz.Nviz::LoadVector(), wxnviz.Nviz::LoadVolume(), main(), NetA_init_distinct(), NetA_init_timetable_from_db(), NetA_initialise_varray(), NetA_timetable_shortest_path(), Nviz_color_from_str(), Nviz_new_light(), Nviz_new_map_obj(), Nviz_set_focus_state(), open_g3d_file(), P_popmatrix(), P_pushmatrix(), parse_freetypecap(), pj_do_proj(), pj_do_transform(), pj_get_kv(), pj_get_string(), PNG_color(), process_command(), process_point(), PS_color(), read_coor(), read_datum_table(), read_ellipsoid_table(), read_file(), S_read(), segment_get_row(), segment_init(), segment_intersection_2d(), segment_intersection_2d_tol(), segment_pagein(), segment_pageout(), segment_put_row(), segment_seek(), segment_setup(), SimpleErrorMessage(), submit(), V1_read_next_line_ogr(), V2_close_ogr(), V2_open_old_ogr(), Vect__open_old(), Vect__read_head(), Vect__write_head(), Vect_add_dblink(), Vect_build_line_area(), Vect_build_nat(), Vect_build_ogr(), Vect_check_input_output_name(), Vect_cidx_open(), Vect_cidx_save(), Vect_close(), Vect_coor_info(), Vect_copy(), Vect_copy_map_lines(), Vect_copy_table_by_cats(), Vect_copy_tables(), Vect_default_field_info(), Vect_delete(), Vect_get_area_points(), Vect_get_area_points_geos(), Vect_get_dblink(), Vect_get_point_in_poly(), Vect_graph_shortest_path(), Vect_isle_find_area(), Vect_legal_filename(), Vect_level(), Vect_line_check_intersection(), Vect_line_segment(), Vect_map_add_dblink(), Vect_map_del_dblink(), Vect_merge_lines(), Vect_net_build_graph(), Vect_net_shortest_path(), Vect_open_new(), Vect_open_topo(), Vect_overlay_and(), Vect_read_dblinks(), Vect_rename(), Vect_save_spatial_index(), Vect_save_topo(), Vect_segment_intersection(), Vect_set_open_level(), Vect_set_varray_from_cat_list(), Vect_set_varray_from_cat_string(), Vect_set_varray_from_db(), Vect_str_to_cat_list(), Vect_write_dblinks(), and Vedit_modify_cats().
if | ( | G__name_is_fully_qualified(name, xname, xmapset) | ) |
sprintf | ( | buf2 | , |
"%s" | , | ||
G3D_CATS_ELEMENT | |||
) |
Referenced by bin_install(), binaries_exist(), check_dependencies(), check_extension(), D_check_map_window(), D_new_window(), D_reset_screen_window(), D_timestamp(), datetime_format(), db__copy_table(), db_convert_value_datetime_into_string(), db_convert_value_to_string(), db_create_index2(), db_dirent(), db_legal_tablename(), db_noproc_error(), db_print_error(), db_procedure_not_implemented(), db_read_dbmscap(), db_set_default_connection(), db_start_driver(), db_syserror(), db_table_to_sql(), DBFCreateLL(), DBFOpenLL(), delete_ext_html(), depstr(), deregister_entries_gisman(), deregister_entries_gisman2(), deregister_extension(), deregister_html(), dump_html(), E_edit_cats(), E_edit_cellhd(), E_edit_fp_cats(), E_edit_history(), ellipsoid_table_file(), exit_db(), exit_tmp(), F_generate(), F_open(), G3d_keySetDouble(), G3d_keySetInt(), G3d_makeMapsetMapDirectory(), G3d_maskFileExists(), G3d_openCellOldNoHeader(), G3d_readHistory(), G3d_removeColor(), G3d_writeCats(), G3d_writeHistory(), G__file_name(), G__file_name_misc(), G__get_window(), G__home(), G__location_path(), G__make_location(), G__make_mapset(), G__make_mapset_element_misc(), G__mapset_permissions2(), G__quant_export(), G__quant_import(), G__tempfile(), G__write_cats(), G_ask_datum_name(), G_ask_ellipse_name(), G_ask_proj_name(), G_available_mapsets(), G_command_history(), G_database_ellipse_name(), G_format_timestamp(), G_fully_qualified_name(), G_get_cellhd(), G_get_datumparams_from_projinfo(), G_get_raster_cat(), G_gishelp(), G_list(), G_llres_scan(), G_mask_info(), G_parser(), G_put_cell_title(), G_put_cellhd(), G_putenv(), G_quantize_fp_map(), G_quantize_fp_map_range(), G_rc_path(), G_read_colors(), G_read_fp_range(), G_read_range(), G_recursive_copy(), G_remove_colors(), G_round_fp_map(), G_short_history(), G_site_format(), G_truncate_fp_map(), G_unctrl(), G_write_colors(), G_write_fp_range(), G_write_quant(), G_write_range(), get_configure_options(), get_package_name(), GPJ_ask_datum_params(), GPJ_get_datum_transform_by_name(), GPJ_get_equivalent_latlong(), GPJ_osr_to_grass(), GS_get_cat_at_xy(), Gs_get_cat_label(), GS_get_val_at_xy(), gsd_put_legend(), gsd_scalebar(), I_cluster_begin(), I_find_subgroup(), I_find_subgroup_file(), I_fopen_signature_file_new(), I_fopen_signature_file_old(), I_fopen_sigset_file_new(), I_fopen_sigset_file_old(), I_fopen_subgroup_file_append(), I_fopen_subgroup_file_new(), I_fopen_subgroup_file_old(), I_list_group(), I_list_subgroup(), I_list_subgroups(), I_location_info(), I_new_signature(), if(), IL_check_at_points_2d(), IL_output_2d(), IL_resample_output_2d(), invent_pad(), list_binaries(), list_extensions(), main(), make_location(), make_mapset(), mkdir_s(), nc_fgets(), nc_fgets_html(), nc_fgets_nb(), NetA_init_timetable_from_db(), new_ext_html(), new_item(), new_submenu(), parse_freetypecap(), pj_get_kv(), pj_get_string(), query_extension(), R_parse_monitorcap(), read_datum_table(), read_ellipsoid_table(), register_entries_gisman(), register_entries_gisman2(), register_extension(), register_html(), restore(), restore_entries_gisman(), restore_html(), run_post(), S_read(), set_proj_lib(), show_details(), show_license(), SHPCreateLL(), SHPOpenLL(), source_clean(), source_install(), su(), submit(), test_install(), uninstall(), unpack_extension(), V1_open_new_nat(), V1_open_old_nat(), V2_close_ogr(), V2_open_old_ogr(), V__dump_window(), V_call(), V_clear(), Vect__init_head(), Vect__open_old(), Vect__read_head(), Vect__write_head(), Vect_cidx_open(), Vect_cidx_save(), Vect_close(), Vect_coor_info(), Vect_copy(), Vect_default_field_info(), Vect_delete(), Vect_get_column_names(), Vect_get_column_names_types(), Vect_get_column_types(), Vect_get_full_name(), Vect_hist_command(), Vect_legal_filename(), Vect_maptype_info(), Vect_open_new(), Vect_open_spatial_index(), Vect_open_topo(), Vect_read_dblinks(), Vect_save_spatial_index(), Vect_save_topo(), Vect_subst_var(), Vect_write_dblinks(), and wget_extension().
switch | ( | read_cats(name, mapset, pcats) | ) |
Definition at line 198 of file g3dcats.c.
Referenced by alloc_slice_buff(), and read_slice().
char buf2[200] |
Definition at line 89 of file g3dcats.c.
Referenced by E_edit_cellhd(), G3d_openCellOldNoHeader(), G3d_readHistory(), G3d_removeColor(), G3d_writeCats(), G3d_writeHistory(), G_is_reclassed_to(), G_put_reclass(), if(), read_ellipsoid_table(), Vect__open_old(), and Vect_default_field_info().
char buff[1024] |
Definition at line 89 of file g3dcats.c.
Referenced by D_check_map_window(), D_new_window(), D_reset_screen_window(), D_timestamp(), dig_read_frmt_ascii(), E_edit_cats(), E_edit_fp_cats(), G3d_readHistory(), G__raster_misc_read_line(), G__read_cats(), G_ask_colors(), G_ask_datum_name(), G_ask_ellipse_name(), G_ask_proj_name(), G_math_egvorder(), G_parser(), G_recreate_command(), GPJ_ask_datum_params(), GPJ_grass_to_osr(), GS_get_cat_at_xy(), GS_get_val_at_xy(), Gs_pack_colors(), gsd_coarse_surf_map(), gsd_fringe_horiz_line(), gsd_fringe_horiz_line2(), gsd_fringe_horiz_poly(), gsd_fringe_vert_line(), gsd_fringe_vert_poly(), gsd_norm_arrows(), gsd_put_legend(), gsd_surf_map(), gsd_surf_map_old(), gsd_wire_arrows(), gsd_wire_surf_map(), and Vect__read_head().
CELL cat |
Definition at line 90 of file g3dcats.c.
Referenced by dig_cidx_add_cat(), dig_cidx_add_cat_sorted(), G__insert_color_into_lookup(), G__lookup_colors(), G__read_cats(), G__row_update_range(), G_cell_stats_histo_eq(), G_extend_histogram(), G_find_cell_stat(), G_get_color(), G_histogram_eq(), G_histogram_eq_colors(), G_make_histogram_cs(), G_make_histogram_eq_colors(), G_make_histogram_log_colors(), G_read_histogram(), G_set_color(), G_site_get(), G_sort_histogram(), G_update_cell_stats(), G_update_range(), G_write_histogram(), G_write_histogram_cs(), Gp_set_color(), IL_check_at_points_2d(), IL_vector_input_data_2d(), NetA_get_node_costs(), NetA_initialise_varray(), Vect_cat_set(), Vect_cidx_dump(), Vect_get_line_cat(), Vect_net_build_graph(), Vect_set_varray_from_cat_list(), Vect_set_varray_from_db(), and Vedit_modify_cats().
else |
long num = -1 |
Definition at line 93 of file g3dcats.c.
Referenced by class_discont(), D_check_map_window(), dig_area_alloc_isle(), dig_area_alloc_line(), dig_isle_alloc_line(), dig_node_alloc_line(), G__read_cats(), G_init_cats(), G_math_pivot_create(), G_set_cat(), get_diag_intersects(), get_horz_intersects(), get_vert_intersects(), gk_follow_frames(), GS_getlight_ambient(), GS_getlight_color(), GS_getlight_position(), gs_los_intersect(), GS_setlight_ambient(), GS_setlight_color(), GS_setlight_position(), gs_setlos_enterdata(), GS_zoom_setup(), gsd_cplane_off(), gsd_cplane_on(), gsd_cplane_setrot(), gsd_cplane_settrans(), gsd_get_nice_range(), gvld_isosurf(), IL_resample_interp_segments_2d(), Nviz_draw_all_surf(), Nviz_init_light(), Nviz_new_fringe(), Nviz_new_light(), Nviz_set_fringe(), Nviz_set_light_ambient(), Nviz_set_light_bright(), Nviz_set_light_color(), Nviz_set_light_position(), order_intersects(), segs_intersect(), Vect_get_node_coor(), Vect_get_num_primitives(), and Vedit_select_by_query().
int old |
Definition at line 92 of file g3dcats.c.
Referenced by avl_t_replace(), free_datum_list(), free_ellps_list(), G__read_cats(), GPJ_ask_datum_params(), GPJ_get_default_datum_params_by_name(), GPJ_osr_to_grass(), I_cluster_reassign(), and tavl_t_replace().
return |
Definition at line 169 of file g3dcats.c.
Referenced by gvl_file_set_slices_param().
DCELL val1 |
Definition at line 91 of file g3dcats.c.
Referenced by G3d_writeCats(), G__read_cats(), G__write_cats(), G_get_ith_c_raster_cat(), G_get_ith_f_raster_cat(), G_get_ith_raster_cat(), G_get_next_marked_raster_cat(), and G_set_raster_cat().
DCELL val2 |
Definition at line 91 of file g3dcats.c.
Referenced by G3d_writeCats(), G__read_cats(), G__write_cats(), G_get_ith_c_raster_cat(), G_get_ith_f_raster_cat(), G_get_ith_raster_cat(), G_get_next_marked_raster_cat(), G_histogram_eq_colors_fp(), and G_set_raster_cat().
char xmapset |
Definition at line 89 of file g3dcats.c.
Referenced by G3d_openCellNew(), G3d_openCellOldNoHeader(), G3d_readHistory(), G3d_readRegionMap(), G3d_removeColor(), G3d_writeCats(), G3d_writeHistory(), G__check_fp_type(), G__file_name(), G__file_name_misc(), G__open_cell_old(), G__quant_export(), G__quant_import(), G_raster_map_is_fp(), G_raster_map_type(), G_remove_colors(), G_rename(), G_write_colors(), Vect__open_old(), Vect_copy(), and Vect_open_new().
char xname |
Definition at line 89 of file g3dcats.c.
Referenced by G3d_openCellNew(), G3d_openCellOldNoHeader(), G3d_readHistory(), G3d_readRegionMap(), G3d_removeColor(), G3d_writeCats(), G3d_writeHistory(), G__file_name(), G__file_name_misc(), G__open_cell_old(), G__quant_export(), G__quant_import(), G_put_reclass(), G_read_colors(), G_remove_colors(), G_rename(), G_write_colors(), if(), Vect__open_old(), and Vect_open_new().