Gradient Infill Puts More Plastic Where You Want It

Gradient Infill Puts More Plastic Where You Want It

It is always tricky setting the infill for a 3D printed part. High infill parts are strong but take longer to print, while low infill prints take less time, but are weaker internally and in danger of surface layer droop between the infill pattern. [Stephan] has a better answer: gradient infill. You can see a video below and find his Python code on GitHub.


The idea is simple enough. In most cases, parts under stress see higher stress near the surface. Putting more material there will make the part stronger than adding plastic in places where the stress is lower. [Stephan] has done finite element analysis to determine an optimal infill pattern before, but this is somewhat difficult to do. Since the majority of parts can follow the more at the edges and less at the center rule, gradient infill makes sense except for a few special cases.

Of course, the real question is: how do you create parts with this type of infill? Some slicers have infill settings that can almost get you there. However, the setup for them isn’t easy. For example, KISSSlicer’s paid version will take a grayscale image to set the infill density. [Stephan] noticed, though, that Cura — and probably most other slicers — put comments in the G-code to show where different features such as infill start. By changing the extrusion amount during infill, you can use the same basic pattern, but still, get the gradient you want.


He wrote a simple program to postprocess the G-code before it is sent to the printer. He computes the distance from the outside of the part and based on ..

Support the originator by clicking the read the rest link below.