Site Tools


This is an old revision of the document!


Peter's Tools 2.0

Summary: Miscellaneous scripts compiled into a plug-in, with a toolbar) (developed primarily by Peter Harris).

I'm not supporting Rhino V4 or V5 anymore, though the old plugins for those versions are still linked at the bottom of this page. Also, please remember that these are free tools that you use at your own risk, of course.

What's new since Version 1.98

  • I've added Achive tools and improved function of the timer tools significantly. I've also added tools for batch renaming files with user-specified text, and a tool for adding a point at the center of a selected object's bounding box. I've removed all file-utility tools completely because I don't feel confident that they are robust.

Overview

This is a collection of scripts that I've written (with the help of many people) which I turned into a plugin and a toolbar to go with it. The download link is at the bottom of the page. Thanks to all who have helped me on these scripts! Especially Pascal, David, Dale, and Mitch.

Commands

The commands currently available in the PetersTools plug-in are:


Geometry-creating or editing tools

  1. TrimAtLine - Prompts you to draw a line to use as a trim line, pick whatever you want to trim, then right-click to delete the line.
  2. TrimAtZero - Same, but starts line at 0,0
  3. SplitBoth - Splits two sets of surfaces with each other.
  4. SplitWithEdgesAndCurves - Script that automates typing in 'crv' after picking the split command.
  5. JoinCurvesByClosestEnds - Joins two curves by closest ends by adding two straight lines.
  6. QuickCage - Click one of 15 numbers (2 through 16) on the command line or type in a number, and the tool creates a bounding-box cage around your object with that many points in each direction. Great for quick edits.
  7. SetX - Flattens an object in the world X direction.
  8. SetXTo0 - Flattens an object in the world X direction to 0.
  9. SetY - Flattens an object in the world Y direction.
  10. SetYTo0 - Flattens an object in the world Y direction to 0.
  11. SetZ - Flattens an object in the world Z direction.
  12. SetZTo0 - Flattens an object in the world Z direction to 0.
  13. MagicCap - Creates a planar surface from any selection of curves and/or surface edges. Here's how it works:

  1. HideAllUnselectedCurves - Hides all unlocked visible unselected curves.
  2. HideAllUnselectedPoints - Hides all unlocked visible unselected points.


Timer

  1. TimerTools - Simple tools for keeping track of time spent on a project. Nested options include StartTimer, StopTimer, TimerLog, CalculateTotalHours, and LegacyTimerLog. The TimerLog is a text file of the start and stop times and it is part of your current rhino document. It can be edited manually if you make a mistake by not stopping your timer. LegacyTimerLog is for users who used the old timer that saved data to a text file so that they can still find that old text file (but the new timer won't add to that text file or calculate totals from it. This will go away entirely in the next update.)


BOM and object properties tools

  1. BOM - Calculates object weights based on density and exports object notes and other attributes to a .csv file or to the clipboard. (Note: Objects need to have a real material assigned in order to do the weight calculations. See next tool…) Now includes more options and lets users select which columns to export. Items that can be exported to the bill of materials includes Part Name, Real Material & Weight, Box Size (bounding box), Object Notes, Volume, Surface Area, Layer, Volume Centroid, and Area Centroid. This tool has a lot in common with Rhino's built-in properties export (export → .csv), except that this includes real material and weight, so if you don't need those properties, try the built-in tool first!
  2. RealMaterialTools - Includes options to set a real material to objects (includes a way to create custom materials based on the density, and it comes with some plastics already in there), match real materials, select objects with no real material, or delete real material data from selected objects.
  3. ObjectNoteTools - Includes options to set an object note to objects, match object notes, select objects with no object notes, or delete notes from objects. Object notes show up in the BOM or in the DotWithData tool.
  4. DotWithData - Adds annotation dots to selected objects with text option of either part names, layer, real materials, weight, object volumes, object surface areas, object notes, volume centroid, area centroid, or bounding box dimensions.
  5. SelUnnamed - Selects all unnamed objects.
  6. NameObjects - Lets you name a bunch of objects in serial fashion (brings up a box for each selected object one by one.)
  7. BatchNameModifier - Lets you add text to a batch of object names at once, either at the front or end of the name.


Archive This group of tools manages an archive of bits of geometry you might need later. It does this simply by creating a layer called Archive that stays turned off, and managing adding or retrieving items from that layer. I created this because I use Hide just to hide things for a few moments, and I needed something else for longer-term holding of things I wanted to keep around just in case they are needed later.

  1. Archive - Has 3 nested options. ArchiveObjects moves objects to archive layer. ArchiveCopy moves a copy of objects to the archive layer. UnarchiveSelected lets you pick objects from the archive layer to move from that layer to the current layer.


Misc tools

  1. ZoomToUnlocked - Zooms to all unlocked objects ('normal' objects).
  2. ZoomToUnlockedAll - Same as zoom to unlocked, but all views.
  3. DetailsTools - Tools for modifying all details in a layout at once. Includes ability to change display mode in all, zoom extents in all, make scale match in all, or apply your own macro or command to all details.
  4. AddPointAtBBoxCentroid - Adds a point at an object's bbox center.
  5. AboutPetersTools - Brings up a box showing you what version you are running.


Installation in Rhino 6 or 7

  1. Download the zip file to either your downloads folder or a user folder (C:\Users\(user-name). Unzip to the same place.
  2. Right-click on the PetersTools.rhp file and select Properties. On the General tab, see if the file is blocked. (It'll say so near the bottom of the page.) If so, unblock it. This cannot be done unless the file is in your downloads or user folder. (Actually, I've heard that desktop works, too.)
  3. It may work to drag & drop both files into the Rhino window. This is the easiest solution. If that doesn't work, try:
  4. Copy the PetersTools.rhp file to your Rhinoceros 6.0 or 7.0 (64-bit)\Plug-ins folder.
  5. Copy the PetersTools.rui file to wherever you like to keep toolbars.
  6. Start Rhino.
  7. Run PluginManager and press the install button. Browse to your Rhinoceros x.0 (64-bit)\Plug-ins directory and select PetersTools.rhp.
  8. Load the toolbar that you saved by going to the Tools menu, pick Toolbar Layout, then File/Open the toolbar file.
  9. If you then try to use the tools and encounter 'unknown command', go to Tools→options→plugins, check to make sure Rhinoscript is Enabled.



Download

Download link for Rhino 6 and 7 users: https://www.dropbox.com/s/bex9x9s78ha63fb/PetersTools2.0.zip?dl=1

Download link for Rhino 5 users: https://www.dropbox.com/s/zcjd1juurx2jrff/PetersTools1.93.zip?dl=1

Here's the Rhino 4 version, which may have different options… Download link for Rhino 4 users (I think this is the right file!): peterstoolsv1.25.zip


E-mail me with your questions and feedback on this plug-in. I get very little feedback, so anything I get really helps!

people/peterharris.1606928851.txt.gz · Last modified: 2020/12/02 by peter_harris