sketchucation logo sketchucation
    • Login
    1. Home
    2. mikenon
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info
    M
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 3
    • Posts 11
    • Groups 1

    mikenon

    @mikenon

    10
    Reputation
    1
    Profile views
    11
    Posts
    0
    Followers
    0
    Following
    Joined
    Last Online

    mikenon Unfollow Follow
    registered-users

    Latest posts made by mikenon

    • RE: [Plugin] Parametric Copy v1.01 20111030

      Ok here is version 1.01: http://forums.sketchucation.com/viewtopic.php?p=361858#p361858

      In addition to fixing the error in Windows-compatibility, there is now better error-handling in general for the input boxes, and there are new parameters for some of the functions.

      Extra thanks to mirale999 for patiently running code updates and sending me the bug reports.

      Mike

      posted in Plugins
      M
      mikenon
    • RE: [Plugin] Parametric Copy v1.01 20111030

      @danbig said:

      This is very cool. SketchUp has needed something like this for a long time.

      For me, SketchUp crashes every time, when the rotation is applied. I've tried different components, rotation axes, and parametric values. Each time, when the rotation is applied, I get a crash.

      Danbig: what version of Sketchup and Windows/OS X are you running? Could you send me a private message with details of what paramater values you used? If you select "None" (you may have to use the pull-down menu to find "None") for all of the rotation and scale operations, but just choose Constant-Step for the translation options, do you get the same problem?

      Everyone: Im in the process of fixing these bugs. It works perfectly on my OS-X box under extensive testing -- so I cannot debug on my own machine.

      Therefore I am debugging by email, which is very slow. But it will get fixed. So far mirale999 has helped by allowing me to send him versions of the plugin with debug statements, running it on his Windows box, then sending me back the debugging output. We have discovered at least one difference between windows and OS X Sketchup: on OS X, if you leave the default values blank in inputbox dialog, the value of a pulldown menu will default to the first item. On windows, it will default to empty-string.

      If anyone else is willing to help, please send me a message.

      posted in Plugins
      M
      mikenon
    • RE: [Plugin] Parametric Copy v1.01 20111030

      @mirale999 said:

      I'm using windows. I think I didn't do something wrong... I haven't learnt ruby yet, so I can't tell what's wrong with it, the only thing I can do is this... 😒

      Hey that video is really helpful. Thank you! Unfortunately, I dont have windows, and I have no way to even access a windows machine, so I cant test it on a pc. 😞

      It doesn't look like you are doing anything wrong though.

      If there is someone on list with a windows machine, and knowledge of the differences between Sketchup on PC and MAC, perhaps I could help walk through the debugging. I imagine the difference between Sketchup on mac and pc cant be very big. So I think this should be a quick fix -- but I dont know.

      Also, is there anyone on list who could verify that this works for them with OS X, so that I know it is not just something that works with the idiosyncrasies of my own machine? Its my first plugin (and first time learning ruby), so I would be grateful for any assistance.

      Thanks for your help!!

      Mike

      posted in Plugins
      M
      mikenon
    • RE: [Plugin] Parametric Copy v1.01 20111030

      @mirale999 said:

      It didn't work on my sketchup 8.0, copied the object several times in one place... the error code below:

      If you do not select any options, the default behavior is to just copy all of the objects in place. You must specify a formula for one of the dimensions. For instance, if you specify "Constant-Step" for x-translation, and set the value to 1-foot. Then each copy will be moved over by one foot along the x dimension. If you specify 0-feet, then all the copies will be in a single place. Also, if there is an error, I think it just goes ahead and makes all the copies, but does not do anything to them (so they all end up in one place).

      Obviously, the code would benefit from some better error-handling. But I cant reproduce your error. Can you give more details of what you entered in the dialog boxes to generate it? Ive tested on OS X SU7 and OSX SU8.

      Mike

      posted in Plugins
      M
      mikenon
    • RE: Does this plugin exist?

      Ok, I made the plugin. Thanks for your help TIG! I used a bunch of your code from Grow2. This new plugin has all the functionality of Grow2, plus allows you to enter lists of values or freeform expressions:

      Parametric Copy:
      http://forums.sketchucation.com/viewtopic.php?p=361858#p361858

      If anyone has a chance to try this out, let me know what you think

      posted in Plugins
      M
      mikenon
    • [Plugin] Parametric Copy v1.01 20111030

      DOWNLOAD LINK:ParametricCopy plugin: unzip and copy contents into Sketchup plugins directory
      OVERVIEW

      • ParametricCopy can be used to make multiple copies of an object, and control their properties using parametric formulas.
      • Separate formulas may be independently applied to position, scale, and rotation on the X, Y, and Z axis.
      • You can use predefined formulas, such as Fibonacci and Exponential, or write your own formulas as freeform expressions.
      • You can also use the output of another program or process, expressed as a list of numbers.
      • Since translation, scaling, and rotation do not break component linkage, all copies of a component object remain linked and editable.
      • ParametricCopy is a generalization of the Grow2 plugin, and duplicates and expands on its functionality.
        Sample object set generated by ParametricCopy
        Sample object set generated by ParametricCopy

      DOWNLOAD LINK:ParametricCopy plugin: unzip and copy contents into Sketchup plugins directory

      INSTRUCTIONS

      • Select an object
      • Choose ParametricCopy from the plugins pull-down menu
      • Choose a point which will be used as the center of rotations, and the reference for scaling operations
      • At the top of the main dialog, enter the number of copies to be made, and select the order of operations (translation,scaling,rotation), and the order of rotation operations (along the X, Y, and Z axis).
      • In the rest of the main dialog, select the formulas which will be applied to each operation.
      • For each selected formula, a dialog box will appear allowing you to specify the formula's parameters

      FORMULAS
      Freeform Expressions

      • Freeform expressions are defined in terms of the variable, i, which iterates from 0 to the number of copies that are made (the 0-th object is the original object). When entering a freeform expression, type only the portion after "f(i)=" -- Example: f(i)= 6i* will generate values 0, 6, 12, 18, ...
      • Freeform expressions may use all of the functions and constants of the Ruby Math module. Examples include the constants E and PI, and the trigonmetric functions sin and cos. Example: f(i)= sin(PIi/2)* will generate values 0,1,0,-1,0,1,0,-1,...
      • Freeform expressions may use ruby constructs, such as the x ? y : z construct (if x then y else z). Example f(i)= i%2==0 ? 0 : 1 will generate values 0,1,0,1,0,...
      • Freeform expressions may refer to previous iterations using f(i) notation. Example: f(i)= i<2 ? i : f(i-1) + f(i-2) will generate the Fibonacci series: 0, 1, 1, 2, 3, 5, 8, 13, ...

      Repeated Value List

      • Repeated Value List is a convenient way to use the output of an external program or process, as long as it can be expressed as a space-delimited list of values.
      • If the list of values is shorter than the number of copies, it will be repeated.
      • Example: 0 1 2 3 will generate values 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3,...

      Predefined Parametric Formulas

      • Predefined formulas contain one or more constants whose values may be input by the user. * These formulas are predefined as a convenience, and may alternatively be expressed as freeform expressions -- whenever the inputbox for a predefined formula is onscreen, the status line at the bottom of the sketchup window will display the equivalent freeform expression.
      • Current predefined formulas are Constant-Step, Linear-Step-Delta, Exponential, Fibonacci, and Step+Sine.

      EXAMPLES
      Example 1: Stretched Spiral Staircase
      Each step is higher than the previous step by 0.25 feet.

      • z-translate = linear-step-delta: step=1', delta=0.25'
      • z-rotate = constant-step: step=15 degrees
      • z-scale: freeform expression: i==0 ? 1.0 : f(i-1) + 0.25
        A spiral staircase where each step is higher than the previous

      Example 2: Copying Over a Surface
      By using the % (MOD) and / (DIV) operators, copies can be distributed across a surface.

      • Copies = 99
      • x-translate = freeform expression: i%10
      • y-translate = freeform expression: [i:wfzfe1cu]i/10[/i:wfzfe1cu]
      • z-translate = freeform expression: [i:wfzfe1cu]sin( (i%10) + (i/10)0.2pi)[/i:wfzfe1cu]
        Copies placed out over a surface using MOD and DIV

      Example 3: Using Random Numbers
      Interesting forms can be created using functions such as rand().

      • Copies = 300
      • Order = Scale Rotate Move
      • z-scale = freeform expression: [i:wfzfe1cu]1.0 + (3.0 * rand())[/i:wfzfe1cu]
      • x-rotate = freeform expression: [i:wfzfe1cu]rand()*360[/i:wfzfe1cu]
      • y-rotate = freeform expression: [i:wfzfe1cu]rand()*360[/i:wfzfe1cu]
        initial object used for Example 3
        Example 3: A starburst form generated with rand()

      [i:wfzfe1cu]VERSION LIST[/i:wfzfe1cu]

      • 1.0 2011_10_23:

      • First issue.

      • 1.01 2011_10_30:

      • Fixed bug in Windows with pull-down menus

      • Added "Initial_Val" parameter to Step+Sine and Linear-Step-Delta

      • Added exception capturing in all entry boxes

      ParametricCopy plugin: unzip and copy contents into Sketchup plugins directory

      posted in Plugins
      M
      mikenon
    • RE: Does this plugin exist?

      @unknownuser said:

      Without a little image i don't understand very well but
      Have you seen Grow 2 by Tig?

      Seems that is exactly that you want to make! πŸ’š

      Ok, thats a great start. Ive been hacking through the Grow2 code today and have enough to do what I want. To start, I have already added periodic functions (sin/sawtooth) since grow only has continuously growing functions.

      I would like to also add manually inputted arrays of numbers so that you can output the results of a custom function from another program. Perhaps someone might then be able to help modify it to work based on a visual curve instead of a table...I will upload results to the Grow2 thread when Im done.

      thanks!
      Mike

      posted in Plugins
      M
      mikenon
    • RE: [Plugin] Grow

      Hi - This is almost exactly what I need, but I would like to use other functions. Is there a way to alter this so that instead of choosing from linear/exponential/fibonacci I have the ability to select my own values. I need some other periodic functions, like sine-wave. I imagine, the easiest way to do this would be to just allow values to be passed in a list. So if I want 100 copies, I pass in a list with 100 numbers for x-offset. Is this possible?

      Mike

      posted in Plugins
      M
      mikenon
    • Does this plugin exist?

      Hi,
      I am a medium level sketchup user (not newbie, but not as expert as people on this forum). Anytime I am doing something extremely tedious and mindless, I think "there must be a plugin for that." So I am in a situation like that, but cant find the right plugin. I would be greatful for anyone's advice. Even partial solutions which get me half of the way there.

      Basically, I am looking for a more complicated version of memory-copy or path-copy, where I can take values from tables (or from drawn curves?) for various transformations.

      For instance, a simply array of objects might be created by reading from a table for x positions:
      x-offset: 1,2,3,4,5,6,7,8

      A more complicated array might allow the spacing to be selected from a non-linear function, like exponential:
      x-offset: 1,2,4,8,16,32,64,128

      Now, I might want to do two transformations simultaneously on different functions. Here x-offset is exponential, but rotation is linear:
      x-offset: 1,2,4,8,16,32,64,128
      rotation-degrees: 10,20,30,40,50,60,70,80

      I have been doing this manually for a set of designs, but I am now doing 100s of elements, with various linear and non-linear transformations on a range of variables (rotation, spacing, scaling), that are not in-sync with each other (they dont share the same period, so it never repeats). Its taking hours!!!

      I can imagine it might be possible to take some of these values from drawn curves instead of tables.

      Any ideas?

      Mike

      posted in Plugins
      M
      mikenon
    • RE: Live Edit Follow Me

      @unknownuser said:

      Though not a free plugin, but extremely powerful: Profile builder.

      Thank you so much. That looks like exactly what I was looking for. Im going to try it out immediately.

      posted in Newbie Forum
      M
      mikenon