[Plugin] SectionCutFace v2.0

Re: [Plugin] SectionCutFace v2.0

Postby Gaieus » Wed Sep 10, 2008 10:00 am

I guess you are not asking this (with the question mark at the end).

OK, I see (and understand) that the face created tries to orient itself to "close" the section cut with the back face inside (or at least that's what I understand from what you wrote).

I actually meant that if in the model, the faces are oriented consistently, it helps the script with "guessing" what to keep and what to delete.
0
User avatar
Gaieus 
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Wed Sep 10, 2008 3:45 pm

Gaieus wrote:I guess you are not asking this (with the question mark at the end).

OK, I see (and understand) that the face created tries to orient itself to "close" the section cut with the back face inside (or at least that's what I understand from what you wrote).

I actually meant that if in the model, the faces are oriented consistently, it helps the script with "guessing" what to keep and what to delete.

The orientation does not rely on the models's faces - it uses the plane direction of the section cut entity.
What is to be kept and what is to be erased is based on a faces' 'loop' look-up alogorithm. Working from the outside-most faces inwards (the outermost faces will not have adjacent faces on their outer edges so we know who they are), these are deleted and the next innermost faces are kept as they're the start of the cut faces. Then the next neighbour face is erased and its inner face neighbours kept and so on until it's all done. Obviously it's quite possible to devise certain shapes that produce collections of potential section-cut faces that aren't correct - if so, you can manullay erase or remake such faces to suit...

.
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby plot-paris » Thu Sep 11, 2008 11:47 am

very interesting facts are discussed here. your method of approaching the faces from the outside bountaries is quite clever, TIG.

however, I see the great potential behind Csaba's idea as well. most of us, I asume, are modelling with a tidy face orientation. and it is likely to encounter huge and complicated models among our designs - models, where the current method has difficulties finding the right faces.

I think, the "start from the outline" approach has one big flaw: if it is wrong at one point, it bases all future decisions on this assumption, right? so when it does a wrong calculation, the only thing to put it on the right track again is another wrong calculation.

I believe with the "face orientation" approach this danger is not as great, because decisions are made individually, based on every closed shape seperately.
this method however can't just rely on the created intersection geometry, but has to refer to existing objects in the model as well. I guess this is quite a tricky piece of code to write.

it would be great (and I am dreaming here :D of course) to have both approaches and to test them against each other - to test their percentage of right calculations...
0
User avatar
plot-paris 
 

Re: [Plugin] SectionCutFace v2.0

Postby Gaieus » Thu Sep 11, 2008 11:57 am

It actually works pretty well - only faulting sometimes with deeply nested geometry.
What could be even better (well, say this is just dreaming because I understand it cannot be done unless with lots of individual faces) to animate this section cut like the "native" (but hollow) one in SU.
0
User avatar
Gaieus 
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Thu Sep 11, 2008 6:53 pm

Gaieus wrote:It actually works pretty well - only faulting sometimes with deeply nested geometry.
What could be even better (well, say this is just dreaming because I understand it cannot be done unless with lots of individual faces) to animate this section cut like the "native" (but hollow) one in SU.

Section-plane methods are notoriously scant. However, it is theoretically possible to link the cut-face's group and its related section-plane using stuff like paired attributes and observers that watch what's changing. That way when the section-plane's location changes the matching cut-face group would be informed and it'd automatically "re-invent" itself based on this related section-plane's new location, direction, what it cuts etc...

Unfortunately I've tried this and I get Bugsplats aplenty ! I haven't found a work-rond so far... Perhaps SUp7 will have better methods for section-planes...

.
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby roadkill » Thu Sep 11, 2008 8:46 pm

thank you... so far i have been doing this in a complex and time consuming manner...
0

roadkill 
 

Re: [Plugin] SectionCutFace v2.0

Postby Gaieus » Fri Sep 12, 2008 8:28 am

When I use the script, I generally paint ever face within the group with the same material it cuts. So an animated script wouldn't add too much to my workflow if these faces couldn't retain the new material I gave them :)

Anyway, some different (enhanced?) method for section planes/cuts could be interesting if they were able to be exported (say in rendering engines and such). AFAIK it is not possible now.
0
User avatar
Gaieus 
 

Re: [Plugin] SectionCutFace v2.0

Postby Matt666 » Mon Sep 15, 2008 11:46 am

Hi TIG !
Thank you for this script, I use it every day, it has become indispensable!

Before this version, the edges of the Section were visible. They are unvisible now. Is there a way to create sections retaining visibility of the edges, without "edit / unhide / all"?

I understand that you have hidden edges, they are visible if you use a different section color. Edges are nevertheless useful for dimensions.

Thank you !
0
Frenglish at its best !
My scripts

Matt666 
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Mon Sep 15, 2008 12:23 pm

Matt666 wrote:Hi TIG !
Thank you for this script, I use it every day, it has become indispensable!

Before this version, the edges of the Section were visible. They are unvisible now. Is there a way to create sections retaining visibility of the edges, without "edit / unhide / all"?

I understand that you have hidden edges, they are visible if you use a different section color. Edges are nevertheless useful for dimensions.

Thank you !

You could temporarily switch all hidden geometry 'on' whilst you are dimensioning and then switch it 'off' later...

However, if you really want the cut's edges to be always visible you can do this...
Edit the script using Notepad or a similar plain text editor [NOT a word processor !]. Find/replace this part about 400 lines down...
Code: Select all
if f.typename == "Edge"      ###v1.4
      f.hidden= true         ###v1.4 <<<<<----<<<<<
end #if                      ###v1.4

Change the single line to be 'false' rather than 'true' and then the edges won't be hidden...
Code: Select all
      f.hidden= false

Leave the rest alone & save it. You you might want to make a copy of the script before the edit in case you are clumsy and it won't work afterwards!
Otherwise you are sorted.

.
0
Last edited by TIG on Mon Sep 15, 2008 6:11 pm, edited 2 times in total.
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby Matt666 » Mon Sep 15, 2008 12:26 pm

Excellent ! Thank you TIG !
0
Frenglish at its best !
My scripts

Matt666 
 

Re: [Plugin] SectionCutFace v2.0

Postby orei » Tue Nov 25, 2008 3:32 pm

hi my friends!!! what is the best solution to erase quickly the side of the section that i don't wanna see? do the cutsectionface, and then.. intersect the block with the rest of the model and then.. erase the other side? there isn't a script or a command, that when use cutsectionface tool, automatic erase the other part of the model??

Thanks a lot
0

orei 
 

Re: [Plugin] SectionCutFace v2.0

Postby pilou » Tue Nov 25, 2008 3:50 pm

what is the best solution

Rectangle selection from left to right ;)
0
Frenchy Pilou
Is beautiful that please without concept!
Speedy Galerie
User avatar
pilou 
Top SketchUcator
 

Re: [Plugin] SectionCutFace v2.0

Postby orei » Tue Nov 25, 2008 10:29 pm

sorry... but i don't understand.. why you say: rectangular selection fron left to right?? upper left and lower right.. or other side??

And.. with this selection.. what i do?? i need to do this.. when in the process??

sorry.. but i'm really confused..
0

orei 
 

Re: [Plugin] SectionCutFace v2.0

Postby Jim » Mon Dec 22, 2008 10:47 pm

I just wanted to say thanks for this plugin. I've been using it extensively over the past few days and it's just great.

I can't show the entire assembly, but here's one small component as an example.
0
Hi

Jim 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby Yanman » Mon Jan 05, 2009 2:41 am

TIG wrote:SectionCutFace.rb v2.0: update fixes an occasional visibility glitch with the cut-face's location relative to the section-plane, and layers are now sorted below the layers 'CUT-nnnn' and 'Layer0' (or the default layer-name if not EN).


thank you very much
0

Yanman 
 

Re: [Plugin] SectionCutFace v2.0

Postby massimo » Mon Jul 13, 2009 4:12 pm

Hi TIG, i've tried this plugin on SU6 free and didn't work for me. I had this error on ruby console:

Error: #<ArgumentError: wrong number of arguments(2 for 1)>
C:/Programmi/Google/Google SketchUp 6/Plugins/SectionCutFace.rb:361:in `offset'
C:/Programmi/Google/Google SketchUp 6/Plugins/SectionCutFace.rb:361:in `face'
C:/Programmi/Google/Google SketchUp 6/Plugins/SectionCutFace.rb:458
C:/Programmi/Google/Google SketchUp 6/Plugins/SectionCutFace.rb:458:in `call'

Then i've installed it on SU7 pro (with no other plugin installed) and it worked fine.
A plugin conflict?
Thanks.
Massimo
0
User avatar
massimo 
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Mon Jul 13, 2009 11:13 pm

Unknown error - unlikely clash...
Try again with a very simple box or two and see if it works...
If so, please publish what it actually fails on, so I can see what might be the problem...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby utiler » Tue Jul 14, 2009 2:04 am

Hi TIG, having a problem with SectionCutFace2.0... see attached video.
For some reason the cut plane is located but the layer and face color is not applied..... any ideas?

Cheers, :thumb:
0
purpose/expression/purpose/....
User avatar
utiler 
Top SketchUcator
 

Re: [Plugin] SectionCutFace v2.0

Postby massimo » Tue Jul 14, 2009 6:51 am

TIG wrote:Unknown error - unlikely clash...
Try again with a very simple box or two and see if it works...
If so, please publish what it actually fails on, so I can see what might be the problem...


My try was made with a very simple box...
0
User avatar
massimo 
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Tue Jul 14, 2009 10:05 am

utiler wrote:Hi TIG, having a problem with SectionCutFace2.0... see attached video.
For some reason the cut plane is located but the layer and face color is not applied..... any ideas?
Cheers, :thumb:

Has the new faces been put onto the section-cut ? When you select the face-group can you try moving so it becomes visible... or try to reverse the section-cut's direction... Does it have just edges or a 'default coloured' face etc, or is it as expected. Get its Entity Info to see if it's on the layer that was specified (also if not check that layer was made and put into the list).

I suspect that the face is getting made OK but it is too near the section plane and doesn't show up - what size is this test box - scale might have an effect ? When the face-group is made it cannot be exactly on the section-cut's plane as that would mean it wasn't visible in the section (!), so it's moved a fraction of a mm into the cut so you can then see it. Try selecting the group and moving it say 0.5mm into the cut so that it becomes visible...

Let me know the results... :geek:
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Tue Jul 14, 2009 11:04 am

viewtopic.php?p=172583#p172583 now has v2.1 which fixes the two problems mentioned in recent posts...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby utiler » Wed Jul 15, 2009 1:00 am

TIG wrote:
utiler wrote:Hi TIG, having a problem with SectionCutFace2.0... see attached video.
For some reason the cut plane is located but the layer and face color is not applied..... any ideas?
Cheers, :thumb:

Has the new faces been put onto the section-cut ? When you select the face-group can you try moving so it becomes visible... or try to reverse the section-cut's direction... Does it have just edges or a 'default coloured' face etc, or is it as expected. Get its Entity Info to see if it's on the layer that was specified (also if not check that layer was made and put into the list).

I suspect that the face is getting made OK but it is too near the section plane and doesn't show up - what size is this test box - scale might have an effect ? When the face-group is made it cannot be exactly on the section-cut's plane as that would mean it wasn't visible in the section (!), so it's moved a fraction of a mm into the cut so you can then see it. Try selecting the group and moving it say 0.5mm into the cut so that it becomes visible...

Let me know the results... :geek:


2.2 works a treat, TIG You're the bomb!!!!!
0
purpose/expression/purpose/....
User avatar
utiler 
Top SketchUcator
 

Re: [Plugin] SectionCutFace v2.0

Postby Jim » Mon Aug 17, 2009 11:58 pm

Report - here is a model where version 2.3 fails with the following message. Might have to due with some very small faces on the radius of the hole.

Code: Select all
Error: #<NoMethodError: undefined method `set_visibility' for nil:NilClass>
C:/Program Files/Google/Google SketchUp 7/Plugins/SectionCutFace.rb:383:in `face'
C:/Program Files/Google/Google SketchUp 7/Plugins/SectionCutFace.rb:451
C:/Program Files/Google/Google SketchUp 7/Plugins/SectionCutFace.rb:451:in `call'

197.jpg
0
Hi

Jim 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Tue Aug 18, 2009 12:28 pm

viewtopic.php?p=172583#p172583
Has v2.4 - error was caused by layer visibility setting if no pages/scenes set - now trapped.
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby Ecuadorian » Wed Sep 16, 2009 4:52 am

Such a fine ruby deserves a "digg". Or, in forum terms, a bump. Actually I meant to do it an hour ago but got busy reading some funny soapbox operas in the corner bar that happened back in July.

Thank you, TIG!
0

Ecuadorian 
 

Re: [Plugin] SectionCutFace v2.0

Postby burgz4 » Tue Feb 16, 2010 4:11 pm

OK totally stressing out, i have cut sections in my sketchup model and now i cant render them in any of my pacakges kerwythea and Artlantis. So i found this website which seems to be the answer to my problem but i cant down load the the plugin as i cant find it any where. I have also herd about Zorro 2 which i also can not find. CAN ANY ONE HELP
0

burgz4 
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Tue Feb 16, 2010 4:15 pm

Learn to use the Forum's Search tools - top right... for Zorro2 try
viewtopic.php?p=124862#p124862
Also search for 'Zorro' for the earlier one...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] SectionCutFace v2.0

Postby burgz4 » Tue Feb 16, 2010 4:52 pm

Hi, no luck with the zorro 2 am i doing it wrong there is nothing there to download . I need the actual link to the down load and how to down load in simple terms.
thanks
0

burgz4 
 

Re: [Plugin] SectionCutFace v2.0

Postby Gaieus » Tue Feb 16, 2010 4:54 pm

Wait TIG, I think he is not finding the plugin itself.

Burgz, the plugins are generally attached at the bottom of the first post in the [Plugin] topics.

To render sections (and added section cut faces) in those apps, you should indeed combine SectionCutFace and Zorro2 (which will definitely and ultimately remove what iscut away by the section plane so be careful and use it only on a copy of your model).

Here is an example I made with these plugins and Twilight Render (that uses the Kerkythea engine so you should get similar results with that)
0
User avatar
Gaieus 
 

Re: [Plugin] SectionCutFace v2.0

Postby TIG » Tue Feb 16, 2010 5:07 pm

burgz4 wrote:Hi, no luck with the zorro 2 am i doing it wrong there is nothing there to download . I need the actual link to the down load and how to down load in simple terms.
thanks

:?
There are two files to download - they have links on that page for Zorro2 that I linked directly to earlier - one is the ruby script [.rb] the other is a .pdf tutorial - they are found just below the large image ???
How is your session set up ?

Assuming you can see these two file links, then depending on your browser clicking on them should open a dialog that asks if you want to open or download them etc.
On Yes/OK for download/save them to your desktop.
From there move/copy them to your ..Sketchup../Plugins/ folder.
On restarting SUp there should be a new Menu item - Tools > Zorro ... and also some right-click context-menu items.
Read the Zorro2 PDF help file on how it works...

NOTE: sometimes scripts come in multiple files found inside a zip file, which can be downloaded and then needs extracting - the resulting files/sub-folders etc need to go into Plugins, BUT in this case the 'plain' .rb file is all that is needed and that goes straight into the Plugins folder with not modification...
Most plugins load into the Plugins Menu but in Zorro's case it loads into the Tools Menu...
:geek:
0
Last edited by TIG on Tue Feb 16, 2010 5:22 pm, edited 2 times in total.
TIG
User avatar
TIG 
Global Moderator
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 

PreviousNext


 

Return to Plugins

cron

Who is online

Users browsing this forum: No registered users and 69 guests

Visit our sponsors: