Last active
December 16, 2015 01:09
-
-
Save CLCL/5352678 to your computer and use it in GitHub Desktop.
Illustatorないから動くかどうかはわからんけれども、aとbとiとmColorとtObjにvarをつけたくなる病を患ったので/うちに帰って動かしてみたらちゃんと動いた。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// オリジナルは、http://www.iwashi.org/archives/2540 | |
(function(){ | |
var start = new Date().getTime(); | |
documents.add( DocumentColorSpace.RGB, 3370, 2284 ); | |
var mColor = new RGBColor(); | |
for ( var b = 0; b < 16; b++ ) { | |
mColor.red = b * 14; | |
mColor.green = b * 12; | |
mColor.blue = b * 10; | |
for ( var i = 0; i < 19266; i++ ) { | |
var a = Math.floor( i / 114 ) | |
var tObj = activeDocument.pathItems | |
.rectangle( | |
b + 20 + ( i - a * 114 ) * 20, | |
b + a * 20, | |
4, | |
4 | |
); | |
tObj.filled = true; | |
tObj.stroked = false; | |
tObj.fillColor = mColor; | |
} | |
} | |
activeDocument.views[0].zoom = 0.1; | |
activeDocument.views[0].zoom = 2; | |
var end = new Date().getTime(); | |
prompt("結果", end - start); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment