Loading...
Searching...
No Matches
gsd_wire.c File Reference

OGSF library -. More...

`#include <grass/gis.h>`
`#include <grass/ogsf.h>`
`#include "gsget.h"`
`#include "rowcol.h"`
Include dependency graph for gsd_wire.c:

Go to the source code of this file.

## Macros

#define | DO_ARROWS

## Functions

int | gsd_wire_surf (geosurf *surf)
| Draw surface wire.
int | gsd_wire_surf_map (geosurf *surf)
| ADD.
int | gsd_wire_surf_const (geosurf *surf, float k)
| ADD.
int | gsd_wire_surf_func (geosurf *gs, int(*user_func)(void))
| ADD.
int | gsd_wire_arrows (geosurf *surf)
| ADD.
int | gsd_coarse_surf_map (geosurf *surf)
| Draw coarse surface.

## Detailed Description

OGSF library -.

GRASS OpenGL gsurf OGSF Library

(C) 1999-2008 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.

Author
  Bill Brown USACERL (January 1993)
  Doxygenized by Martin Landa <landa.martin gmail.com> (May 2008)

Definition in file gsd_wire.c.

## Macro Definition Documentation

## DO_ARROWS

#define DO_ARROWS

Definition at line 25 of file gsd_wire.c.

## Function Documentation

## gsd_coarse_surf_map()

int gsd_coarse_surf_map | ( | geosurf * | surf | ) |

Draw coarse surface.

New (TEST) wire routine that draws low res surface Based on new Triangle Fan routine Resolution is a function of current surface resolution times wire resolution

Todo
  normals have to be recalculated before proper low res surface can be drawn

In window optimization has been removed

Parameters

  surf | surface (geosurf)

Returns

Definition at line 572 of file gsd_wire.c.

References FNORM, GET_MAPATT, gs_calc_normals(), gs_get_att_typbuff(), GS_get_scale(), GS_global_exag(), gs_mapcolor(), gs_update_curmask(), gsd_bgntfan(), gsd_blend(), gsd_colormode(), gsd_do_scale(), gsd_endtfan(), gsd_litvert_func(), gsd_popmatrix(), gsd_pushmatrix(), gsd_set_material(), gsd_surf_const(), gsd_translate(), gsd_zwritemask(), SCALE_ATT, VCOLS, VROWS, X, and Y.

Referenced by gsd_wire_surf().

## gsd_wire_arrows()

int gsd_wire_arrows | ( | geosurf * | surf | ) |

ADD.

Need to do Zexag scale of normal for arrow direction, drawing routine unexags z for arrow

Parameters

  surf | surface (geosurf)

Returns

Definition at line 457 of file gsd_wire.c.

References BM_get(), FNORM, G_debug(), GET_MAPATT, gs_get_att_typbuff(), GS_get_scale(), GS_global_exag(), gs_mapcolor(), gs_update_curmask(), gsd_arrow(), gsd_colormode(), gsd_do_scale(), gsd_popmatrix(), gsd_pushmatrix(), gsd_translate(), X, and Y.

## gsd_wire_surf()

int gsd_wire_surf | ( | geosurf * | surf | ) |

Draw surface wire.

Parameters

  surf | surface (geosurf)

Returns

Definition at line 46 of file gsd_wire.c.

References G_debug(), gs_get_att_src(), gsd_coarse_surf_map(), gsd_wire_surf_const(), gsd_wire_surf_func(), and gsd_wire_surf_map().

Referenced by GS_alldraw_wire(), GS_draw_surf(), and GS_draw_wire().

## gsd_wire_surf_const()

int gsd_wire_surf_const | ( | geosurf * | surf,
|  | float | k )

ADD.

Parameters

  surf | surface (geosurf)
  k |

Returns

Definition at line 276 of file gsd_wire.c.

References BM_get(), G_debug(), gs_get_att_typbuff(), gs_mapcolor(), gs_update_curmask(), gsd_bgnline(), gsd_color_func(), gsd_colormode(), gsd_do_scale(), gsd_endline(), gsd_popmatrix(), gsd_pushmatrix(), gsd_translate(), gsd_vert_func(), gsdiff_do_SD(), gsdiff_get_SDref(), NULL, X, and Y.

Referenced by gsd_wire_surf().

## gsd_wire_surf_func()

int gsd_wire_surf_func | ( | geosurf * | gs,
|  | int(* | user_func )(void) )

ADD.

Not yet implemented.

Parameters

  gs | surface (geosurf) [unused]
  user_func | user defined function [unused]

Returns
  1

Definition at line 442 of file gsd_wire.c.

Referenced by gsd_wire_surf().

## gsd_wire_surf_map()

int gsd_wire_surf_map | ( | geosurf * | surf | ) |

ADD.

Parameters

  surf | surface (geosurf)

Returns

Definition at line 99 of file gsd_wire.c.

References BM_get(), G_debug(), GET_MAPATT, gs_get_att_typbuff(), gs_mapcolor(), gs_update_curmask(), gsd_bgnline(), gsd_color_func(), gsd_colormode(), gsd_do_scale(), gsd_endline(), gsd_popmatrix(), gsd_pushmatrix(), gsd_translate(), gsd_vert_func(), X, and Y.

Referenced by gsd_wire_surf().