POVRAYOPT = -l/local/opt/povray/include
TRACE = /local/opt/povray/bin/povray $(POVRAYOPT)
RM = /bin/rm

TARGET =  csg.pov
all:: super 

top.ppm: $(TARGET)
	-$(TRACE) +FT -i$(TARGET) -w150 -h150 +Ofoo.tga

super.ppm: $(TARGET)
	-$(TRACE)  -a0.2 -i$(TARGET) -w300 -h300 +ft +ofoo.tga 
	
super: super.ppm

duper.tga: $(TARGET)
	-$(TRACE)  -a0.2 -i$(TARGET) -w600 -h600 +ft +oduper.tga 
	
duper: duper.tga


view: top.ppm
	true "tgatoppm top.out | ppmquant -fs 256 | ppmtogif > top.gif"
	xview top.ppm

topquick.ppm: $(TARGET)
	-$(TRACE) -i$(TARGET) -w100 -h100 -q9 +ofoo.tga +FT +d

qv: topquick.ppm
	true "tgatoppm topquick.out | ppmquant -fs 256 | ppmtogif >topquick.gif"
	xview topquick.ppm

quick.out: $(TARGET)
	-$(TRACE) +FT -i$(TARGET) -oquick.out -w300 -h300 -q3 +ofoo.tga

quick: quick.out
	tgatoppm quick.out | xview stdin

clean:
	$(RM) -f a b *.o output.test *.out *.pnm ourshapes.dat
