Can I ask a question about the interaction between Pencil2D and ffmpeg software?

I’ve had strange results when exporting either to the .GIF and to the .MP4 formats.

These include artifacts generated during the editing process.

If a user of Pencil2D generates a .pclx project file. This can be viewed within Pencil2D by pressing the Play button in the timeline window.

This causes Pencil2D to display the frames in order and if the repeat option has been clicked will repeat this process until the stop button is pressed.

When the Pencil2D user selects export as either .GIF or .MP4 format these screens are grabbed and transferred via the ffmpeg software to the appropriate files.

Thus any artifacts displayed when using the play button in the Timeline window, will be transfered into the files.

The work around I use is to save the file, before carrying out the export operation.

Is my understanding of how these operations are performed within Pencil2D correct?

Most of what you said is correct, but it’s not accurate to think of think of video exporting as doing a screen grab of each frame. If it were to do that, lots of stuff that shouldn’t be in the exported video would be included, such as onion skins, relative layer transparency, selection borders, etc. In actually, there are separate functions to handle rendering image frames for export and for display.

If you can find a reliable set of steps to reproduce your artifact issue, that would be the best way to help us look into the issue further. A screencast video or set of screenshots showing the issue and how it differs from what you expect, along with a project file, would be the next best thing if you cannot reproduce the issue consistently.

1 Like

You have stated that Export as .GIF and .MP4 does not use screen grabs. How then do you explain what has happeded when this project was exported?

The images below are screen grabs of the 1st two frames from the project.

All of the frames in the project the light grey shape fill was selected.

The animation below is the project exported as a .GIF file.


The same effects were experienced with the .MP4 file export!

This file, is the project file Edit_Artifacts.pclx (45.7 KB)

If you don’t deselect a fill on a vector layer and then export it as a .GIF or .MP4 file the selection indications are transferred to the final image on screen!

This to me indicates that the image on screen is a screen grab!

If the fact that the image of the stationary object proves that the images on screen are screen grabs, then zoom in.

The pattern superimposed over the grey colour is the pattern that appears, when a fill is selected for applying a colour!