Get PCG Painter blueprints:
Unreal 5.5 is mandatory ! No support for versions below 5.5 !!
PCG Painter is a Blueprint Scriptable tool which allows you to paint a PCG graph in the world, on any objects ( by default, it traces all Visible objects ). As it’s 100% made with Blueprint and PCG graph, it’s easily customizable.
To find the tool, you have to activate the “Scriptable tools” mode:
The tool works in three steps:
- Trace “root points” on visible objects according to “brush strokes” ( click and drag from the tool ).
- Scatter points around those root points, in the given radius, using the samples count parameter and project them on the visible objects.
- Execute a selected PCG graph with those points as input ( roots + scattered ).
Tool parameters
Graph: The PCG graph instance which will be executed on root and scattered points ( only graph instance are supported, not regular PCG graphs ).
Show graph instances parameters: Display the selected PCG graph instances parameters ( if any exposed ), they can be tweaked directly from this UI widget.
Randomize button: Force a recook of the PCG graph with a different seed.
Clear all points: Delete all generated points ( roots and scattered ).
Size: The size ( radius ) of the brush. It will be used to scatter the points in it, as well as used to project them on the visible objects.
Samples count: The number of “rays” or “samples” to be processed in the brush radius when the use click and drag it. It doesn’t represent the real number of output points, but more a “density”.
Custom data: A simple integer value which can be set to any brush strokes. This is useful to drive the PCG graph behavior differently between brushes if needed.
Global samples mult. : A global multiplier applied on the whole PCG graph ( not per strokes ). Multiplies the number of samples used to create the scattered points.
Scatter points bounds: Set the scatter points ( around roots ) bounds size, used to remove overlapping point if needed ( the option can be turned on / off using the checkbox ), the setting is applied globally, not per strokes.
Debug options
Show root points:
Show scatter points:
Show roots radius:
PCG points to graphs
As said as the beginning, the tool works in steps, it generates the scattered points then executes a custom graph created by the user, with those points as inputs.
The core graph which will generate the root and scattered points is “PCG_PainterGraphPreparePoints”. It can be found in PCGPainter/PCGGraph folder.
Tn this graph, a node “Execute PCG graph processor” will execute the custom graph selected by the user.
An exampler of PCG graph processor is available in the “PCGPainterData” folder “PCG_PainterExample”
Few attributes are available to help you build the systems you need:
- __BrushCustomData (int)
- __BrushRadius (float)
- __PainterImpactNormal (vector)
- __BrushSampleCount (int)
- __RootPoint ( 0 or 1 )
- __RayCastLengh (float)
- ActorReference (SoftRef)
- PhysicalMaterial (SoftRef)
The tool only accept Graph instances, not regular graphs, you need to create a graph instance by right click on the graph => Create PCG graph instance.
Github depot:
https://github.com/cgtoolbox/PCGPainter
contact@cgtoolbox.com