# input a vector of vectors via the customizer pane

4 messages
Open this post in threaded view
|

## input a vector of vectors via the customizer pane

 I’d like to input a vector of the type [[a,b],[c,d]] via the Customizer pane. I am able to input  a simple vector with a line that looks like this:Variable = [];Then I can paste the value [a,b,c,d,e] into the Customizer pane and process that vector within the code. For a vector of vectors, I’ve tried:Variable = [[],[]];But I can’t change the displayed value by pasting [[a,b],[c,d]]. I’d be OK with using a string input variable and then using some conversion function to take the string “[[a,b],[c,d]]” and turn it into a vector, but I don’t see that functionality in vanilla OpenSCAD. Any ideas? Thanks,Ken_______________________________________________ OpenSCAD mailing list [hidden email] http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Open this post in threaded view
|

## Re: input a vector of vectors via the customizer pane

 how about ```ab=[5, 10];//[[-100:100], [-100:100]] cd=[5, 10];//[[-100:100], [-100:100]] abcd = [ab, cd]; echo(abcd); ``` Sent from the OpenSCAD mailing list archive at Nabble.com._______________________________________________ OpenSCAD mailing list [hidden email] http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
 Yes, though that creates two inputs in the customizer rather than one. From: Parkinbot <[hidden email]> Sent: Wednesday, February 17, 2021 3:46 AMTo: [hidden email]Subject: Re: [OpenSCAD] input a vector of vectors via the customizer pane how about ` ``ab=[5, 10];//[[-100:100], [-100:100]]``cd=[5, 10];//[[-100:100], [-100:100]]``abcd = [ab, cd]; ``echo(abcd); ` Sent from the OpenSCAD mailing list archive at Nabble.com._______________________________________________ OpenSCAD mailing list [hidden email] http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org