9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* Stars (was: CD-ROM music)
@ 1995-09-20  8:34 Amos
  0 siblings, 0 replies; only message in thread
From: Amos @ 1995-09-20  8:34 UTC (permalink / raw)


dmr@plan9.ATt.COM writes:

>Speaking of play-value, has anyone gotten themselves far enough
>out of VGA hell to try the sky catalog or the geographic/road
>databases?

Here's a filter to "astro"'s output which uses "plot" to draw a
picture of the sky; now all we need is to add that to "scat"'s output,
or teach "astro" to present current star positions (it does read the
star catalog to check for occultations, but doesn't present position
info).

#!/bin/rc
# << doesn't work inside {}
{
echo 'o
ra -90 -90 90 90
e
ci 0 0 90
li -90 0 90 0
li 0 -90 0 90
m 0 -88
t \CS
m 0 88
t \CN
m -88 0
t \CE
m 88 0
t \CW
'
astro -p $* |
awk 'NR>1{
	if(NF==6) { name=$1; a=$4; e=$5 }
	else { name=$2; a=$5; e=$6 }
	if(e >=0) {
		a = a*3.14159/180
		print "m", (e-90)*sin(a), (90-e)*cos(a)
		print "t *" name
	}
}
END {print "cl"}'
} |
plot
--
	Amos Shapir		Net: amos@nsof.co.il
Paper: nSOF Parallel Software, Ltd.
       Givat-Hashlosha 48800, Israel
Tel: +972 3 9388551   Fax: +972 3 9388552        GEO: 34 55 15 E / 32 05 52 N






^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1995-09-20  8:34 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1995-09-20  8:34 Stars (was: CD-ROM music) Amos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).