adding more thumbs

This commit is contained in:
Patricio Gonzalez Vivo 2016-04-03 17:59:19 -04:00
parent 32c7fc1fe1
commit 0f4b59f2eb
16 changed files with 14 additions and 1 deletions

BIN
00/cmyk-halftone.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 344 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 46 KiB

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 40 KiB

BIN
08/matrix.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 581 KiB

BIN
09/diamondtiles.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

BIN
09/iching-01.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

BIN
09/marching_dots.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
10/ikeda-00.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

BIN
10/ikeda-03.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

BIN
10/ikeda-04.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

BIN
11/circleWave-noise.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 108 KiB

BIN
11/iching-03.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

BIN
11/lava-lamp.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

View File

@ -7,7 +7,20 @@ def injectShaderBlocks( _folder, _text ):
rta = ""
lines = _text.split('\n');
for line in lines:
if line.find('<div class=\"codeAndCanvas\"') >= 0:
if line.find('<canvas id=\"custom\" class=\"canvas\"') >= 0:
shaderFile = re.search("<canvas id=\"custom\" class=\"canvas\" data-fragment-url=\"(.*?)\"", line.rstrip(), re.S).group(1)
shaderName, shaderExt = os.path.splitext(shaderFile)
shaderPath = folder+"/"+shaderFile;
shaderString = open(shaderPath, 'r').read()
shaderImage = folder+"/"+shaderName+".png"
shaderCommand = "glslViewer " + shaderPath + " " + \
" -s 0.5 -o " + shaderImage
print shaderCommand
returnCode = subprocess.call(shaderCommand, shell=True)
elif line.find('<div class=\"codeAndCanvas\"') >= 0:
shaderTextureResults = re.findall(r'<div class=\"codeAndCanvas\" data=\".*\" data-imgs=\"(.*)\"></div>', line.rstrip())
shaderFile = re.sub(r'<div class=\"codeAndCanvas\" data=\"(.*?)\"(>| .+>)</div>', r'\1', line.rstrip())