42 float top, bottom, left, right;
58 return (
bgn[
X] >= left &&
bgn[
X] <= right && end[
X] >= left &&
59 end[
X] <= right &&
bgn[
Y] >= bottom &&
bgn[
Y] <= top &&
60 end[
Y] >= bottom && end[
Y] <= top);
83 float zmin, zmax,
fudge;
88 G_debug(5,
"gvd_vect(): id=%d",
gv->gvect_id);
99 fudge = (zmax - zmin) / 500.;
125 if (!
gv->fastlines) {
136 G_debug(5,
"gvd_vect(): type = %d dims = %d",
gln->type,
gln->dims);
147 if (
gln->highlighted > 0) {
151 else if (
gv->tstyle &&
gv->tstyle->active) {
163 if (
gln->dims == 2 || !
gv->use_z) {
164 G_debug(5,
"gvd_vect(): 2D vector line");
165 for (k = 0; k <
gln->npts - 1; k++) {
166 if (
gln->dims == 3) {
169 end[
X] =
gln->p3[k + 1][
X] +
gv->x_trans -
gs->ox;
170 end[
Y] =
gln->p3[k + 1][
Y] +
gv->y_trans -
gs->oy;
175 end[
X] =
gln->p2[k + 1][
X] +
gv->x_trans -
gs->ox;
176 end[
Y] =
gln->p2[k + 1][
Y] +
gv->y_trans -
gs->oy;
183 for (i = 0,
j = 0; i < npts; i++) {
192 points[i][
Z] +=
gv->z_trans;
222 G_debug(5,
"gvd_vect(): 3D vector line");
226 for (k = 0; k <
gln->npts; k++) {
242 if (
gln->dims == 3) {
243 G_debug(5,
"gvd_vect(): draw 3D polygon");
246 if (
gln->npts >= 3) {
265 for (k = 0; k <
gln->npts; k++) {
308 for (i = 0,
j = 0; i < npts; i++) {
void G_free(void *)
Free allocated memory.
int G_debug(int, const char *,...) __attribute__((format(printf
int gs_point_is_masked(geosurf *, float *)
Check if point is masked.
int gv_decimate_lines(geovect *)
Decimate line.
void gsd_pushmatrix(void)
Push the current matrix stack.
void gsd_do_scale(int)
Set current scale.
int gs_get_zrange(float *, float *)
Get z-range.
int gs_get_att_src(geosurf *, int)
Get attribute source.
Point3 * gsdrape_get_segments(geosurf *, float *, float *, int *)
ADD.
int gs_update_curmask(geosurf *)
Update current maps.
void gsd_color_func(unsigned int)
Set current color.
void gsd_translate(float, float, float)
Multiply the current matrix by a translation matrix.
void gsd_popmatrix(void)
Pop the current matrix stack.
void gsd_linewidth(short)
Set width of rasterized lines.
void gsd_endline(void)
End line.
void gsd_colormode(int)
Set color mode.
void GS_get_scale(float *, float *, float *, int)
Get axis scale.
void gsd_bgnline(void)
Begin line.
void gsd_vert_func(float *)
ADD.
int GS_check_cancel(void)
Check for cancel.
void gvd_draw_lineonsurf(geosurf *gs, float *bgn, float *end, int color)
Draw line on surface.
int gvd_vect(geovect *gv, geosurf *gs, int do_fast)
Draw vector set.
int gs_clip_segment(geosurf *gs, float *bgn, float *end, float *region)
Clip segment.
OGSF header file (structures)