From: Rudolf Polzer Date: Wed, 14 Mar 2012 20:00:02 +0000 (+0100) Subject: add some QR code tests (not used by map yet) X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=9e5a3d596168dc05b9ff46db1b8befe0332aefef;p=xonotic%2Fxonotic-maps.pk3dir.git add some QR code tests (not used by map yet) --- diff --git a/scripts/map_augenkrebs.shader b/scripts/map_augenkrebs.shader index 51819e1c..2c88c9ed 100644 --- a/scripts/map_augenkrebs.shader +++ b/scripts/map_augenkrebs.shader @@ -474,3 +474,12 @@ textures/map_augenkrebs/tvsnow blendfunc filter } } +textures/map_augenkrebs/qranim +{ + nopicmip + nomipmaps + { + map textures/map_augenkrebs/qranim + tcmod page 4 3 0.05 + } +} diff --git a/textures/map_augenkrebs/qr-i.png b/textures/map_augenkrebs/qr-i.png new file mode 100644 index 00000000..0dcd1ef4 Binary files /dev/null and b/textures/map_augenkrebs/qr-i.png differ diff --git a/textures/map_augenkrebs/qr-m0.png b/textures/map_augenkrebs/qr-m0.png new file mode 100644 index 00000000..aac2436f Binary files /dev/null and b/textures/map_augenkrebs/qr-m0.png differ diff --git a/textures/map_augenkrebs/qr-m1.png b/textures/map_augenkrebs/qr-m1.png new file mode 100644 index 00000000..9c416c40 Binary files /dev/null and b/textures/map_augenkrebs/qr-m1.png differ diff --git a/textures/map_augenkrebs/qr-m2.png b/textures/map_augenkrebs/qr-m2.png new file mode 100644 index 00000000..aa10c155 Binary files /dev/null and b/textures/map_augenkrebs/qr-m2.png differ diff --git a/textures/map_augenkrebs/qr-m3.png b/textures/map_augenkrebs/qr-m3.png new file mode 100644 index 00000000..3231c846 Binary files /dev/null and b/textures/map_augenkrebs/qr-m3.png differ diff --git a/textures/map_augenkrebs/qr-r1.png b/textures/map_augenkrebs/qr-r1.png new file mode 100644 index 00000000..3e20f4fa Binary files /dev/null and b/textures/map_augenkrebs/qr-r1.png differ diff --git a/textures/map_augenkrebs/qr-r2.png b/textures/map_augenkrebs/qr-r2.png new file mode 100644 index 00000000..5a51ecd2 Binary files /dev/null and b/textures/map_augenkrebs/qr-r2.png differ diff --git a/textures/map_augenkrebs/qr-r3.png b/textures/map_augenkrebs/qr-r3.png new file mode 100644 index 00000000..80c535ed Binary files /dev/null and b/textures/map_augenkrebs/qr-r3.png differ diff --git a/textures/map_augenkrebs/qr.png b/textures/map_augenkrebs/qr.png new file mode 100644 index 00000000..d86337e7 Binary files /dev/null and b/textures/map_augenkrebs/qr.png differ diff --git a/textures/map_augenkrebs/qr.sh b/textures/map_augenkrebs/qr.sh new file mode 100644 index 00000000..0d33f625 --- /dev/null +++ b/textures/map_augenkrebs/qr.sh @@ -0,0 +1,44 @@ +urls=' +http://youtu.be/oJwcRyf5XZM +http://youtu.be/1ZbOD-yVTxw +http://youtu.be/gxc-kREijH4 +http://youtu.be/9ufjRoidV_E +http://youtu.be/SmpITVtnMXk +http://youtu.be/Pvkj3PfO4gM,http://youtu.be/kfVsfOSbJY0 +' + +makeqr() +{ + echo "$4" | qrencode -o "$1" -l H -s 14 -m 0 + mogrify -mattecolor white $2 -frame $((256 - `identify -format %w "$1"` / 2)) $3 "$1" + optipng -o7 -nc "$1" +} + +makeqr qr.png "" "" "https://pzt.me/8o8s" +makeqr qr-i.png "" "-negate" "https://pzt.me/072d" +# numbered by location of small dot: 3 2 1 0 +makeqr qr-m0.png "" "-transpose" "https://pzt.me/654q" +makeqr qr-m1.png "" "-flop" "https://pzt.me/654q" +makeqr qr-m2.png "" "-flip" "https://pzt.me/654q" +makeqr qr-m3.png "" "-transpose -flip -flop" "https://pzt.me/654q" +makeqr qr-r1.png "" "-flip -transpose" "https://pzt.me/4tfi" +makeqr qr-r2.png "" "-flop -transpose" "https://pzt.me/4tfi" +makeqr qr-r3.png "" "-flip -flop" "https://pzt.me/4tfi" + +i=0 +for u in $urls; do + i=$(($i+1)) + makeqr qr-$i.png "" "" ${u%%,*} + makeqr qr-${i}_i.png "" "-negate" ${u%%,*} +done + +l= +j=0 +while [ $j -lt $i ]; do + j=$(($j+1)) + l="$l qr-$j.png qr-$((($j-1+$i/2)%$i+1))_i.png" +done +convert -delay 10 $l qranim.gif +montage -border 0 -frame 0 -geometry +0+0 $l qranim.png +optipng -o7 -nc qranim.png +rm -f $l diff --git a/textures/map_augenkrebs/qranim.png b/textures/map_augenkrebs/qranim.png new file mode 100644 index 00000000..9af06c1a Binary files /dev/null and b/textures/map_augenkrebs/qranim.png differ