# Makefile para exercícios ESTÁTICOS de POV-Ray # Last edited on 2019-11-22 19:20:37 by jstolfi SHELL := /bin/bash # Runs POV-Ray on file "main.pov" to produce # image "main.png". # Image size: WIDTH := 800 HEIGHT := 800 # Should images be displayed automatically? SHOW := YES # Should filter error messages (0 or 1): FILTER := 1 # Will cast {NRAYS^2} rays per pixel: NRAYS := 2 # Directories where POV-Ray is installed: POVRAY := /usr/bin/povray POVINC := /usr/share/povray-3.7/include/ POVTTF := ../tools/ttf # ---------------------------------------------------------------------- NAME := main MAIN := main all: ${MAKE} image cat out/pieces.txt \ | draw_pieces.sh \ > out/cutting.txt cat out/cutting.txt clean:: -/bin/rm -f ${NAME}.png -/bin/rm -f ${NAME}-*.log ${NAME}.log -/bin/rm -f out/*.{txt,png,pdf} # ---------------------------------------------------------------------- # Auxiliary source files should be named "*.inc". # Image fiels used for textures etc. shoud be named "pic-*.png" or "pic-*.jpg". # Input files except "main.pov": INC_IMG_FILES := ${wildcard *.inc pic-*.{png,jpg,JPG} } OTHERINPUTS := \ ${shell echo ${INC_IMG_FILES} | tr ' ' '\012' | grep -v -e '${NAME}.(png|pov)'} # These are defined with "=" rather than ":=" in order to defer expansion DIRTAIL = ${shell pwd | sed -e 's:^.*/::'} # Full name of POV-ray executable: POVRAY := povray # Command to display resultin image: IMVIEW := display -title '%d/%f' include STATIC.make