wenyan-lang / book

文言陰符 An Introduction to Programming in Wenyan Language
https://book.wy-lang.org
Other
332 stars 41 forks source link

A brilliant idea #28

Open UtilityHotbar opened 3 years ago

UtilityHotbar commented 3 years ago

Can I ask how you generated the "authentic relic" edition? Just interested for my own purposes haha.

LingDong- commented 3 years ago

Hi, the code to produce it is in this file: https://github.com/wenyan-lang/book/blob/master/scripts/makeold.py

It uses openCV to add noise, blur, warp, grunge etc. to the plain version. The plain version is typeset using this script: https://github.com/wenyan-lang/book/blob/master/scripts/pdf.js

UtilityHotbar commented 3 years ago

Thanks! Is there anyway to make it not add the "spine" effect, where there is a line splitting the page in half and half is slightly warped? (and the faint inverted image overlay effect)

LingDong- commented 3 years ago

Hi,

I haven't touched the code for a while, perhaps the best way is to comment in/out the lines and just see if it's the effect you want :)

UtilityHotbar commented 3 years ago

Thanks for the help! I think the line you indicated for the central fold controls the colour channels, though. I'll keep messing with it. I think I might also write a transpiler from 白話 to 文言...