Copy with base point (as it does in Autocad)

Hello,
After some time using Rhino, I still cannot figure out how to copy and paste an object with the specified base point (as it does in Autocad):

  • In the same file

  • Between 2 open files

Where is this feature hidden?
Sincerely.

Use the command Copy (not copy/paste) - you can specify a “from” and a “to” point.

There is no direct way to do this, copy/paste between files (or in the same file) always pastes the objects in the same location as the source.

1 Like

Thank you.
As I understand, there is no default shortcut (like Ctrl-Shift-C -> Ctrl-Shift-V in Autocad)?

Hello! It is a late reply, but maybe someone else is happy to read a solution!

There is no default shortcut, however you can make your own shortcut to do exactly this. In the properties you can add some commands to the shortcut Crtl-Shift-V. Besides, you can make your own python- (or rhino-)script programs. Combine these and you can make a paste command which pastes the copied object at a certain place.

First, I made a pythonscript named “MoveToCameraTarget.py”:

import rhinoscriptsyntax as rs
rs.Command("!'_Paste")
objects = rs.SelectedObjects()
if objects:
    box = rs.BoundingBox(objects)
    if box:
        x = 0
        y = 0
        z = 0
        for i, point in enumerate(box):
            x += point[0]
            y += point[1]
            z += point[2]
        x = x/8
        y = y/8
        z = z/8
        
        avPoint = rs.CreatePoint(x, y, z)
        target = rs.ViewCameraTarget()[1]
        moveVector = rs.VectorCreate(target, avPoint)
        rs.MoveObjects(objects, moveVector)

Next, I added the Ctrl-Shift-V shortcut in the properties:
!_-RunPythonScript MoveToCameraTarget.py

If you now paste an object in your document, it will automatically paste the objects, calculate the points of the boundingbox, take its average, and move the objects from that average point to the camera target.