sketchucation logo sketchucation
    • Login
    1. Home
    2. CPhillips
    3. Posts
    Oops, your profile's looking a bit empty! To help us tailor your experience, please fill in key details like your SketchUp version, skill level, operating system, and more. Update and save your info on your profile page today!
    FredoBend | Powerful new bending tool for SketchUp Download
    C
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 68
    • Posts 1,089
    • Groups 1

    Posts

    Recent Best Controversial
    • RE: [Plugin] SketchyFFD (Classic)

      @kwistenbiebel said:

      That's really cool Krash88.

      The only little remark I have with current plugin (besides saying it is awesome πŸ˜„), is that after some manipulation, it starts to become difficult to see which points to move.
      It would be great if the control points would stick more to the geometry...I am not sure if my explanation is clear.

      The points need to be where they are. It was possible in the previous version to move the control point grid object away from the mesh you are deforming. That makes it a little easier. I think it is broke in this version but I will see if I can fix it.

      @kwistenbiebel said:

      Another thing is, I noticed that the outer limits of geometry gets changed by the plugin, even though only points were selected in the middle (no points located at the boundaries of an object). I experienced this issue as well while using the 'sandbox tool' in SU.

      Not sure what you mean here. Maybe post and example?

      Chris

      posted in Plugins
      C
      CPhillips
    • RE: [Plugin] SketchyFFD (Classic)

      @krash88 said:

      Great job! The auto update is very nice. But I have one problem... If I create a flat piece of geometry similar to your wave demo, then strange things happen. After moving a control point the geometry disappears and the camera goes nuts. It sticks me in an over-head view, miles away from the control points. After a zoom extents I can tell that the geometry is still there and is selectable, but not visible. Turning on hidden geometry doesn't help and any attempt to zoom in or out puts me back over-head at a great distance from the points. It seems to work great on geometry with thickness. Any help is appreciated and thanks again for the wonderful script!

      Edit:

      After looking back at your wave demo, I noticed that you have a vertical edge at one corner of the mesh to give it thickness and I assume that you have deleted the control points from the bottom also. I tried this and it works just fine. So thanks again for the script!

      You got it! FFD objects need to have at least some depth when you first start. But after that it is safe to delete unwanted geometry and control points.

      Thanks for all the positive comments everyone. πŸ˜„
      Chris

      posted in Plugins
      C
      CPhillips
    • RE: [Plugin] SketchyFFD (Classic)

      @daniel s said:

      Here i attach a video using FFD like a twist tool...
      it would be easy to make this automatic with ruby?
      i mean.. to set the center of rotation (like in TIGΒ΄s Grow.rb) and the rotation angle.

      Daniel S

      Possible. But a fair amount of work. I'll look into it when I can spend more time on it.

      posted in Plugins
      C
      CPhillips
    • RE: [Plugin] SketchyFFD (Classic)

      This version supports NxN deforms. But more importantly it updates the mesh automatically when you move control points. That makes it a lot more usable.

      Also added status text progress when it is weighing and deforming the mesh.

      Making a curling wave with a 13x13x2 FFD.

      See the PluginStore for the download...

      posted in Plugins
      C
      CPhillips
    • RE: Question about "open" groups.

      I found a work around but its a little gross. I don't fully trust observers not to crash Sketchup.

      I put a entityObserver on my lattice group and then in onChangeEntity I store the current transformation in an attribute. Then when a user moves a point I check to see if the group is open (via observer) and if so I transform my control points by the inverse of the stored transform. That gives me a group relative point. whew.

      Thanks for the help.
      Chris

      posted in Developers' Forum
      C
      CPhillips
    • RE: Joypad use.

      @lozio said:

      Hi i have created a this model with multiple controls:

      http://sketchup.google.com/3dwarehouse/details?mid=57afaf98204577bf71f7c5c477d39467&prevstart=0

      and i want to put som controls in a joypad, but i dont know how to...

      if some one can tell me haow ill be really happy!!!!

      gracias lOZIO

      PD any joy pad would work? or do i need an specific joypad?

      Just change the name of the controller to joyLX,joyLY,joyRX or joyRY.

      It doesnt require a specific joypad but one with actual analog sticks is needed. Here is the one I use:

      http://www.gogamermadness.com/spotimage/SaitekP880GamePad.jpg

      posted in SketchyPhysics
      C
      CPhillips
    • RE: Question about "open" groups.

      @unknownuser said:

      I had a similar issue recently and I simply had to tell the user that the operation he was trying to perform was not allowed while in Group edit. This was because of the bugs dealing with working with groups and being out of context when in group/component edit.

      That's the way the ball bounces.

      Thats disappointing.

      Thanks Todd.

      posted in Developers' Forum
      C
      CPhillips
    • RE: Question about "open" groups.

      @unknownuser said:

      OK, you're right.

      What are you trying to do? Can you use the group's transformation origin and apply that to any translation you need to do for your cpoints?

      I could if I could get the original transformation. But as I said its set to identity as soon as you open the group.

      When I create the group of construction points I set an attribute that has its initial position in the group. Then the user opens the group, manipulates the points and I compare the new position to the position stored in the attribute. It works fine if the group is closed but if it is still open the points are transformed into world space instead of group space so I am comparing apples and oranges.

      @jim said:

      But the Group's transformation stays the same even if its entities are changed... so what's the point trying to get something you already know? Sorry if I'm missing the obvious.

      The groups transform does not stay the same. Not only is the transform zeroed but the location of all the points is world relative instead of group relative. If I have a point at position (1,1,1) in a group when I open the group its position will be (1,1,1) + whatever the transformation.origin of the unopened group is. Not to mention the effects of rotation and scaling.

      It seems when you open a group Sketchup transforms all the entities in that group by the groups transform and then sets the group transform to identity.

      posted in Developers' Forum
      C
      CPhillips
    • RE: Question about "open" groups.

      @unknownuser said:

      Post a small script that illustrates what you are having trouble with.

      Create a group and select it. Then type:

      group=Sketchup.active_model.selection[0]
      Then:
      group.transformation.to_a.inspect

      Note the transformation.

      Now open the group and execute the same line.
      group.transformation.to_a.inspect

      When open the transformation will always be:
      [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]

      posted in Developers' Forum
      C
      CPhillips
    • RE: Question about "open" groups.

      Ok, now I can detect that it is open. But how can I tell what the unopened groups transform is. As soon as a group is opened its transform becomes identity. I even tried to get it in a observer and by the time the onOpen is called it is already transformed.

      posted in Developers' Forum
      C
      CPhillips
    • RE: [Plugin] SketchyFFD (Classic)

      I made a new version that has a NxN FFD. That means you can select how many control points there are in each direction. It isn't as slow as I expected.

      Here is a 12x12x2. I am playing back my undo buffer so it looks faster than it is.

      Ill post it once I fix a bug or two.

      Just when I thought I was out they pull me back in.
      Chris

      posted in Plugins
      C
      CPhillips
    • RE: Question about "open" groups.

      @whaat said:

      This might be what you want:

      m=Sketchup.active_model
      > ents=m.active_entities
      > 
      > parent=ents.parent
      > 
      > if parent.class==Sketchup;;ComponentDefinition
      >    if parent.group?
      >        trans=parent.transformation
      >        p "in group #{parent.name}"
      >        p  trans.origin
      >    end
      > end
      

      Thanks. That answers the first question "how to tell if a group is open".

      But the code above doesn't work for me. "parent" is a ComponentDefinition and that class doesn't have a transformation. (unless i did something wrong?)

      I found the instance of the group but when the object is open the .transformation is identity.

      The real question I guess is if a group is open how can you get its real transformation?

      Chris

      posted in Developers' Forum
      C
      CPhillips
    • Question about "open" groups.

      My FFD plugin creates a group of construction points. If the user has the group open the position of the points (all entites) is given in world space not group space.

      How can I detect if the group is "open"? Or is there some other way to get untransformed positions?

      Thanks
      Chris

      posted in Developers' Forum
      C
      CPhillips
    • RE: [Plugin] SketchyFFD (Classic)

      @unknownuser said:

      The example in the pic takes a few seconds to deform.

      So do the points placed actually have different coordinates assigned to them? That's what I was asking in my previous post. I find it kinda hard to explain, I hope you know what I mean.

      Yes they do. Each construction point has its original position stored in an attribute. Thats how I know how far the point moved. But that is only 1/2 the equation. You also need the pre-calculated weight. That is what is missing when you copy a control point. Its that quick because it doesn't have all the calculated weights to process.

      If you want to try it with more control points do this:
      -Select the group you want to deform.
      -Open the ruby console and enter the following line:

      startFFD(Sketchup.active_model.selection[0],7.0)

      That will create a 8x8 control grid (8-1=7.0). Delete the points you don't intend to move to make it a bit faster.


      ffd9x9.skp

      posted in Plugins
      C
      CPhillips
    • RE: [Plugin] SketchyFFD (Classic)

      @unknownuser said:

      You're welcome Dave!

      What's a dope slap though?

      Also, I have been experimenting more with this script. I had an idea to position the cloned Construction Points along a series of curved Edges that you usually see used on Soap Skin Bubble examples, but I haven't been successful. I am trying to see (and would like Chris to shed some light on this) if the Construction Points have coordinates assigned to them. What I mean is that if I clone the Construction Points from the top and use them in the bottom will this distort the FFD? Should I therefor use the top ones? Well I tested this and it does seem so that there are coordinates assigned to them because by running two tests, one with using the Construction Points from above and the other test by using the bottom ones, and the result were different. The second test is what you see below, which brings me to another point - it is interesting to see what kind of curvy geometry you can create with this script, cloning Construction Points and positioning them. I hope I can find a way to understand how to exactly control them so it becomes easy to make any kind of curved geometry I had hoped to create in the first place.

      As it is currently written it creates the construction points at fixed points and then weights the model based on that initial position. I am actually surprised that coping the construction points works at all. πŸ˜„

      I think what you are asking for is: Take this mesh and start FFD with this group of arbitrary positioned control points. That should be possible and probably not to difficult.

      But you would have to be careful. When you start a FFD it creates a table of weights for each construction point with 3 floats per vertex in the group to deform.
      So if you have a mesh with 1000 verts and a 3x3 set of control points:
      3x3x3=27 control points
      2710003=81,000 floats

      When you update it loops through each vertex and calculates how much to move it based on the weighted changes in the control point. So the more control points you have the slower it is.

      In your picture it looks like you have 9x9x3 control points. That comes to 729,000 floats. It would be really really slow to deform.

      Chris

      posted in Plugins
      C
      CPhillips
    • RE: Sketchup.active_model.set_attribute

      @jorgensen said:

      YES YES YES YES
      I found the solution 😍

      I add a entity.set_attribute ("TM_area", "TM_ID", "TM_ID " + target.entityID.to_s)
      This is kept and can be used to recognise the objects - finally the script can be finshed 🀣

      I won't disturb anymore - I did that quite alot - sorry

      Thanks Todd (thanks all)

      Jorgensen
      😍

      Here it is in action. This will be very useful for me when sketching projects with focus on areas

      Be advised that entityID can change when a file is saved and loaded. I hope that isnt a problem for your application.

      posted in Developers' Forum
      C
      CPhillips
    • RE: Next version.

      @rayl said:

      Thanks for the great support you give to your work. Will you be including compatibility for various controllers in your SketchyPhysics 2 release? Or will we have to wait for SketchyPhysics 3?

      That buoyancy feature looks very interesting. I can't wait for it. Thanks.

      I plan to open up more controller axis. I dont know if I am going to have time to do an actual configuration script or not.

      You don't have to wait for buoyancy. Its in the b1 release. πŸ˜„

      posted in SketchyPhysics
      C
      CPhillips
    • RE: [Plugin] SketchyFFD (Classic)

      @dave r said:

      Very cool script. Thank you.

      I do seem to being doing something wrong with it though. (Leave it to me to break it. πŸ˜’ ) See the attached screen grab.

      I drew a sphere centered on the blue axis and above the ground plane. After moving a single point marked at the top and updating, the egg moved off to where it is now. What did I do wrong?
      [attachment=0:wa4rvigs]<!-- ia0 -->FFD1.JPG<!-- ia0 -->[/attachment:wa4rvigs]

      It looks like you did a "Update FFD" without first closing the control point group.

      Chris

      posted in Plugins
      C
      CPhillips
    • RE: [Plugin] SketchyFFD (Classic)

      @kwistenbiebel said:

      Does the plugin in any means uses web based 'action script' or 'javascript' as I had trouble before with corrupt Iexplorer settings?
      (I refer to web panel based plugins like Skindigo that failed in the past on my pc due to 'script blockers' )

      No other scripts at all. Just pure ruby.

      Hrmm. Very strange. Try doing a 2x2 FFD on a simple box. With the ruby console open in case of errors.

      posted in Plugins
      C
      CPhillips
    • Next version.

      I am running out of time to work on SketchyPhysics because my job is going to get busy for the next several months.

      I am going to do one more release in a week or so. It will be SketchyPhysics2 (no beta) and will really only be a few bugs fixes and no new features. Well, technically no new features. I am going to expose at least one feature that wasn't really ready (and probably still isn't).

      http://www.sketchucation.com/forums/scf/viewtopic.php?f=61&t=6112&start=0&st=0&sk=t&sd=a

      I'll probably be able to start work on SP3 again in the spring. In the meantime I am still going to checking these boards daily and am happy to answer questions, debug models or take feedback. And of course I will still be helping out on the Mac port(no eta yet).

      Chris

      posted in SketchyPhysics
      C
      CPhillips
    • 1 / 1