I wonder what is happening here?

Thinking

Bitmapped Images

In this exercise I draw a shape on the left side of the drawing area in frame 1. I then copy the shape into frame 6 and then rotate this second copy place on the right of the drawing area. These shapes are drawn on a bitmapped layer.

To select, for the purpose of Cut operation, for bitmapped images is used Bit_Select tool.

I then select the left hand copy and apply the Cut function on the top line menu.

I then create a new frame 11 and then using the Paste function from the top line menu.

What is see in this sequence of using the Cut function and then selecting another frame, frame 11 and then using the Paste function is what I expect to see!

Vector Images

When I carry out the same proceedure using vector drawings, the results are shown below. To select for the vector images I left clicked on the shape using the Vec_Select tool.

The 1st two stages, the results are what I expect to see, but the third illustration is not, the paste operation seem to be as if I had duplicated the 1st drawing.

I only selected the right hand shape in both cases.

Thinking

The pclx file is included for your examination.

Cuts.pclx (67.5 KB)

There is of course a simple work around in this example. The Pencil2D user simply selects the left had shape and removes it using the same Cut function. This however is more complex if the shapes are components in a character drawing and overlap.

The shapes used in a vector drawing are held as a series of Bezier curves. You can examine these by opening a .vec file using a text editor, like Windows Notepad.

In the above example Pencil2D has correctly identified the lines in the file, which are stored in XML format and deleted them correctly.

BUT during the Paste operation Pencil2D has used the complete .Vec file for the frame instead.

Copy Operations

If you select shapes to be copied and then attempt to copy them using Copy, you then select another frame, perhaps by adding a new frame, and the use Paste to effect the copy operation. You’ll copy the entirity of the contents of the first frame into the desination frame. You have effectivly performed a Duplicate operation.

To acheive the desired result, you’ll have to select the shape to be deleted and then remove it using a Cut operation.

The listing below is the initial frame with both shapes.

The listing below containes what represents the right hand shape only. In the Cut example this is correctly done, BUT in the Paste and the Copy operations it is the first listing that is used!

Thinking

Why is the Cut performed correctly using the correctly identified and the Paste operation in both cases using the incorrect data?

If the same data was used for the Paste, as used for the Cut operation then everything in the garden would look good!

As the result of some experiments, I’ve discovered that Pencil2D does not use the ‘clipboard’ type mechanism within the computers operating system.

The Cut, Copy Paste etc uses software mechanisms buried deep in Pencil2D.

I’d discovered, some time ago that you couldn’t use Copy & Paste etc. to transfer data between multiple copies of Pencil2D, running in different ‘windows’.

The above makes it more difficult, but not impossible to develop ‘work flows’ that overcome the above constraints.

Pencil2D does use the built-in clipboard, so it is technically possible to to copy keyframes between two Pencil2D instances. We don’t recommend having two instances running at the same time for various reasons though.

The clipboard logic is however very basic in the way that we don’t store Keyframe data. For bitmap keys, we store the image as png and for vector we don’t store anything.

It works in the same instance because we keep a copy of each keyframe but in a proper implementation, we would parse the clipboard content and create keyframe content from that information.

The feature is on my todo list.

@StopMotionVector The behavior you’re seeing with Vector where copying leads to a copy of both vector strokes on the third frame, that’s a bug.

Hi MrStevens

Thanks for the explanation.

Following the explanation, I have found an work around which enables me to acheive the desired results. I do however find myself doing things, which from a logical viewpoint seem counter intuitive!