[Plugin] Shape Bender Beta

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby joergj » Fri Apr 10, 2009 7:21 pm

Hi Chris,
first of all, thank you so much for all your brilliant plugins. They are absolutely amazing.
Unfortunately, Shape Bender does not work well for me. Well, it kind of works, but I can´t keep the results,
Here is what happens:
Bild 1 - Shape selected
Bild 2 - Shape bender activated, one klick on the strait line, one klick on the curve
Bild 3 - hit enter
Bild 4 - hit enter second time
Bild 5 - hit enter third time...
Bild 6 - changed to the select tool after first time hitting enter

with each additional enter, the shape bends a little more.

am I doing something wrong?

btw: Mac OS 10.4.11, SketchUP 5 pro

anyway, I can´t thank you enough!
Jörg
0

joergj 
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby xrok1 » Fri Apr 10, 2009 7:30 pm

Are you seeing it happen more often than expected? If so, could you upload a model where it is behaving poorly, thanks!


well actually i expect it to never happen :lol:

seriously, i noticed if you unsmooth it then resmooth it after its bent that its fine, what about doing it that way in your script?
0
“There are three classes of people: those who see. Those who see when they are shown. Those who do not see.”

http://www.Twilightrender.com try it!

xrok1 
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby dtrarch » Fri Apr 10, 2009 8:24 pm

Hi Chris

Just a basket full of Easter eggs and thanks. :berserk:

Here is one that just went by me.
When the script is executed the original shape just seemed to disappear.
HMMMMM.? :?
While the bend conversion does make a saved component out of the original shape it would be nice to have the shape remain in place instead of disappearing when the script is executed.

Also with all your super scripts growing daily an icon set would much appreciated by all to have them at the ready 24-7.

Just a couple of thoughs for the day and thanks again for all the killer stuff you have created.
Happy Easter to all :enlight:

dtr
0

dtrarch 
Premium Member
Premium Member
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby david_h » Fri Apr 10, 2009 8:32 pm

Chris. . .the first iteration worked like a charm. The next version. . .not so great.

All kinds of wierd results. Should I dump it and reload or what?
0
If I make it look easy. . .then it probably is.
User avatar
david_h 
Top SketchUcator
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby Chris Fullmer » Fri Apr 10, 2009 8:56 pm

@David, your line is not lined up on the red axis in that example. I'll add a check to the system so that it will not select a line that is not on the red axis. I think that is the problem there.

@Jorg - hmm, there is a command that is called after the user hits enter to de0activate the tool. It looks like it is not being called. Could you open the Ruby Console and then run the script. It should write a lot of errors to the screen just after you hit enter. Could you copy and paste those this forum for me? I'll see if I can put in a workaround for people still on version 5. Thanks!

@xrok, smoothing in SU doesn't remember what angle/degree the smoothing was set at. The angle is used only to tell SU what lines to apply a smooth to. But it then promptly forgets what angle it was. So there is no way to find and retain that information. So I can't just implement a shape-wide smoothing at a certain degree. thing about models that have some places smoothed where the angles are at 90 degrees, and other places where the angles are flat, but they left line unsmoothed to give it a highlight. A global resmooth would break all of that. It essentially is set up to run an intersect with model on the shape. All the new lines that are created should be smoothed, and all the others should be left alone. But any line that already existed precisely where that intersection takes place, is going to be smoothed, regardless of its previous setting. Also, some faces get bent in ways that I have not figured out how to determine ahead of time. SU does some bending and adds lines on its own. Those are the lines that are not smoothed that should be smoothed. Perhaps there is a setting to have SU add them as pre-smoothed edges. That would be ideal. Otherwise I'll have to find a way to determine where SU is going to need to add breaking-lines and add them myself before SU does, so I can smooth them when I add them. I only explain it all in this detail in hopes that someone will understand the dilemma and help me find a better solution.

@dtr, thanks! I do like the idea of leaving the original component/group back where it was originally. If it was a group, I might need to convert it to a component. Is that acceptable? Perhaps not, I'm not positive. I'll play with it. It would nice in my mind too. And I do keep thinking about putting together an entire toolbar of all my scripts. I suppose I'm not opposed to it. But I would want to figure out a good way to make it so the user can selectively turn off unwanted icons while leaving others on. Maybe once I think that through all the way, I can make a comprehensive set.

Thanks everyone! Great round of suggestions. I'll probably be working on it for the next for hours if anything else comes up.

Chris
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby joergj » Fri Apr 10, 2009 9:23 pm

Hi Chris,
here is what I find in the Ruby Console after hitting enter once:

Error: #<NoMethodError: undefined method `to_component' for #<Sketchup::Group:0xb2357a0>>
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:103:in `activate'
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:904:in `select_tool'
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:904
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:904:in `call'
Error: #<NoMethodError: undefined method `to_component' for #<Sketchup::Group:0xb22f698>>
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:885:in `componentizer'
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:230:in `onReturn'


and this after hitting enter a second time:

Error: #<NoMethodError: undefined method `to_component' for #<Sketchup::Group:0xb2357a0>>
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:103:in `activate'
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:904:in `select_tool'
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:904
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:904:in `call'
Error: #<NoMethodError: undefined method `to_component' for #<Sketchup::Group:0xb22f698>>
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:885:in `componentizer'
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:230:in `onReturn'
Error: #<NoMethodError: undefined method `to_component' for #<Sketchup::Group:0xb22f698>>
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:885:in `componentizer'
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:230:in `onReturn'
/Library/Application Support/SketchUp 5/Plugins/clf_shape_bender.rb:885


thanks a lot!
Jörg
0

joergj 
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby Chris Fullmer » Fri Apr 10, 2009 9:28 pm

oh bummer. I'm sure I can put in a workaround. It might take a little while though. I'll probably need to find a version of SU 5 to install to make the testing go faster.

If I get it fixed, I'll try to remember to PM you directly too. And I'll put a note in the first post that its not currently compatible with version 5. Thanks!

Chris
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby joergj » Fri Apr 10, 2009 9:58 pm

Chris, you don´t have to pm me, I will be on the watch ;-). You have more important things on the list! Anyway, I can use the free version of SU 6 ore 7 to do the bending stuff.

Thank you!!!
Jörg
0

joergj 
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby jeff hammond » Fri Apr 10, 2009 10:22 pm

here's my issue with certain rubies.. this one included.
i understand that it probably has something to do sketchup being a polygon modeler and how its curves have segments/vertexes..


scene 4 though -- that gives me hope :D
bending_reup.skp

[EDIT] oops - the first one i uploaded had scene four drawn wrong (it was the same as scene 8).. it should be ok now


i hope the skp is pretty explanatory.. i think it's less confusing than the 5 paragraphs i had type up :)
0
dotdotdot
User avatar
jeff hammond 
Global Moderator
 

Re: [Plugin] Shape Bender Beta v0.25 UPDATED April 10, 2009

Postby dtrarch » Sat Apr 11, 2009 12:05 am

Chris

Whatever is needed for the original to stay put would work.
Drove me crazy until I looked at the Component pulldown.

Selective icons would be perfect

Maybe a universal script to access and integrate other's work???

An aside:
My wife heard your little one in the backgound on the video.
Mother's ears never rest. :enlight:

Cheers

dtr
0

dtrarch 
Premium Member
Premium Member
 

Re: [Plugin] Shape Bender Beta v0.3 UPDATED April 10, 2009 AGAIN

Postby Chris Fullmer » Sat Apr 11, 2009 1:27 am

UPDATED v0.3 beta!

0.3 Beta:: 2009-04-10
* Added a check to disable the up and down keys until the correct selections have been made.
* Added more checks to make sure that the line and curve being selected are acceptable selections. Pops up messageboxes letting you know if your selection was invalid.
* Now it leaves a component where the original group/component was located. It remains mostly untouched, but it might get a name change, and if its a group it gets changed to a component.

ok, a few more safety checks to help the selection process and now the original shape gets left in place.

Chris
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.3 UPDATED April 10, 2009 AGAIN

Postby Chris Fullmer » Sat Apr 11, 2009 1:34 am

I had accidentally uploaded my testing version. It was online for about 2 minutes. If you get an error something like "You must a single group/component before activating this plugin" when you start Sketchup, that means you got the bad copy. Just delete it and re-install with the copy that is up right now. Thanks!

Chris

Also, the idea of a universal script to control all plugin's toolbars has long been a dream of lots of people. so far it seems like a no go. I could probably get it working for just my scripts, but it would require a little bit of thinking. I know fredo has implemented something like it (plus lots more) for his scripts.
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.3 UPDATED April 10, 2009 AGAIN

Postby •BTM » Sat Apr 11, 2009 4:26 am

The home and end keys don't seem to work either :oops:
I'll try to figure out which script might be breaking it...
Picture 2.png

The good news: when all other rubies are removed, I don't get the problem, so it MUST be another script breaking it.
0
Last edited by •BTM on Sat Apr 11, 2009 4:45 am, edited 1 time in total.

•BTM 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Shape Bender Beta v0.3 UPDATED April 10, 2009 AGAIN

Postby •BTM » Sat Apr 11, 2009 4:41 am

You might not believe this, but on my first try, I managed to find what script was breaking it...
I don't know if it's for all versions, but I know that at least the version I have is breaking it...
(drumroll)...

SketchyPhysics3X. I still don't know which file in particular, but something in sketchyphysics seems to break the ability to toggle in your script.
... :( bad luck for me...
0

•BTM 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Shape Bender Beta v0.3 UPDATED April 10, 2009 AGAIN

Postby Chris Fullmer » Sat Apr 11, 2009 5:14 am

Oh bummer! Well I just PM'ed Chris Phillips, we'll see if he has any thoughts about what the problem might be and if its fixable.

The alternative is to always draw the line from right to left, and if the arc is oriented the wrong direction, just cancel out of the shape bender and scale the arc manually on the red axis. Then re-run shape bender and the curve will be oriented correctly. a litle more time consuming, but its not bad.

Chris
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.3 UPDATED April 10, 2009 AGAIN

Postby •BTM » Sat Apr 11, 2009 11:45 am

Chris Fullmer wrote:Oh bummer! Well I just PM'ed Chris Phillips, we'll see if he has any thoughts about what the problem might be and if its fixable.

The alternative is to always draw the line from right to left, and if the arc is oriented the wrong direction, just cancel out of the shape bender and scale the arc manually on the red axis. Then re-run shape bender and the curve will be oriented correctly. a litle more time consuming, but its not bad.

Chris

...I just move the first line to the other side of my shape. it seems to do the same thing.
0

•BTM 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Shape Bender Beta v0.3 UPDATED April 10, 2009 AGAIN

Postby gilles » Sat Apr 11, 2009 3:28 pm

One word: GREAT

I attach here two files LIMON2-en.skp and LIMON3.skp.
The first one is a tuto I made for staircase stringer creation (translated by GreyHead).
The second is the same shape made with SHAPE BENDER.

The result is the same but you can imagine how much time the first one takes to do.

GREAT.
THANKS.
0
" c'est curieux chez les marins ce besoin de faire des phrases "
User avatar
gilles 
Top SketchUcator
 

Re: [Plugin] Shape Bender Beta v0.3 UPDATED April 10, 2009 AGAIN

Postby jeff hammond » Sun Apr 12, 2009 3:38 am

nice example of putting this ruby to use gilles.. great results and i can imagine it being one heck of a time saver.
0
dotdotdot
User avatar
jeff hammond 
Global Moderator
 

Re: [Plugin] Shape Bender Beta v0.5 UPDATED April 11, 2009

Postby Chris Fullmer » Sun Apr 12, 2009 4:03 am

UPDATED v0.5 beta!

You must delete the clf_chap_bender.rb in the plugins folder if you had an older version of this plugin installed.

0.5 Beta:: 2009-04-11
  • Added a toolbar and icon
  • Added new mouse pointers that sort of hint at what you should be trying to click on next
  • Fixed the bug where the bent shape would not appear smoothed until you double clicked on it. Should look good now immediately after bending.
  • Added extensions support so this plugin can be turned off through the extensions manager.
  • Added Progressbar.rb support. It is now required. Get it at smustard.com

The icon is not great. I'd consider replacing it in the next release if anyone feels so motivated to design a better one.

Also, this plugin now requires progressbar.

ok, thanks!

Chris
0
Last edited by Chris Fullmer on Sun Apr 12, 2009 6:43 am, edited 1 time in total.
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.5 UPDATED April 11, 2009

Postby jeff hammond » Sun Apr 12, 2009 5:08 am

hey chris..

re: toolbar
i'm wondering if you can add some lines in the future updates for the mac users.. supposedly macs don't remember if the toolbar is on or off in the same way pcs do and the scripts need a little something to help the macs along..

i replaced line 993 with this:

Code: Select all
case toolbar.get_last_state
    when 1
       toolbar.restore
    when -1   
       toolbar.show
    end


it's working well. i can have the toolbar off when i quit sketchup and it will stay closed upon a relaunch..

fwiw, that code might as well be chinese.. i don't understand it but it's something fredo figured out..

here's a copy of the modification for you to look at and see if there would be any problems with keeping it in the future releases.
[edit - removed link -- no longer necessary]
(with perpendicular face tools, i did the same thing at line 748 of release 1.2)


thanks


[edit] oh, two more things..
1. the reasoning behind this for me is that i can customize the toolbar at the top of my SU window which can contain tools that only have one icon or for toolbars which contain more icons but i really only use one or two of them. if the toolbar doesn't let me turn it off, then have have two of the same icons in different places on my screen + the small toolbars (containing 1 or 2 icons) just seem a little lonely sitting amongst the bigger toolbars.

2. yeah, you should get one of the icon makers around here to make some for this script and perpendicular face.. here's a screenshot of the customized toolbar:


the little tiny spec sitting between the view selections and 1001bit extrude icon is the perp.face icon :)... the shape bender icon doesn't have a transparent background. i think it'd be cool to get the same person to do your whole suite just for a consistent CF look..


and yeah, i hope i'm not bumming you out with these weird little nit-picks :D
0
Last edited by jeff hammond on Sun Apr 12, 2009 7:21 am, edited 1 time in total.
dotdotdot
User avatar
jeff hammond 
Global Moderator
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby Chris Fullmer » Sun Apr 12, 2009 7:01 am

Updated - minor. v0.51 beta

Ok, thanks Jeff. I got the code in place for the Mac please test it and let me know if I got it right. I also gave the icon a transparent background so it doesn't stand out so much. Its still ugly though :)

And Jeff, why is your perpendicular face tool icon so tiny? That's kind of weird. It should be the normal size.

Chris
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby jeff hammond » Sun Apr 12, 2009 7:19 am

sweet.
the toolbar works. thank you.

i wouldn't necessarily say the icon looks ugly.. if anything, once you use the tool, the icon describes it perfectly.

i'm not sure what's up with the tiny icon.
they look good in their regular toolbar


all three of them are tiny with the custom toolbar though and they're the only 3 i've ever seen it happen with..

BTM has perpendicular face and a mac.. i wonder if he's getting the same thing?
0
dotdotdot
User avatar
jeff hammond 
Global Moderator
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby Daniel S » Sun Apr 12, 2009 1:08 pm

oops.. this version dosen`t work for me. I have progressbar.rb
I can select the first line and the endline. But it dosen´t show the object in wireframe mode and with enter dosen´t accept... so i can´t bend.

Any idea what is happening?

Daniel S
0

Daniel S 
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby Chris Fullmer » Sun Apr 12, 2009 4:27 pm

Boy, its giving a few errors there. But it sort of looks like I might have implemented the progressbar wrong in the exploding part of the program. Could you upload a model that is not working? Thanks,

Chris
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby Chris Fullmer » Sun Apr 12, 2009 4:29 pm

Oh, I have another idea Daniel. Do you have component spray installed? If so, make sure you have the most recent version. Here's the link:

viewtopic.php?f=180&t=16446&st=0&sk=t&sd=a&hilit=component+spray#p129280

Chris
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby Daniel S » Sun Apr 12, 2009 4:55 pm

Chris Fullmer wrote:Oh, I have another idea Daniel. Do you have component spray installed? If so, make sure you have the most recent version. Here's the link:

viewtopic.php?f=180&t=16446&st=0&sk=t&sd=a&hilit=component+spray#p129280

Chris


I update the component spray plugin and now Shape Bender works fine. :ecstatic:

Thank you,
Daniel S
0

Daniel S 
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby EarthMover » Sun Apr 12, 2009 6:00 pm

Chris, thanks so much for the work you've put into this tool. It works very similarly to the Path Deformation modifier in 3ds Max, but is much easier and quicker in SU. I used the shape bender to bend an array of bullnose pool coping and mortar joints around the shape of a pool. It worked like a charm! :berserk:

Shape Bender1.jpg

Shape Bender3.jpg

Shape Bender_pool.jpg
0
3D Artist at Clearstory 3D Imaging
Guide Tool at Winning With Sketchup
Content Creator at Skapeup
User avatar
EarthMover 
Premium Member
Premium Member
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby xrok1 » Sun Apr 12, 2009 6:06 pm

please please if its possible could the script writters who make toolbars have them floating when they first appear! i'm getting soooo tired of rearanging my messed up toolbars its just not funny anymore. :cry:
0
“There are three classes of people: those who see. Those who see when they are shown. Those who do not see.”

http://www.Twilightrender.com try it!

xrok1 
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby Chris Fullmer » Sun Apr 12, 2009 7:29 pm

Sorry xrok, I don't think its possible. I could be wrong, and if I am, I'll fix the script to do that.

@Earthmover, that looks great! That is a good example of where the script is helpful, thanks! In some future iteration of the script, I would like it to be able to work with closed loops, like a pool outline. Then you could easily bend the tiles around in one move.

I also have some plans for a few additional utilities for this tool.

Planned Utilities:
1. Scale the line to be the same length as the pre-bent shape
2. Scale the shape to be the same length as the line
3. Scale both the be the same length as the curve

I see all of these as being additional icons and menu items that can be activated before beginning to bend the shape (getting them to work while the bend tool has been activated already mgiht be tricky because of the shape subdividing that happens. But it might be do-able.).

Anyhow, just some thoughts for the future of the script. Then there is also planar shape bending to try to implement.......

Chris
0
Lately you've been tan, suspicious for the winter.
All my Plugins I've written
User avatar
Chris Fullmer 
SketchUp Team
SketchUp Team
 

Re: [Plugin] Shape Bender Beta v0.51 UPDATED April 11, 2009

Postby sepo » Sun Apr 12, 2009 8:39 pm

For some reason the last version is not working for me. The plugin starts and just stays without bending it. It shows error in console and on progress bar.Attached screen.
0

sepo 
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 

PreviousNext


 

Return to Plugins

Who is online

Users browsing this forum: carlodenny, dpaul, medeek and 4 guests

Visit our sponsors: