[Plugin] TIG-weld
-
I tried the recurve.rb plugin, without sucess.
It does not work with nested objects. Any other suggestion? Is anyone able to edit the weld.rb to run for nested closed lines as well? -
Copyright 2004-2005 by Rick Wilson [in parts], and 2012-2017 (c) TIG.
Permission to use, copy, modify, and distribute this software for
any purpose and without fee is hereby granted, provided that the above
copyright notice appear in all copies.
THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.TIG-weld_code
Description:-
Joins selected edges into a 'curve' (~"polyline").Author:-
TIG - based somewhat on RickW's 'weld.rb'...
[but it has no close/face options, and also made suitable to be called from
other methods].Usage:-
Make a selection which includes the edges to be joined.
Run the script from the menu:
Tools > TIG-weld
or type in the Ruby Console:
TIG.weld +<enter>
or [recommended] set up a shortcut-key, say J [==Join?]Selected edges will then be 'welded' into a curve wherever possible.
Disconnected edges or branching edges might give unexpected results.
A curve will be split where any 'branching' edge intersects it.
The process is one step undoable.To use the tool run within another method include:
require('TIG-weld.rb')
*** >= v2.0 use:
require('TIG-weld/TIG-weld_code.rb')
to load it even if its extension is deactivated;
and later in the code use:
TIG.weld(true)***
use the 'true' to supress 'undo' complications.
It returns an array of the welded edges or 'nil' if none.
The calling method must make a selection of potential edges to
process, even if inside another context; perhaps iterated in turn,
see scripts like "TIG-weldall.rb" for an example of this...Version:-
1.0 20120305 First public issue.
2.0 20160130 Made into Extension. Signed for v2016 full compatibility.
Note: with v2.0 the alternative to TIG.weld() can be TIG::Weld.new()
3.0 20170307 Signed for v2017 full compatibility.
http://sketchucation.com/resources/pluginstore?pln=TIG-weld
-
Thank You TIG,
it works fine, but needs a lot of time for my geometries.
Is it possible to speed it up or if not, to implement a progressbar?
It still runs 30mins for 200.000 edges, no end in sight. I will abort now.
I will try with 15.000 edges and post the needed time when its done.
-
If I could have sped it up I would have.
It has to iterate every edge in the model and all groups/definitions and then decide which go into which connected curve - it's complex stuff, I'd leave it running as long as you can - it'll beep when done.
A progress bar would only slow it further and as soon as it hits a limit it'll white-out anyway and stop updating it, giving the impression it's stalled when it is actually still processing...
The Task Manager will show if it's still doing its stuff... -
Thanks TIG, we appreciate all your hard work!
-
Excuse me ,I would like to know,does this plugin merely fits for Windows?
-
No. It works on MAC too...
Most Plugins work on PCs AND MACs...
If there are limitations like something is for PC only, OR for Pro only, then this is spelled out in the instructions on the download page...
-
Hi Tig,
This may be a slightly different problem in that I am trying to use Sketchup 7. Is Tig-weld.rb supposed to work in that version of SU? I always get bugsplats.Thanks
John E
-
It should work on all versions [7-13] and OSs.
Bugpslats can happen with several legit plugins.
These Bugsplats are not usually from the legit plugin itself, but rather from an observer [looking at definitions and entities ?] which is added by a 3rd party 'rogue' plugin, that then breaks [and splats] when the legit plugin does some simple operations on a temporary group it uses in its processes...
A few other rogues might ill-advisedly change base Ruby classes relating to groups etc, and thereby break the legit plugin's code - but the result of these is usually to put errors in the Ruby Console and just abort the operation - so they rarely lead to a full-blown splat...
The rogues are listed in a quarantined set - search SCF.
These include old-podium versions, some newer BIM tools and SketchyPhysics...
To test for adverse affects of plugins on legit ones, use the SketchUcation Plugins Manager to disable some suspects [Tip: use Sets to remember where you started from!], restart SketchUp and see if TIG-weld then works... If it doesn't re-enable the disabled ones, and disable some more and retry... Once you get a shortlist of culprits temporary load them one at a time until TIG-weld breaks again.
Then you know the culprit...
Let us know what 3rd party plugin is causing the issue...
If in the unlikely event that you find TIG-weld still crashes... then please post an example SKP of what it reacts badly to -
Thanks Tig,
I'll try disabling plugins. I see that Tig-weld works in SU 2013 for which I've not installed many plugins yet. I'll let people know what I find.
John
-
A bit peeved when I looked at the long list of incompatible plugins that no longer work for SU2016. This is a request to TIG to update this fantastic plugin which I use probably on every project. Please update it for SU2016.... PLEASE!
-
@grice said:
A bit peeved when I looked at the long list of incompatible plugins that no longer work for SU2016. This is a request to TIG to update this fantastic plugin which I use probably on every project. Please update it for SU2016.... PLEASE!
Where is this mythical list of incompatible plugins ?***As far as I know
weld.rb
still works in v2016 [it's by RickW from Smustard.com] - have you tried it ?My own take on it -
TIG-weld.rb
- which is available from the SCF PluginStore - also works just fine in v2016.***I know many plugins are not yet signed [ the effort involved is somewhat disproportionate to its benefits - but complain to Trimble - not the authors - who have a life too ].
Signing allows them to work in all of v2016's Loading-Policies, BUT at the moment the shipped default Policy for v2016 is 'Unrestricted', which will then let ALL Plugins/Extensions load [just like they do in v2015] - even with 'Approve' you can choose to load an unsigned one.
So even when the RBZ has not been signed it will/can load...So '
weld
' [of both 'flavors' is NOT "incompatible"].
But if you find it's "not working", then please expand on the problems you've encountered... -
@grice said:
A bit peeved when I looked at the long list of incompatible plugins that no longer work for SU2016. This is a request to TIG to update this fantastic plugin which I use probably on every project. Please update it for SU2016.... PLEASE!
I can attest to the fact that TIG's weld plugin does indeed work in SU2016. If it doesn't for you, you've either not installed it correctly or you're using it incorrectly. -
when you log into the EW it will list the plugins (my plugins section) you have / use that isn't compatible with 2016, they're under a separate heading. Although I don't quite get it as they seem to install and work fine...
-
@juju said:
when you log into the EW it will list the plugins (my plugins section) you have / use that isn't compatible with 2016, they're under a separate heading. Although I don't quite get it as they seem to install and work fine...
As TIG wrote, it only means they haven't been signed by Trimble which doesn't affect the way they work. He also has a good point about the time and effort on the part of the authors to get them signed by Trimble. The vast majority of plugin/extension authors aren't getting paid to make them and keep them up. They need to make a living, too.
-
Not to mention that complaints about issues with the Extension Warehouse should be addressed to the Sketchup Forum where Trimble employees can see them.
Sketchucation released its plugin store before the EWarehouse and looks after the plugins there. Trimble is entirely responsible for the extension Warehouse. -
@juju said:
when you log into the EW it will list the plugins (my plugins section) you have / use that isn't compatible with 2016, they're under a separate heading. Although I don't quite get it as they seem to install and work fine...
That's because ANY extension/plugin which worked in v2015 will also work in v2016M0 in 'Unrestricted' its Loading-Policy - signed or unsigned.
So Trimble are [currently] being disingenuous in 'blacklisting' any 'unsigned' RBZs.
But they have thus far handled this whole issue very shoddily [IMHO].It takes not inconsiderable effort for authors to recast their plugins/extensions to be fully v2016 compatible, and then to get their RBZs signed by Trimble via the Extension-Warehouse.
Many of these are 'free' so there's little incentive for a quick fix.
Many are also not available through the EW - but only through other trusted outlets like the SketchUcation's PluginStore [aka ExtensionStore³] or Smustard.com.
But... after considerable 'behind-the-scenes' pressure "they" have thus-far agreed to provide the [default] 'Unrestricted' Policy, which allows v2016 to work much as v2015 in this regard.So any Plugin/Extension which worked with v2015 will [probably***] work with v2016M0.
***There are some observer changes, which could break a very few extensions - but these will probably have been updated anyway...
The whole question of what protection/comfort a 'signed' extension gives to a user is illusory.
Trimble's smoke-and-mirrors.
Previously if a user got an RBZ from the Extension-Warehouse, SketchUcation's PluginStore [aka ExtensionStore³] or Smustard.com [let's called the a 'trusted-source'], then they could be assured that the RBZ's contents were 'kosher'.
These were only lodged on these sites after checks...
Now for v2016 use [unrestricted by the current Loading-Policy] SketchUp v2016 expects a 'signed' HASH RBZ.
BUT if you get a 'signed' RBZ for v2016, it is NO different in effect...
What 'comfort' does a user get from this HASH - no more than they had before - because the were getting their RBZ from an already trusted source.
BUT Trimble now shoot itself in the foot.
In v2016 a signed plugin/extension will 'break' and not load if its HASH does not exactly match its RB/RBS/RBE files within the signed RBZ [and also several other files like HTM/MTML/JS/CSS].
The likelihood of this happening with a file from a 'trusted-source' is ZERO.
It is very unlikely to contain 'malicious content'.BUT let's assume an alternative scenario...
Some hacker ['hacks_are_us'] gets an RBZ and he changes it.
If someone downloads that RBZ from 'hacks_are_us', then that version if it has changed the shipped content will fail.
At least until they learn to hack the signed HASH file !
BUT if they are circumspect it can be made to contain malicious content, even today.
It relates only to "Extensions" - plain vanilla "Plugisns" are [ironically] exempt from such hacking !It relies on the EW signing regime.
You must submit a set of files in the RBZ in RB format.
Encrypted files - RBS and the new RBE - are NOT accepted.
This is so the checkers can easily read what you submit.
An extension must specify the path to the file it first loads.
E.G.Aardvark.rb
has a subfolder containing the main code,
E.G"Aardvark/Aardvark_code.rb"
This works if the file is NOT to be encrypted.
It is necessary when submitting RBZs to the EW, otherwise the not-yet-encrypted files will NOT load.
So authors will ship the RBZ withAardvark.rb
specifying the paths
"Aardvark/Aardvark_code"
Sketchup is clever enough to find a file that is .RB or .RBS and load that.
If the author chooses to do no encryption all is well [their IP is exposed, but they probably don't care that much].
If the author chooses to encrypt as .RBE [suitable for >= v2016] then in >=v2016, that RBE loads in preference to all other files it finds using the same 'basename'.
The newer RBE is strongly encrypted, and thus far it is un-hacked and protects authors' IP - but this protection is at the limitation of only working in >= v2016 - with the downside being that it limits the potential user-base...
BUT if the author chooses to encrypt as RBS [a format will limited protection from IP hacking. BUT on the up-side compatible with ALL SketchUp versions - including v2016 (despite what the signing-portal says!)] then it will load OK in all current versions of SketchUp.
It's susceptible to hacking, but if the extension is old its IP is already compromised !Now the problem.
SketchUp - including v2016 - has a loading precedence - when a extension looks forAardvark/Aardvark_code
it finds a match.
Perhaps in >= v2016 it findsAardvark_code.rbe
, and loads that - in preference to all others.
But in v2016 [when there's no RBE], or other earlier versions, it findsAardvark_code.rbs
, and loads that.
BUT now the rub...
If there is a file namedAardvark_code.rb
it loads that in preference to the RBS file that might be there.
But why would both files exist ?
When an author submits an RBZ for signing, then it is returned to him with either ALL RB files kept in the subfolder [no encryption], or ALL RB files in the subfolder encrypted as RBS*** - as he chose.
The signed HASH file reflects this, so ANY alterations to those files in that subfolder are flagged, and it is deemed invalid.
However, if the subfolder contains RBS files, the HASH checker [currently] has no way for spotting that a new RB file has been added to the RBZ and the 'loader' will load that instead.
So if my RBZ 'Aardvark.rbz
' containedAardvark.rb
to load it and it's encrypted by EW to haveAardvark/Aardvark_code.rbs
, then if a hacker addsAardvark/Aardvark_code.rb
then that loads in preference.
The addedAardvark_code.rb
is not spotted in the [current] HASH check.
It can contain 'malicious content', the it can loadAardvark_code.rbs
.
This the user has no idea what's happened - the tools works exactly as advertised.
BUT it could have done something bad in the background - hacking their system, passing details to unauthorized 3rd-parties etc...This 'loophole' is a poor show by Trimble.
It'd be easily fixed if the SketchUp extension loader code only only allowed the files listed in the HASH to load - currently it does not.Changing the load order to RBS before RB is of no real benefit either, because an RBS format file is easily made, and if added to the RBZ it would then supersede the RB [albeit in un-encrypted low-value plugins' RBZs]...
***An RBE file does load first, so that avoids the hacking issue, but limits authors to >=v2016 users only...
So the only supposed benefit of a signed RBZ is that it gives you comfort that it is 'genuine'.
But that is "illusory".
Getting it from a trusted source gives you that confidence.
Getting a signed RBZ from a dodgy site means nothing - unless it is only suited to >-v2016, then it could be hacked - but still seem to be perfect.
So sensible users, who getting their RBZs from trusted sources, have no more comfort than they had before [which was always 'considerable'].
BUT stupid users, who get their RBZs from less reputable sources. will only have themselves to blame, if they contain 'malware' etc: the signing process offers no real protection for them for that [<v2016 or in v2016's Unrestricted Policy].
BUT that begs the question, "Why do we worry about 'protecting' them anyway?"
It's a mess. -
I take it all back... despite Trimble's plugin warehouse listing this plugin as not compatible with SU2016, I installed it anyway and it is working fine...
Looks like Trimble need to up their game in terms of keeping their customers satisfied. Isn't that what we pay our yearly subscription fees for?
-
Here's v2.0 http://sketchucation.com/pluginstore?pln=TIG-weld
It's made into an extension and is also signed, so it's fully compatible with all of v2016's 'Loading Policies'.Note:
Because it needed a name change when becoming a compatible extension, note that if you have a old shortcut key set you to 'Tools/Weld' you need to reset it to it's new persona = 'Tools/TIG-weld'... -
Hi - new to sketch up and SketchuNation. Trying to install your Weld extension, but I am getting an "Outdated Signature" error. Even in unrestricted mode it will not load, and my Google search did not help much. Any thoughts?
Advertisement