
{"id":426,"date":"2008-08-06T09:00:01","date_gmt":"2008-08-06T08:00:01","guid":{"rendered":"http:\/\/www.matthijskamstra.nl\/blog\/?p=426"},"modified":"2012-06-22T23:30:58","modified_gmt":"2012-06-22T22:30:58","slug":"shape-2-array-jsfl","status":"publish","type":"post","link":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/","title":{"rendered":"Shape 2 Array jsfl"},"content":{"rendered":"<p>For a project of mine: <a href=\"http:\/\/www.matthijskamstra.nl\/blog\/index.php\/category\/design\/custmm-grumm-design\/\">Custmm Grumm<\/a> I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code.<\/p>\n<p>As far as I know there is no other method then the one I created here with jsfl.<\/p>\n<p>To make this happen I imported the .AI file (Illustrator) to the stage.<br \/>\n<a href=\"http:\/\/www.matthijskamstra.nl\/blog\/wp-content\/uploads\/importaiintoflash.jpg\" rel=\"flashbox\" title=\"Import screen from Flash\"><img decoding=\"async\" src=\"http:\/\/www.matthijskamstra.nl\/blog\/wp-content\/uploads\/importaiintoflash.jpg\" alt=\"Flash import screen\" title=\"Import .AI into Flash\" width=\"500\" class=\"alignnone size-medium wp-image-427\" srcset=\"https:\/\/www.matthijskamstra.nl\/blog\/wp-content\/uploads\/importaiintoflash.jpg 766w, https:\/\/www.matthijskamstra.nl\/blog\/wp-content\/uploads\/importaiintoflash-300x227.jpg 300w\" sizes=\"(max-width: 766px) 100vw, 766px\" \/><\/a><\/p>\n<p>This JSFL files has some restrictions, you can read it in the comments:<\/p>\n<blockquote><p>\nthis script only works under certain conditions:<br \/>\n&#8211; everything that is selected must be shapes, if not, this doesn&#8217;t work (select all and ctrl+b (break))<br \/>\n&#8211; every shape has to be in a different layer, otherwise the script see it as one shape\n<\/p><\/blockquote>\n<div class='highlight'>The result of this jsfl is not always what you expect&#8230;<br \/>\nsometimes geometric shapes like squares\/rectangles\/triangles are all f#$%ed-up (it looks like curves are made to opposite corners)<br \/>\nI have no solution for that in this jsfl (in the code), it seems that Flash &#8216;reads&#8217; the shape wrong (or in the wrong order)&#8230;<br \/>\nBut you could try: \t<\/p>\n<ul>\n<li>I used the straighten tool which worked in one case, but not in the other <\/li>\n<li>rotated a square 90 degrees <\/li>\n<li>both solutions<\/li>\n<\/ul>\n<\/div>\n<p>I&#8217;m not making an install file, so if you want to try this script you need to copy it in the correct directory (I&#8217;m sorry for the OsX users: I have no idea, but if you do, place a comment)<br \/>\n<strong>Windows (on my computer): <\/strong> C:\\Documents and Settings\\<strong>[here you name]<\/strong>\\Local Settings\\Application Data\\Adobe\\Flash CS3\\en\\Configuration\\Commands<\/p>\n<p>here is the JSFL (if you need to give it a name; I have a suggestion: &#8220;[mck] shape2array 2.jsfl&#8221;)<\/p>\n<pre class=\"brush: as3; title: ; notranslate\" title=\"\">\r\n\/**\r\n*\r\n* this script only works under certain conditions:\r\n*\t\t- everything that is selected must be shapes, if not, this doesn't work (select all and ctrl+b (break))\r\n* \t\t- every shape has to be in a different layer, otherwise the script see it as one shape \r\n*\r\n* The result of this jsfl is not always what you expect...\r\n* \t\tsometimes geometric shapes like squares\/rectangles\/triangles are all f#$%ed-up (it looks like curves are made to opposite corners)\r\n* \t\tI have no solution for that in this jsfl (in the code), it seems that Flash 'reads' the shape wrong (or in the wrong order)... \r\n*\t\tBut you could try: \t- I used the straighten tool which worked in one case, but not in the other \r\n*\t\t\t\t\t\t- rotated a square 90 degrees \r\n*\t\t\t\t\t\t- both solutions \r\n*\r\n*\r\n* \r\n* based upon \t\thttp:\/\/ericlin2.tripod.com\/bugwire\/bugwiret.html\r\n* and\t\t\thttp:\/\/livedocs.adobe.com\/flash\/9.0\/main\/wwhelp\/wwhimpl\/common\/html\/wwhelp.htm?context=LiveDocs_Parts&amp;file=00003869.html\r\n*\r\n* &lt;pre&gt;\r\n*  ____                   _      ____\r\n* |  __| _ __ ___    ___ | | __ |__  |\r\n* | |   | '_ ` _ \\  \/ __|| |\/ \/    | |\r\n* | |   | | | | | || (__ |   &lt;     | |\r\n* | |__ |_| |_| |_| \\___||_|\\_\\  __| |\r\n* |____|                        |____|\r\n*\r\n* &lt;\/pre&gt;\r\n*\r\n*\r\n* @author\t\t\tMatthijs C. Kamstra &#x5B;mck]\r\n* @version\t\t1.1\r\n* @since\t\t\t10:00 5-5-2008\r\n*\r\n* Changelog:\r\n* \t\tv1.1 &#x5B;2008-05-09] - test movie after use of this jsfl\r\n* \t\tv1.0 &#x5B;2008-05-05] - Initial release\r\n*\r\n*\r\n*\/\r\nvar currentVersion = '1.1';\r\n\r\nfl.trace ('&#x5B;mck] shape2Array :: version ' + currentVersion);\r\n\r\n\/\/ with a shape selected\r\nvar ptArray = &#x5B;];\r\nvar doneEdge = &#x5B;];\r\nvar exportString = 'var shapeArrayz:Array = new Array ();\\n';\r\nvar selectionNumber = 0;\r\n\r\n\/\/ fl.trace(&quot;\/\/ start ---------------------------&quot;);\r\nfunction isDrawn(id) {\r\n\tfor (var k = 0; k&lt;doneEdge.length; k++) {\r\n\t\tif (doneEdge&#x5B;k] == id) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t}\r\n\treturn false;\r\n}\r\n\r\n\r\nsel = fl.getDocumentDOM().selection;\r\nfor (var n = 0; n &lt; sel.length; n++) {\r\n\r\n\texportString += 'shapeArrayz&#x5B;'+n+'] = &#x5B;';\r\n\tselectionNumber = sel.length;\r\n\t\r\n\tvar elt = sel&#x5B;n];\r\n\tif (elt.elementType != 'shape') {\r\n\t\tcontinue;\r\n\t}\r\n\telt.beginEdit();\r\n\tfor (i=0; i&lt;elt.contours.length; i++) {\r\n\t\tvar cont = elt.contours&#x5B;i];\r\n\t\tvar he = cont.getHalfEdge();\r\n\t\tvar startId = he.id;\r\n\t\tvar id = 0;\r\n\t\twhile (id != startId) {\r\n\t\t\tvar ed = he.getEdge();\r\n\t\t\tif (!isDrawn(ed.id)) {\r\n\t\t\t\tdoneEdge.push(ed.id);\r\n\t\t\t\tfor (var j = 0; j&lt;3; j++) {\r\n\t\t\t\t\tvar pt = ed.getControl(j);\r\n\t\t\t\t\tptArray.push(pt.x, pt.y , j);\r\n\t\t\t\t\texportString += '&#x5B;' + pt.x + ',' + pt.y + ',' + j + '] , ';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\the = he.getNext();\r\n\t\t\tid = he.id;\r\n\t\t}\r\n\t}\r\n\telt.endEdit();\r\n\texportString += '];\\n';\r\n}\r\n\/\/ fl.trace(ptArray);\r\n\/\/ fl.trace(&quot;\/\/ end ---------------------------&quot;);\r\n\r\n\r\n\/\/ I'm a lazy bastard, so paste the code in the as layer\r\n\/\/ create or place code in 'as' layer\r\nvar tl = fl.getDocumentDOM().getTimeline();\r\nif (tl.findLayerIndex(&quot;as&quot;) == undefined){\r\n\ttl.addNewLayer('as', 'normal' , true); \r\n} else {\r\n\ttl.currentLayer = tl.findLayerIndex(&quot;as&quot;)&#x5B;0];\r\n}\r\ntl.layers&#x5B;tl.currentLayer].frames&#x5B;0].actionScript = exportString.split('] , ];').join(']];') + &quot;\\n&quot;;\r\n\r\n\/\/ The following example tests the movie for the current document:\r\nfl.getDocumentDOM().testMovie(); \/\/ if you don't want to export to swf after the jsfl is ready, comment this line\r\n\r\n\r\n\/\/ end jsfl\r\n<\/pre>\n<p>It will create a layer named &#8216;as&#8217; where the array will be placed that will look something like this:<\/p>\n<pre class=\"brush: as3; title: ; notranslate\" title=\"\">\r\nvar shapeArrayz:Array = new Array ();\r\nshapeArrayz&#x5B;0] = &#x5B;&#x5B;20.05,169.5,0] , &#x5B;62.425,169.5,1] , &#x5B;104.8,169.5,2] , &#x5B;104.8,169.5,0] , &#x5B;104.8,211.85,1] , &#x5B;104.8,254.2,2] , &#x5B;104.8,254.2,0] , &#x5B;62.425,254.2,1] , &#x5B;20.05,254.2,2] , &#x5B;20.05,254.2,0] , &#x5B;20.05,211.85,1] , &#x5B;20.05,169.5,2]];\r\nshapeArrayz&#x5B;1] = &#x5B;&#x5B;189.55,0,0] , &#x5B;189.55,42.35,1] , &#x5B;189.55,84.7,2] , &#x5B;189.55,84.7,0] , &#x5B;147.175,84.7,1] , &#x5B;104.8,84.7,2] , &#x5B;104.8,84.7,0] , &#x5B;104.8,42.35,1] , &#x5B;104.8,0,2] , &#x5B;104.8,0,0] , &#x5B;147.175,0,1] , &#x5B;189.55,0,2]];\r\nshapeArrayz&#x5B;2] = &#x5B;&#x5B;189.55,169.45,0] , &#x5B;231.9,169.45,1] , &#x5B;274.25,169.45,2] , &#x5B;274.25,169.45,0] , &#x5B;274.25,211.8,1] , &#x5B;274.25,254.15,2] , &#x5B;274.25,254.15,0] , &#x5B;231.9,254.15,1] , &#x5B;189.55,254.15,2] , &#x5B;189.55,254.15,0] , &#x5B;189.55,211.8,1] , &#x5B;189.55,169.45,2]];\r\nshapeArrayz&#x5B;3] = &#x5B;&#x5B;189.55,84.7,0] , &#x5B;189.55,127.075,1] , &#x5B;189.55,169.45,2] , &#x5B;189.55,169.45,0] , &#x5B;147.175,169.45,1] , &#x5B;104.8,169.45,2] , &#x5B;104.8,169.45,0] , &#x5B;104.8,127.075,1] , &#x5B;104.8,84.7,2] , &#x5B;104.8,84.7,0] , &#x5B;147.175,84.7,1] , &#x5B;189.55,84.7,2]];\r\nshapeArrayz&#x5B;4] = &#x5B;&#x5B;104.8,169.45,0] , &#x5B;147.175,169.45,1] , &#x5B;189.55,169.45,2] , &#x5B;189.55,169.45,0] , &#x5B;189.55,211.8,1] , &#x5B;189.55,254.15,2] , &#x5B;189.55,254.15,0] , &#x5B;147.175,254.15,1] , &#x5B;104.8,254.15,2] , &#x5B;104.8,254.15,0] , &#x5B;104.8,211.8,1] , &#x5B;104.8,169.45,2]];\r\nshapeArrayz&#x5B;5] = &#x5B;&#x5B;104.8,338.95,0] , &#x5B;104.8,296.55,1] , &#x5B;104.8,254.15,2] , &#x5B;104.8,254.15,0] , &#x5B;147.175,254.15,1] , &#x5B;189.55,254.15,2] , &#x5B;189.55,254.15,0] , &#x5B;189.55,296.55,1] , &#x5B;189.55,338.95,2] , &#x5B;189.55,338.95,0] , &#x5B;147.175,338.95,1] , &#x5B;104.8,338.95,2]];\r\nshapeArrayz&#x5B;6] = &#x5B;&#x5B;274.25,169.5,0] , &#x5B;284.275,179.5,1] , &#x5B;294.3,189.5,2] , &#x5B;294.3,189.5,0] , &#x5B;294.3,211.9,1] , &#x5B;294.3,234.3,2] , &#x5B;294.3,234.3,0] , &#x5B;294.275,234.3,1] , &#x5B;294.25,234.3,2] , &#x5B;294.25,234.3,0] , &#x5B;284.325,244.25,1] , &#x5B;274.4,254.2,2] , &#x5B;274.4,254.2,0] , &#x5B;274.325,254.2,1] , &#x5B;274.25,254.2,2] , &#x5B;274.25,254.2,0] , &#x5B;274.25,211.85,1] , &#x5B;274.25,169.5,2]];\r\nshapeArrayz&#x5B;7] = &#x5B;&#x5B;0.1,189.45,0] , &#x5B;10.1,179.45,1] , &#x5B;20.1,169.45,2] , &#x5B;20.15,254.2,0] , &#x5B;20.125,211.825,1] , &#x5B;20.1,169.45,2] , &#x5B;20.15,254.2,0] , &#x5B;20.1,254.2,1] , &#x5B;20.05,254.2,2] , &#x5B;20.05,254.2,0] , &#x5B;10.025,244.2,1] , &#x5B;0,234.2,2] , &#x5B;0,234.2,0] , &#x5B;0.05,211.825,1] , &#x5B;0.1,189.45,2]];\r\nshapeArrayz&#x5B;8] = &#x5B;&#x5B;124.85,359,0] , &#x5B;114.825,349,1] , &#x5B;104.8,339,2] , &#x5B;189.55,338.85,0] , &#x5B;147.175,338.925,1] , &#x5B;104.8,339,2] , &#x5B;189.55,338.85,0] , &#x5B;189.55,338.925,1] , &#x5B;189.55,339,2] , &#x5B;189.55,339,0] , &#x5B;179.6,349.05,1] , &#x5B;169.65,359.1,2] , &#x5B;169.65,359.1,0] , &#x5B;147.25,359.05,1] , &#x5B;124.85,359,2]];\r\nshapeArrayz&#x5B;9] = &#x5B;&#x5B;274.25,254.15,0] , &#x5B;274.25,254.2,1] , &#x5B;274.25,254.25,2] , &#x5B;274.25,254.25,0] , &#x5B;264.3,264.275,1] , &#x5B;254.35,274.3,2] , &#x5B;254.35,274.3,0] , &#x5B;231.975,274.3,1] , &#x5B;209.6,274.3,2] , &#x5B;209.6,274.3,0] , &#x5B;199.575,264.25,1] , &#x5B;189.55,254.2,2] , &#x5B;189.55,254.2,0] , &#x5B;231.9,254.175,1] , &#x5B;274.25,254.15,2]];\r\nshapeArrayz&#x5B;10] = &#x5B;&#x5B;104.8,254.15,0] , &#x5B;104.8,254.2,1] , &#x5B;104.8,254.25,2] , &#x5B;104.8,254.25,0] , &#x5B;94.85,264.275,1] , &#x5B;84.9,274.3,2] , &#x5B;84.9,274.3,0] , &#x5B;62.525,274.3,1] , &#x5B;40.15,274.3,2] , &#x5B;40.15,274.3,0] , &#x5B;30.125,264.25,1] , &#x5B;20.1,254.2,2] , &#x5B;20.1,254.2,0] , &#x5B;62.45,254.175,1] , &#x5B;104.8,254.15,2]];\r\nshapeArrayz&#x5B;11] = &#x5B;&#x5B;189.6,169.5,0] , &#x5B;199.625,159.475,1] , &#x5B;209.65,149.45,2] , &#x5B;209.65,149.45,0] , &#x5B;232.025,149.45,1] , &#x5B;254.4,149.45,2] , &#x5B;254.4,149.45,0] , &#x5B;254.4,149.475,1] , &#x5B;254.4,149.5,2] , &#x5B;254.4,149.5,0] , &#x5B;264.325,159.475,1] , &#x5B;274.25,169.45,2] , &#x5B;274.25,169.45,0] , &#x5B;274.25,169.5,1] , &#x5B;274.25,169.55,2] , &#x5B;189.6,169.5,0] , &#x5B;231.925,169.525,1] , &#x5B;274.25,169.55,2]];\r\nshapeArrayz&#x5B;12] = &#x5B;&#x5B;20.15,169.5,0] , &#x5B;30.175,159.475,1] , &#x5B;40.2,149.45,2] , &#x5B;40.2,149.45,0] , &#x5B;62.55,149.45,1] , &#x5B;84.9,149.45,2] , &#x5B;84.9,149.45,0] , &#x5B;84.9,149.475,1] , &#x5B;84.9,149.5,2] , &#x5B;84.9,149.5,0] , &#x5B;94.85,159.475,1] , &#x5B;104.8,169.45,2] , &#x5B;104.8,169.45,0] , &#x5B;104.8,169.5,1] , &#x5B;104.8,169.55,2] , &#x5B;20.15,169.5,0] , &#x5B;62.475,169.525,1] , &#x5B;104.8,169.55,2]];\r\n\r\n<\/pre>\n<p>And if you need some help to convert this Array into a Flash generated shape ?<br \/>\nhere is some code that could help you (AS3):<\/p>\n<pre class=\"brush: as3; title: ; notranslate\" title=\"\">\r\n\/\/ draw the new extracted image\r\nfunction drawArray (_arr:Array) {\r\n\t\/\/ trace (&quot;drawArray &quot;);\r\n\tvar _shape:Shape = new Shape();\r\n\t_shape.graphics.lineStyle (1, 0x333333, 1);\r\n\t_shape.graphics.beginFill (0xcccccc);\r\n\t_shape.graphics.moveTo (_arr&#x5B;0]&#x5B;0], _arr&#x5B;0]&#x5B;1]); \/\/ starting point\r\n\tfor (var i=1; i&lt;=_arr.length; i+=3) {\r\n\t\t_shape.graphics.curveTo (_arr&#x5B;i]&#x5B;0], _arr&#x5B;i]&#x5B;1] , _arr&#x5B;i+1]&#x5B;0], _arr&#x5B;i+1]&#x5B;1]);\r\n\t\t\/\/ _shape.graphics.lineTo (_arr&#x5B;i+1]&#x5B;0], _arr&#x5B;i+1]&#x5B;1]);\r\n\t}\r\n\t_shape.graphics.endFill ();\r\n\tthis.drawContainer_mc.addChild (_shape);\r\n}\r\n\r\n\/\/ jumpstart everything\r\nfunction init (){\t\r\n\tfor (var j=0; j&lt;shapeArrayz.length; j++) {\r\n\t\t\/\/ trace(shapeArrayz&#x5B;j])\r\n\t\tdrawArray (shapeArrayz&#x5B;j]);\r\n\t}\r\n}\r\ninit ();\r\n<\/pre>\n<p>have fun \ud83d\ude42<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[22,21,3],"tags":[162,408,148,398,164,95,29,163,161,160],"class_list":["post-426","post","type-post","status-publish","format-standard","hentry","category-as3","category-extending-flash","category-flash","tag-array","tag-as3","tag-custmm-grumm","tag-flash","tag-flash-9","tag-illustrator","tag-jsfl","tag-shape","tag-shapes","tag-vector"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 4.9.9 - aioseo.com -->\n\t<meta name=\"description\" content=\"For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Matthijs Kamstra\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 4.9.9\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"[mck] | a polymath zapper\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"Shape 2 Array jsfl | [mck]\" \/>\n\t\t<meta property=\"og:description\" content=\"For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2008-08-06T08:00:01+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2012-06-22T22:30:58+00:00\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Shape 2 Array jsfl | [mck]\" \/>\n\t\t<meta name=\"twitter:description\" content=\"For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#article\",\"name\":\"Shape 2 Array jsfl | [mck]\",\"headline\":\"Shape 2 Array jsfl\",\"author\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/author\\\/admin\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/#organization\"},\"image\":{\"@type\":\"ImageObject\",\"url\":\"http:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/wp-content\\\/uploads\\\/importaiintoflash.jpg\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#articleImage\"},\"datePublished\":\"2008-08-06T09:00:01+01:00\",\"dateModified\":\"2012-06-22T23:30:58+01:00\",\"inLanguage\":\"en-US\",\"commentCount\":6,\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#webpage\"},\"articleSection\":\"AS3, Extending Flash, Flash, array, AS3, Custmm Grumm, Flash, flash 9, illustrator, JSFL, shape, shapes, vector\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/category\\\/flash\\\/#listItem\",\"name\":\"Flash\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/category\\\/flash\\\/#listItem\",\"position\":2,\"name\":\"Flash\",\"item\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/category\\\/flash\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/category\\\/flash\\\/extending-flash\\\/#listItem\",\"name\":\"Extending Flash\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/category\\\/flash\\\/extending-flash\\\/#listItem\",\"position\":3,\"name\":\"Extending Flash\",\"item\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/category\\\/flash\\\/extending-flash\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#listItem\",\"name\":\"Shape 2 Array jsfl\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/category\\\/flash\\\/#listItem\",\"name\":\"Flash\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#listItem\",\"position\":4,\"name\":\"Shape 2 Array jsfl\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/category\\\/flash\\\/extending-flash\\\/#listItem\",\"name\":\"Extending Flash\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/#organization\",\"name\":\"[mck]\",\"description\":\"a polymath zapper\",\"url\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/author\\\/admin\\\/#author\",\"url\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/author\\\/admin\\\/\",\"name\":\"Matthijs Kamstra\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/06ff22a1197b6624946e5a3377184f11ddc00ac06a6f1d2311b9d2072bdf61b1?s=96&d=wavatar&r=g\",\"width\":96,\"height\":96,\"caption\":\"Matthijs Kamstra\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#webpage\",\"url\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/\",\"name\":\"Shape 2 Array jsfl | [mck]\",\"description\":\"For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\\\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/2008\\\/08\\\/06\\\/shape-2-array-jsfl\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/author\\\/admin\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/author\\\/admin\\\/#author\"},\"datePublished\":\"2008-08-06T09:00:01+01:00\",\"dateModified\":\"2012-06-22T23:30:58+01:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/\",\"name\":\"[mck]\",\"description\":\"a polymath zapper\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.matthijskamstra.nl\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Shape 2 Array jsfl | [mck]","description":"For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI","canonical_url":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#article","name":"Shape 2 Array jsfl | [mck]","headline":"Shape 2 Array jsfl","author":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/author\/admin\/#author"},"publisher":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/#organization"},"image":{"@type":"ImageObject","url":"http:\/\/www.matthijskamstra.nl\/blog\/wp-content\/uploads\/importaiintoflash.jpg","@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#articleImage"},"datePublished":"2008-08-06T09:00:01+01:00","dateModified":"2012-06-22T23:30:58+01:00","inLanguage":"en-US","commentCount":6,"mainEntityOfPage":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#webpage"},"isPartOf":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#webpage"},"articleSection":"AS3, Extending Flash, Flash, array, AS3, Custmm Grumm, Flash, flash 9, illustrator, JSFL, shape, shapes, vector"},{"@type":"BreadcrumbList","@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog#listItem","position":1,"name":"Home","item":"https:\/\/www.matthijskamstra.nl\/blog","nextItem":{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/#listItem","name":"Flash"}},{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/#listItem","position":2,"name":"Flash","item":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/extending-flash\/#listItem","name":"Extending Flash"},"previousItem":{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/extending-flash\/#listItem","position":3,"name":"Extending Flash","item":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/extending-flash\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#listItem","name":"Shape 2 Array jsfl"},"previousItem":{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/#listItem","name":"Flash"}},{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#listItem","position":4,"name":"Shape 2 Array jsfl","previousItem":{"@type":"ListItem","@id":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/extending-flash\/#listItem","name":"Extending Flash"}}]},{"@type":"Organization","@id":"https:\/\/www.matthijskamstra.nl\/blog\/#organization","name":"[mck]","description":"a polymath zapper","url":"https:\/\/www.matthijskamstra.nl\/blog\/"},{"@type":"Person","@id":"https:\/\/www.matthijskamstra.nl\/blog\/author\/admin\/#author","url":"https:\/\/www.matthijskamstra.nl\/blog\/author\/admin\/","name":"Matthijs Kamstra","image":{"@type":"ImageObject","@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/06ff22a1197b6624946e5a3377184f11ddc00ac06a6f1d2311b9d2072bdf61b1?s=96&d=wavatar&r=g","width":96,"height":96,"caption":"Matthijs Kamstra"}},{"@type":"WebPage","@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#webpage","url":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/","name":"Shape 2 Array jsfl | [mck]","description":"For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/#breadcrumblist"},"author":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/author\/admin\/#author"},"creator":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/author\/admin\/#author"},"datePublished":"2008-08-06T09:00:01+01:00","dateModified":"2012-06-22T23:30:58+01:00"},{"@type":"WebSite","@id":"https:\/\/www.matthijskamstra.nl\/blog\/#website","url":"https:\/\/www.matthijskamstra.nl\/blog\/","name":"[mck]","description":"a polymath zapper","inLanguage":"en-US","publisher":{"@id":"https:\/\/www.matthijskamstra.nl\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"[mck] | a polymath zapper","og:type":"article","og:title":"Shape 2 Array jsfl | [mck]","og:description":"For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI","og:url":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/","article:published_time":"2008-08-06T08:00:01+00:00","article:modified_time":"2012-06-22T22:30:58+00:00","twitter:card":"summary_large_image","twitter:title":"Shape 2 Array jsfl | [mck]","twitter:description":"For a project of mine: Custmm Grumm I needed to change a shape into an array, you could say that I needed to change a Illustrator\/vector file into code. As far as I know there is no other method then the one I created here with jsfl. To make this happen I imported the .AI"},"aioseo_meta_data":{"post_id":"426","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[]},"schema_type":"default","schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"breadcrumb_settings":null,"limit_modified_date":false,"ai":null,"created":"2024-12-11 09:01:32","updated":"2025-06-04 09:04:48","seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.matthijskamstra.nl\/blog\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/\" title=\"Flash\">Flash<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/extending-flash\/\" title=\"Extending Flash\">Extending Flash<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tShape 2 Array jsfl\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/www.matthijskamstra.nl\/blog"},{"label":"Flash","link":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/"},{"label":"Extending Flash","link":"https:\/\/www.matthijskamstra.nl\/blog\/category\/flash\/extending-flash\/"},{"label":"Shape 2 Array jsfl","link":"https:\/\/www.matthijskamstra.nl\/blog\/2008\/08\/06\/shape-2-array-jsfl\/"}],"_links":{"self":[{"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/posts\/426","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/comments?post=426"}],"version-history":[{"count":3,"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/posts\/426\/revisions"}],"predecessor-version":[{"id":1929,"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/posts\/426\/revisions\/1929"}],"wp:attachment":[{"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/media?parent=426"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/categories?post=426"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.matthijskamstra.nl\/blog\/wp-json\/wp\/v2\/tags?post=426"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}