File:  [Research Unix] / researchv8dc / cmd / map / libmap / conic.c
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 17:21:59 2018 UTC (8 years, 3 months ago) by root
Branches: belllabs, MAIN
CVS tags: researchv8, HEAD
researchv8 Dan Cross

#include "map.h"

struct coord stdpar;

Xconic(place, x, y)
struct place *place;
float *x, *y;
{
	float r;
	if(fabs(place->nlat.l-stdpar.l) > 80.*RAD)
		return(-1);
	r = stdpar.c/stdpar.s - tan(place->nlat.l - stdpar.l);
	*x = - r*sin(place->wlon.l * stdpar.s);
	*y = - r*cos(place->wlon.l * stdpar.s);
	if(r>3) return(0);
	return(1);
}

int (*conic(par))()
float par;
{
	extern Xcylindrical();
	if(fabs(par) <.1)
		return(Xcylindrical);
	deg2rad(par, &stdpar);
	return(Xconic);
}

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.