[Plugin] Coords Text Tag from Datum

[Plugin] Coords Text Tag from Datum

Postby TIG » Thu Nov 04, 2010 5:06 pm

Read its Documentation and Release Notes and Download its latest RBZ archive from the SCF PluginStore:

Download


Or get/install the SketchUcation Plugin Store toolset to AutoInstall plugins and Manage them...
http://sketchucation.com/resources/plug ... e-download
2
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby Dave R » Thu Nov 04, 2010 5:09 pm

Thanks TIG. Can those text tags be collected into a CSV file to use for making a table?
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby TIG » Thu Nov 04, 2010 5:25 pm

Dave R wrote:Thanks TIG. Can those text tags be collected into a CSV file to use for making a table?

They could be... you'd just search Entities for Text with the appropriate Attribute ["CoordTool_Datum","text"], and read their Text.text strings ["Coords: 12.34, 56.78, 9.00"], with whatever manipulations you wanted [e.g. strip off 'Coords '], and then 'puts' them into file like a .CSV etc... You could first put them into an Array and then .sort! it before then iterating through it to 'puts' each string into your CSV file...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby watkins » Thu Nov 04, 2010 7:14 pm

Dear TIG,

Do you dream in Ruby? I will try out the plugin this evening.

Many thanks,
Bob
0

watkins 
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby Ken » Thu Nov 04, 2010 8:12 pm

TIG

Another great plugin. Just a question, would it be possible to set and reset the "Coord Datum" just by left clicking a point after selection the menu option "Set Coord Datum".


Thank you

Ken
0
Fight like your the third monkey on Noah's Ark gangway.
User avatar
Ken 
Premium Member
Premium Member
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby TIG » Thu Nov 04, 2010 8:34 pm

Ken wrote:TIG
Another great plugin. Just a question, would it be possible to set and reset the "Coord Datum" just by left clicking a point after selection the menu option "Set Coord Datum".
Thank you
Ken

This is v1.0 ;)
At the moment the Coords.Tags update every time you open the model or move one.
[I still need to add some extra observers for opening a skp from the menu etc...]
I could introduce a 'freeze' option where you'd remove the update observer/attribute...
I felt that you'd set a Datum once [if even that] and then all you coordinates would be always relative to that?
One thing I can see is that when you model in mm you might want the coords in meters ! or inches >> feet. Then 'freezing them might be useful ?
I await user feedback to get this how 'we' all want it...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby watkins » Fri Nov 05, 2010 12:06 pm

Dear TIG,

I tried the plugin last night, and I should like to make a few observations and comments.

First, it either doesn't do what I should like it to do, or I'm not using the plugin properly. When I change the datum to say 5,10,10 (in mm), it adds these numbers to the x,y,z values of the points selected. So, if I hover over a cpoint at say 5,10,10 (the new datum) it reads 10,20,20, which is not what I need. The new datum point should read 0,0,0, and the origin of the World co-ordinate system (SU's default co-ordinate system) should read -5,-10,-10. The ideal would be as follows:

* A dialog box that sets the datum either by entering the x,y,z values, or by clicking on a cpoint. The box should also have a Rest button to reset everything back to the World co-ordinate system. I think cpoints could be used for all points of interest as they make selection easier and unambiguous.

* A dialog box that displays the x,y,z values of the point selected (point and click), with a counter to record the number of points selected, with a box to enter a three character identifier (A01, A02 etc), and a Save/Delete button to either save the data to a spreadsheet (identifier and associated co-ordinates) or to delete the point from the running total.

Thank you for all your efforts.
Kind regards,
Bob
0

watkins 
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby Gaieus » Fri Nov 05, 2010 1:07 pm

Hi TIG,

Excellent so far :thumb:
(don't listen to Bob - this is exactly what I need). :D

If I may also have some wishes...
  • Now there is this text tag but could you also add a guide point where it is so that I could snap geometry to it?
  • Also, it would be wonderful if (from a dialog) I could also enter points manually.
Say I first set the coords datum to 100,100,100 then relative to this I want to enter a cpoint at 200,200,200 (that would of course just be 100,100,100 from the model origin).

The case is (as it seems) that Bob and I are approaching the problem from different ends.
0
User avatar
Gaieus 
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby Dave R » Fri Nov 05, 2010 1:22 pm

I think what Bob would like to do is generate a table as shown on the right in this screen grab. In this drawing, 0,0 is at the upper right corner of the part. I would find that useful from time to time as well.

0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby watkins » Fri Nov 05, 2010 2:54 pm

Dear David,

That is exactly what I should like my friend.

I suppose TIG's plugin would go half way there if I were to insert negative as well as positive numbers into the datum dialogue box. With reference to my previous example, if I had entered -5,-10,-10 instead of 5,10,10, then the point at 5,10,10 would have appeared as 0,0,0 instead of 10,20,20, and so perhaps it just a matter of using the plugin correctly. I will try out the idea tonight.

Another idea: If the datum dialogue box had a 'query' icon/button that one could click on and then query a point, and with the datum field automatically filled after selecting a point, then that would be really helpful. Now, how lazy can one get!!!

Kind regards,
Bob
0

watkins 
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby Dave R » Fri Nov 05, 2010 3:54 pm

Dear Bob,

I figured that would be your goal. So, while we're heaping work on poor TIG...

Suppose the plugin worked something like this:

    Open the component for editing.
    Select all of the geometry with a triple click of the Select tool.
    Start the plugin.
    The plugin identfies all of the circles and arcs in the selection and places a cpoint at center.
    After that job completes the user clicks on the desired cpoints and the plugin places text tags. the text is A1, A2,...An. Perhaps you hit the up arrow to increment the leading letter in the tags.
    All the while the user is clicking and placing tags, the tag and the coordinates are being collected by the plugin.
    When the user clicks Enter or something the plugin pops up a message indicating that a CSV file has been saved to the same directory in which the SKP file has been saved.

As always, I can dream them up but it takes a wizard like TIG or Thomas or someone else that isn't me to figure out if and how it can be done.
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby Ben Ritter » Fri Nov 05, 2010 4:25 pm

TIG, another BIG thank you.
0

Ben Ritter 
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby TIG » Fri Nov 05, 2010 9:13 pm

Thanks for the feedback... My new Uni lecturing commitments will delay things until say Wednesday next week - but please post any other comments / ideas in the mean while...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby watkins » Fri Nov 05, 2010 11:29 pm

Dear TIG,

What university and waht subject?

Thanks for all your help.

Bob
0

watkins 
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby JClements » Fri Nov 05, 2010 11:35 pm

Hi TIG:

1- Running SU8, PC, XP. My VCB doesn't display anything

2- I already have models to which I have used #heightool.rb (and labels).

Could one of the following be done?
Change heighttool.rb so it uses the same model tag variable (converts the old tag to the new).
or
Combines both into one ruby with the option to display the Z value only in the labels? (converts any existing heightool tag to a coordinate tag).

Regards, John
0
Last edited by JClements on Sat Nov 06, 2010 1:40 am, edited 1 time in total.
John
Illustrator
Beaverton, Oregon
User avatar
JClements 
Premium Member
Premium Member
 

Re: [Plugin] Coords Text Tag from Datum 20101104

Postby TIG » Fri Nov 05, 2010 11:41 pm

watkins wrote:Dear TIG,
What university and waht subject?
Thanks for all your help.
Bob

At my old Alma Mata - Newcastle upon Tyne, School of Architecture - it's the 'SketchUp and Ruby Scripting' module for ~16nr year-5/6 'masters' students [I did a little bit last year too] ... it least until the new year... then the funding will probably evaporate with the latest round of 'cut-backs'...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum v1.2 20101118

Postby TIG » Thu Nov 18, 2010 4:33 pm

Here's v1.2 viewtopic.php?p=284829#p284829
It totally revised and updated with many more options and settings.
Please read the note in the linked post...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum v1.3 20101118

Postby TIG » Thu Nov 18, 2010 5:22 pm

Here's v1.3 viewtopic.php?p=284829#p284829
An additional option to Export all of the Coords-Tags to a CSV file is added.
See the notes in the linked post...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum v1.3 20101118

Postby Dave R » Thu Nov 18, 2010 5:38 pm

Excellent, TIG. This works quite nicely. I'll bet Bob will be pleased.
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum v1.3 20101118

Postby Gaieus » Fri Nov 19, 2010 10:36 am

Thanks TIG again; this CPoint enhancement is very essential for me! :thumb:

(Now if I could also add CPoints/Coord-tags by inputting into a box the XYZ values...) :roll:
0
User avatar
Gaieus 
 

Re: [Plugin] Coords Text Tag from Datum v1.3 20101118

Postby TIG » Fri Nov 19, 2010 10:51 am

Gaieus wrote:Thanks TIG again; this CPoint enhancement is very essential for me! :thumb:
(Now if I could also add CPoints/Coord-tags by inputting into a box the XYZ values...) :roll:

OK, OK...
What format would the input be would you want it to reflect your current Coords-Tag Settings ?
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum v1.3 20101118

Postby watkins » Fri Nov 19, 2010 11:47 am

Dear TIG,

I have just noticed this post. Many thanks for all you efforts, and the continuing development of this plugin.

I will look at it more detail when I get home.

Kind regards,
Bob
0

watkins 
 

Re: [Plugin] Coords Text Tag from Datum v1.3 20101118

Postby Gaieus » Fri Nov 19, 2010 1:43 pm

TIG wrote:What format would the input be would you want it to reflect your current Coords-Tag Settings ?

Well, when I have already set the co-ordinates (say for example) X=1000, Y=1000, Z=1000, I then wish to place guide points (maybe with an option to receive a tag - or a tag with the option to add a CPoint)) to say (again, with the above example) at 2000/2000/2000 which in this case would of course be only at 1000/1000/1000 relative to the model origin.

To make the example clear; when we have the chance to dig "cleanly", we generally work in a 10m x 10m (or 5mx5m or whatever) grid system (where we keep section walls between these rectangular pits). This grid system is set up according to our national orthographic grid system so whenever I find a Roman coin (again, for instance), we take the exact location with those surveying tools.

Now when I set up an excavation with a grid plugin (there are lots of fine ones) and I want to quickly display the (already) known location of this coin, I could then have an input box to enter the xyz co-ordinates (maybe a yes/no for an additional CPoint) rather than trying to guess where it is.

In other words; what the plugin already does just vice-versa.

And of course, I am already very grateful and would not "urge" you in any way...
;)
0
User avatar
Gaieus 
 

Re: [Plugin] Coords Text Tag from Datum v1.4 20101119

Postby TIG » Fri Nov 19, 2010 3:20 pm

Here's v1.4 viewtopic.php?p=284829#p284829
It fixes a glitch with incorrect reading of the Datum.
It also adds two new tools:
Import Coords-Tag from CSV [optional units and optional cpoint]
Add Coords-Tag by Dialog [input XYZ and optional cpoint, using current units' settings]
Please read the notes on the download page as linked...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum v1.4 20101119

Postby Gaieus » Sat Nov 20, 2010 4:54 pm

Hi TIG and many thanks again but what I would need is not exactly this.

First of all, the add coord tag by input seems to add the tags in inches (2.54x farther than needed).

The other thing is that these points are now added relative to the current origin (that would also be cool in fact but then I could simply use 0/0/0 as my origin). What I would need is to add the coords according to the modified origin co-ordinates. So if I am 800 kilometres away from our national origin (that is somewhere in Slovenia, Austria or Italy AFAIK :roll: ), and add a coord at 800.000.125 - or 800,000,125 on my Hungarian keyboard system (i.e. only 125 centimetres from my model origin), it would be just 125 cms from my origin.
0
User avatar
Gaieus 
 

Re: [Plugin] Coords Text Tag from Datum v1.4 20101119

Postby Gaieus » Sat Nov 20, 2010 4:56 pm

Wait a minute, something else is also wrong here. My model origin is not at 100/100/100 but all negative; -100/-100/-100!

I tried again and indeed it sets it to negative! :roll:
0
User avatar
Gaieus 
 

Re: [Plugin] Coords Text Tag from Datum v1.4 20101119

Postby Gaieus » Sat Nov 20, 2010 5:04 pm

Some correction/modification...

It only works in inches if I set the coords in model-units. Although I have centimetres in my template, it doesn't seem to recognise it.

Then if I set the units to centimetres, it will correctly add the coords - except it swaps my origin from + to - (see screenshot) and does not add the coord tag where I wish (so what is written above is still valid).
0
User avatar
Gaieus 
 

Re: [Plugin] Coords Text Tag from Datum v1.4 20101119

Postby TIG » Sat Nov 20, 2010 5:17 pm

I'm sure this is 'fixable'... :roll:
Let's say you set your Coords-Tag Datum of X=100m, Y=100m, Z=0m.
This then interprets the SKP origin SKP[0,0,0] as CT[100m,100m,0m] which is the text shown in the Coords-Tag that is placed at the SKP[0,0,0] ?
If you add a Coords-Tag manually at SKP[1m,1m,1m] its displays CT[101m,101m,1m] in the Tag.
If you want to Add a Coords-Tag via the dialog at say CT[102m,101m,1m] you enter those values three, and it then places a new Coords-Tag in the model at SKP[2m,1m,1m] - because its SKP[X,Y,Z] = CT[typedX - datumX, typedY - datummY, typedZ - datumZ].
I fear I might have got my +datum/-datum calculations in a twist - I'll revisit the code and issue an update... :roll: :geek:
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] Coords Text Tag from Datum v1.4 20101119

Postby Gaieus » Sat Nov 20, 2010 5:19 pm

Hm. Very interesting. If I set the origin to -100/-100/-100, the plugin puts the origin in correctly at 100/100/100 and works as intended (i.e. a point at 200/200/200 is at 100/100/100 from the model origin). So maybe yes, you twisted something...
:)

Yet the centimetres need to be set otherwise it works in inches.
0
User avatar
Gaieus 
 

Re: [Plugin] Coords Text Tag from Datum v1.5 20101120

Postby TIG » Sat Nov 20, 2010 5:56 pm

Here's v1.5 viewtopic.php?p=284829#p284829

The balls up in the datum v. tag's values is now fixed :roll:

The Coords-Tag values correctly show the value relative to the set Datum - irrespective of the method used to input them - i.e. manual-pick/add-by-dialog/imported-CSV...

Gaieus - the XY/Z units should be either the SKP's current-units or the XY/Z units you choose [or XY Lat/Long?] - please try and report back...
0
TIG
User avatar
TIG 
Global Moderator
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 

Next


 

Return to Plugins

cron

Who is online

Users browsing this forum: Google Bot, MarekSk and 10 guests

Visit our sponsors: