17#if defined(OPENGL_X11) || defined(OPENGL_WINDOWS)
20#elif defined(OPENGL_AQUA)
22#include <OpenGL/glu.h>
112 (
double)
gd->nearclip, (
double)
gd->farclip);
119 glRotatef((
float)(
gv->twist / 10.), 0.0, 0.0, 1.0);
123 (
double)
gv->from_to[
FROM][
Z], (
double)
gv->from_to[
TO][
X],
124 (
double)
gv->from_to[
TO][
Y], (
double)
gv->from_to[
TO][
Z],
125 (
double)up[
X], (
double)up[
Y], (
double)up[
Z]);
161 (
double)
gd->nearclip, (
double)
gd->farclip);
168 glRotatef((
float)(
gv->twist / 10.), 0.0, 0.0, 1.0);
172 (
double)
gv->from_to[
FROM][
Z], (
double)
gv->from_to[
TO][
X],
173 (
double)
gv->from_to[
TO][
Y], (
double)
gv->from_to[
TO][
Z],
174 (
double)up[
X], (
double)up[
Y], (
double)up[
Z]);
177 if (
gv->rotate.do_rot) {
183 gv->rotate.rot_axes[1],
gv->rotate.rot_axes[2]);
186 for (i = 0; i < 16; i++) {
220 gv->from_to[
TO][
Z] -= zmin;
222 gv->from_to[
TO][
Z] *=
gv->vert_exag;
277 pi = 4.0 *
atan(1.0);
372 float min,
max, n, s, w, e;
377 point[
X] = (point[
X] - w) * sx;
378 point[
Y] = (point[
Y] - s) * sy;
379 point[
Z] = (point[
Z] -
min) * sz;
392 float min,
max, n, s, w, e;
397 point[
X] = (sx ? point[
X] / sx : 0.0) + w;
398 point[
Y] = (sy ? point[
Y] / sy : 0.0) + s;
399 point[
Z] = (sz ? point[
Z] / sz : 0.0) +
min;
412 float min,
max, sx, sy, sz;
423 point[
Z] = (sz ? point[
Z] / sz : 0.0) +
min;
426 point[
X] = (sx ? point[
X] / sx : 0.0);
427 point[
Y] = (sy ? point[
Y] / sy : 0.0);
440 float min,
max, sx, sy, sz;
446 point[
Z] = (sz ? (point[
Z] -
min) * sz : 0.0f);
449 point[
X] = (sx ? point[
X] * sx : 0.0f);
450 point[
Y] = (sy ? point[
Y] * sy : 0.0f);
void GS_v3mult(float *, float)
Multiple vectors.
int GS_get_region(float *, float *, float *, float *)
Get 2D region extent.
void GS_set_draw(int)
Sets which buffer to draw to.
void gsd_scale(float, float, float)
Multiply the current matrix by a general scaling matrix.
double GS_get_aspect(void)
Get aspect value.
int GS_get_zrange(float *, float *, int)
Get z-extent for all loaded surfaces.
int GS_v3normalize(float *, float *)
Change v2 so that v1v2 is a unit vector.
int gs_get_datacenter(float *)
Get data center point.
void GS_v3eq(float *, float *)
Copy vector values.
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_linewidth(short)
Set width of rasterized lines.
void GS_get_scale(float *, float *, float *, int)
Get axis scale.
int GS_v3dir(float *, float *, float *)
Get a normalized direction from v1 to v2, store in v3.
float GS_distance(float *, float *)
Calculate distance.
void gsd_update_cplanes(void)
Update cplaces.
void gsd_real2model(Point3 point)
Convert real to model coordinates.
void gsd_surf2real(geosurf *gs, Point3 point)
Convert surface to real coordinates.
void gsd_check_focus(geoview *gv)
Check focus.
int gsd_zup_twist(geoview *gv)
ADD.
int gsd_get_los(float(*vect)[3], short sx, short sy)
ADD.
void gsd_real2surf(geosurf *gs, Point3 point)
Convert real to surface coordinates.
void gsd_surf2model(Point3 point)
Convert surface to model coordinates.
void gsd_model2real(Point3 point)
Convert model to real coordinates.
void gsd_model2surf(geosurf *gs, Point3 point)
Convert model to surface coordinates.
void gsd_do_scale(int doexag)
Set current scale.
void gsd_get_zup(geoview *gv, double *up)
Get z-up vector (z-direction)
void gsd_set_view(geoview *gv, geodisplay *gd)
Set view.
OGSF header file (structures)