ccdemos/Makefile
author Radek Brich <radek.brich@devl.cz>
Thu, 13 Dec 2007 00:08:11 +0100
branchpyrit
changeset 36 b490093b0ac3
parent 29 574c34441a1c
child 39 7079dcc3bd74
permissions -rw-r--r--
new virtual Shape::intersect_bbox implementation of triangle-AABB intersection octree building updated and simplified with help of this new method octree made default for Python, it's currently much faster than kd-tree (both building and traversal)

ifndef $(ROOT)
	ROOT=$(shell pwd)/..
endif

include $(ROOT)/config.mk


### Targets ###
all: realtime realtime_dragon realtime_bunny spheres_shadow

realtime: realtime.o libs-double
	$(CXX) -o $@ $(ROOT)/bin/libs-double/*.o $< $(LDFLAGS) $(SDL_LDFLAGS)

realtime_dragon: realtime_dragon.o libs-double
	$(CXX) -o $@ $(ROOT)/bin/libs-double/*.o $< $(LDFLAGS) $(SDL_LDFLAGS)

realtime_bunny: realtime_bunny.o libs-double
	$(CXX) -o $@ $(ROOT)/bin/libs-double/*.o $< $(LDFLAGS) $(SDL_LDFLAGS)

spheres_shadow: spheres_shadow.o image.o libs-float
	$(CXX) -o $@ $(ROOT)/bin/libs-float/*.o $< image.o $(LDFLAGS) -lpng

libs-float:
	$(MAKE) -C ../src libs-float

libs-double:
	$(MAKE) -C ../src libs-double

realtime.o: realtime.cc
	$(CXX) -c -o $@ $(CCFLAGS) $(SDL_CCFLAGS) $< $(DEFS) -DPYRIT_DOUBLE

realtime_dragon.o: realtime_dragon.cc
	$(CXX) -c -o $@ $(CCFLAGS) $(SDL_CCFLAGS) $< $(DEFS) -DPYRIT_DOUBLE

realtime_bunny.o: realtime_bunny.cc
	$(CXX) -c -o $@ $(CCFLAGS) $(SDL_CCFLAGS) $< $(DEFS) -DPYRIT_DOUBLE

image.o: image.c
	$(CXX) -c -o $@ $*.c

spheres_shadow.o: spheres_shadow.cc
	$(CXX) -c -o $@ $*.cc $(CCFLAGS) $(DEFS)

clean:
	rm -f spheres_shadow realtime realtime_dragon realtime_bunny *.o