diff --git a/.gitignore b/.gitignore index f322dfc..5863a25 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ -handbook \ No newline at end of file +handbook +pdf/*handbook* \ No newline at end of file diff --git a/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE.md b/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE.md index c4c3d55..5095997 100644 --- a/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE.md +++ b/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE.md @@ -51,6 +51,9 @@ date: "March 1983" | [Other Fades](#other-fades) | 16 | [Ritual and Art](#ritual-and-art) | 35 | ::: +::: {.indexTableEnd} +::: + \newpage \pagenumbering{arabic} @@ -1173,6 +1176,8 @@ Example of a joint color and brightness test: > Each line in the chart represents CC filtration to be added to an initial guess of the right CC's. At each line make a series of ND variations surrounding an initial guess of the right ND. Perhaps the guess -.50, -.40, -.30, -.20, -.10, the guese itself, +.10, +.20, and +.30. The series is lopsided because the CC filtrations are all added to the CC guess. The 37 CC variations X the 9 ND variations = a 333 frame test. +::: {.ymcTable} + | Y | M | C | |-----|-----|-----| | 0 | 0 | 0 | @@ -1213,6 +1218,8 @@ test. | 30 | 20 | 0 | | 30 | 30 | 0 | +::: + **** A joint color and brightness test is a net spread over the logical region around an initial guesea, to catch the right exposure. diff --git a/build_handbook.sh b/build_handbook.sh new file mode 100644 index 0000000..918c05e --- /dev/null +++ b/build_handbook.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +convert "handbook/zine_*.jpg" -quality 100 ./pdf/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE_handbook.pdf \ No newline at end of file diff --git a/compile_handbook.sh b/compile_handbook.sh index 716f9be..bff0549 100644 --- a/compile_handbook.sh +++ b/compile_handbook.sh @@ -11,13 +11,40 @@ if [ ! -f ./handbook/cmunrm.otf ]; then cd .. fi +HANDBOOK="./handbook" TMP_HTML="$(realpath ./handbook/index.html)" HTML="html/index.html" LAYOUT_PDF="handbook/layout.pdf" +BODY_HTML="handbook/body.html" +INDEX_TABLE_HTML="$(cat ./tmpl/handbook_index.html)" + +rm -f "${BODY_HTML}" + +WRITING=0 +INDEX_TABLE=0 + +while read p; do + if [ ${WRITING} -eq 0 ] && [[ "${p}" == *"
"* ]]; then + WRITING=1 + fi + if [ ${WRITING} -eq 1 ] && [[ "${p}" == *""* ]]; then + WRITING=0 + fi + if [ ${INDEX_TABLE} -eq 0 ] && [[ "${p}" == *"class=\"indexTable\""* ]]; then + INDEX_TABLE=1 + echo "${INDEX_TABLE_HTML}" >> "${BODY_HTML}" + fi + if [ ${INDEX_TABLE} -eq 1 ] && [[ "${p}" == *""* ]]; then + INDEX_TABLE=0 + fi + if [ ${WRITING} -eq 1 ] && [ ${INDEX_TABLE} -eq 0 ]; then + echo "$p" >> "${BODY_HTML}" + fi +done < "${HTML}" BODY_VAR="{{BODY_HTML}}" TMPL_HTML=`cat tmpl/layout.html.tmpl` -BODY_CONTENT=`cat "${HTML}"` +BODY_CONTENT=`cat "${BODY_HTML}"` FONT=`cat handbook/cmunrm.txt | tr -d '\n'` BODY_CONTENT="${BODY_CONTENT//.svg/.jpg}" @@ -37,8 +64,27 @@ chromium-browser \ cd handbook +rm -f page-*.jpg + #convert -density 600 "../${LAYOUT_PDF}" -quality 90 page-%3d.jpg -#pdftoppm "../${LAYOUT_PDF}" page -jpeg -rx 600 -ry 600 +pdftoppm "../${LAYOUT_PDF}" page -jpeg -rx 600 -ry 600 + +convert -size 5100x6601 xc:white blank.jpg + +cp blank.jpg page-0.jpg +cp blank.jpg page-00.jpg + +pages=`ls page-*.jpg` +i=-1 +for page in $pages +do + #5100x6601 + if [ ${i} -gt 0 ]; then + echo "Numbering [$i] $page" + convert "${page}" -gravity North -pointsize 180 -draw 'text 0,6450 "'${i}'"' "${page}" + fi + let i=i+1 +done cd .. #rm -f "${TMP_HTML}" diff --git a/pdf/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE.pdf b/pdf/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE.pdf index 1c8f417..95e3307 100644 Binary files a/pdf/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE.pdf and b/pdf/NOTES_ON_OPTICAL_PRINTER_TECHNIQUE.pdf differ diff --git a/tmpl/handbook_index.html b/tmpl/handbook_index.html new file mode 100644 index 0000000..0b74002 --- /dev/null +++ b/tmpl/handbook_index.html @@ -0,0 +1,241 @@ +