Skip to content

Node reference ​

This page is generated from the node library (cargo run -p kvas_engine --example gen_node_docs). Nodes in total: 215.

The letters show where a node can be used: M - material (.kmat), S - object shader (.kshader), E - camera effect (.kfx).

Parameters are shown as name (min..max). The descriptions are the tooltips of the editor (some older nodes only have Russian or no text yet).

Input ​

Constants, textures, time, UV.

NodeWhereInputsParametersDescription
ColorMSE-colourA constant colour.
ValueMSE-value (-100..100)A constant number.
TextureMSUVslot (0..2), tiling (0.01..100)Samples one of the material images (slot 0 albedo, 1 normal, 2 ORM).
TimeMSE--Seconds since the game started.
Object colourMS--The colour set in the MeshRenderer of the object.
Triplanar textureMS-slot (0..2), scale (0.01..50), sharpness (1..32)Projects a material image from three world axes, no stretching on any slope.
Image textureMSVectorslot (0..2), tiling x (0.01..100), tiling y (0.01..100), offset x (-10..10), offset y (-10..10), rotation (-1..1)An image file of the project. Pick it in the node; up to three images per material (slots 0..2). Outputs colour, channels and brightness.
RGBMSEColour-A colour with R, G, B and brightness outputs.

Geometry ​

Position, normal, height, direction masks, vertex offsets.

NodeWhereInputsParametersDescription
UVMSE--Texture coordinates of the surface (0..1).
World positionMS--Position of the pixel in the world.
NormalMS--Direction the surface faces.
HeightMS--World height (Y) of the pixel.
Slope maskMS-from (0..1), to (0..1)1 on flat ground, 0 on steep slopes (between the two thresholds).
Camera distanceMS-range (1..1000)0 at the camera, 1 at the chosen range (fog, level of detail).
View directionMS--Unit vector from the surface to the camera.
ReflectionMS--The view direction mirrored by the surface normal.
Camera positionMS--World position of the camera.
Object positionMS--World position of the object's origin.
Object randomMS--A random number that is different for every object but constant over time.
Screen positionMS--Pixel position on the screen (0..1).
Direction maskMS-x (-1..1), y (-1..1), z (-1..1), threshold (-1..1), softness (0.001..2)White where the surface faces the chosen direction (x, y, z). Top = (0,1,0).
Surface sidesMS--Red = top faces, green = side faces, blue = bottom faces. Split with Red / Green / Blue nodes.
Triplanar weightsMS-sharpness (1..32)How strongly each world axis projection (X, Y, Z) applies on this surface.
Local positionMS--Position relative to the object's origin.
Object distanceMS-range (0.1..500)0 at the object's centre, 1 at the chosen range.
World gradientMS-x (-1..1), y (-1..1), z (-1..1), from (-1000..1000), to (-1000..1000)A 0..1 ramp along a world direction between two values (fog by height, snow line).
Planar UVMS-axis (0..2), scale (0.01..100)Texture coordinates projected from world space along an axis.
Normal UVMS--Spherical coordinates from the normal (for sky-like mapping).
Wave offsetMS-height (0..5), frequency (0..30), speed (-10..10)Vertex offset for waves. Connect to Shader output > Vertex offset.
Wind swayMS-strength (0..3), speed (0..20), scale (0..10)Vertex offset that bends things in the wind, more at the top. Connect to Vertex offset.
Texture coordinateMS--Every coordinate system at once: UV, object, world, normal, reflection and screen.
Geometry infoMS--Position, normal, view direction, height, back side and slope of the surface point.

Light ​

Sun, shadows, highlights, rim light, glow (Emission).

NodeWhereInputsParametersDescription
FresnelMSPower-Brighter at grazing angles (rim light, glass, water edges).
Sun lightMS--How much the surface faces the sun (0..1), without shadows.
Sky reflectionMS--What the sky looks like in the mirror direction.
Sun directionMS--Unit vector pointing to the sun.
Sun colourMS--Colour and strength of the sun.
Ambient lightMS--Constant ambient light colour of the scene.
ShadowMS--1 in light, 0 in the sun shadow.
LightingMSBaseroughness (0..1)Applies scene lighting (sun, shadows, lamps) to a colour.
Light angleMS--Dot product of the normal and the sun direction: 1 facing the sun, -1 facing away.
Half lambertMS-power (0.1..4)Soft wrap-around sun lighting (0..1) without a hard dark side.
Specular highlightMS-shininess (1..512), intensity (0..10)Blinn-Phong glint of the sun. Higher shininess = smaller, sharper spot.
Rim lightMS-colour, power (0.1..12), intensity (0..20)A coloured glow on the edges that face away from the camera. Plug into Emission.
BacklightMS-sharpness (1..64)Bright when the camera looks towards the sun through the surface (leaves, cloth, ice).
Facing ratioMS--1 where the surface faces the camera, 0 on silhouettes.
Sun with shadowMS--Sun lighting amount (0..1) that respects shadows.
Sun lightingMS--Sun colour times the lighting amount, with shadows. Add Sky light for a full diffuse term.
Sky lightMS--Ambient light from the sky in the direction of the normal.
GlowMSE-colour, intensity (0..50)A constant colour multiplied by an intensity. Plug into Emission to make things shine.
Pulsing glowMSE-colour, intensity (0..50), speed (0..20)A glow that pulses over time.
Layer weightMSBlend-Fresnel and facing masks with a blend control; good for coatings and rims.

Normals ​

Normal maps, bump from height, normal blending.

NodeWhereInputsParametersDescription
Normal mapMSMap, UVstrength (0..4)Turns a normal-map colour into a surface direction. Connect the result to Output > Normal.
Bump from heightMSHeightstrength (0..10)Makes bumps from a height value. Connect the result to Output > Normal.
Normal strengthMSNormalstrength (0..4)Blends between the surface normal and the connected normal.
Normal blendMSBase, Detail-Adds a detail normal on top of a base normal.
Normal to colourMSNormal-Shows a normal as a colour (for previews and debugging).
Noise bumpMSCoordsscale (0.05..100), strength (0..10)Bumps the surface with fractal noise. Connect to Output > Normal.
Height to normalMSUVslot (0..2), tiling (0.01..100), strength (0..32)Makes a normal-map colour from the height in a texture slot. Feed it to Normal map.
BumpMSHeight, Strength, Distanceinvert (0..1)Surface relief from a height value; connect to Output > Normal.

Noise ​

Fractal, Perlin, Voronoi, cracks, clouds, grunge. They show a preview by default.

NodeWhereInputsParametersDescription
NoiseMSECoordsscale (0.01..100)Simple smooth value noise (2D, uses the X and Z of the coordinates).
VoronoiMSECoordsscale (0.01..100)Cell pattern: distance to the nearest random point.
Cell colourMSECoordsscale (0.01..100)A random colour per Voronoi cell.
Noise 3DMSCoordsscale (0.01..100)Smooth 3D noise that does not stretch on any surface.
Ridged noiseMSCoordsscale (0.01..100)Noise with sharp ridges (mountains, veins).
TurbulenceMSCoordsscale (0.01..100)Billowy noise with creases (smoke, fire).
White noiseMSECoordscells (1..1000)A random grey value per cell, no smoothing (TV static).
SparkleMSECoordscells (4..1000), density (0..1)Rare bright dots (stars, glitter).
Fractal noiseMSECoordsscale (0.01..100), octaves (1..8), lacunarity (1.2..4), gain (0.1..0.9), type (0..2)Layered noise with control over octaves, lacunarity and gain. Types: fBm, ridged, billow.
Perlin noiseMSECoordsscale (0.01..100)Smooth gradient noise (0..1).
Voronoi cellsMSECoordsscale (0.01..100), randomness (0..1), output (0..3)3D cell noise. Outputs: distance, cell edges, random id per cell, second distance.
CracksMSECoordsscale (0.01..100), width (0.005..0.5)Thin cracks along cell borders (dry ground, ice, shattered stone).
Warped noiseMSECoordsscale (0.01..100), warp (0..8)Noise bent by other noise - swirly, organic shapes.
CloudsMSECoordsscale (0.01..100), coverage (0..1), softness (0.01..1)Soft cloud-like blobs. Coverage sets how much is filled.
GrungeMSECoordsscale (0.01..100), contrast (0.1..8)Dirt and wear mask. Multiply with a base colour or use for roughness.
ScratchesMSECoordsdensity (2..400), angle (-3.15..3.15)Thin stretched scratches at an angle.
Noise textureMSEVector, Scale, Detail, Roughness, Distortiontype (0..2), lacunarity (1.2..4)Fractal noise with scale, detail, roughness and distortion inputs; outputs a factor and a colour.
Voronoi textureMSEVector, Scale, Randomnessfeature (0..3)Cells: distance, edges, a value and a colour per cell.

Patterns ​

Checker, bricks, hexagons, planks, weave, gradients and shapes.

NodeWhereInputsParametersDescription
CheckerMSECoordsscale (1..200)A black and white checkerboard.
StripesMSECoordsscale (1..200), sharpness (0..1)Parallel stripes along X.
BricksMSECoordsscale (1..100), mortar (0..0.3)A brick wall pattern with mortar lines.
DotsMSECoordsscale (1..200), size (0.01..0.5)A grid of round dots.
CausticsMSCoordsscale (0.05..50), speed (0..10)Moving light patterns like under water.
HexagonsMSECoordsscale (0.5..100), edge width (0..0.5)Honeycomb pattern edges.
Wave ringsMSECoordsfrequency (1..200), speed (-20..20)Animated rings spreading from the centre.
Linear gradientMSECoords-0..1 from left to right (X of the coordinates).
Radial gradientMSECoords-1 in the centre, 0 at the edge.
Angular gradientMSECoords-0..1 around the centre like a clock hand.
CircleMSECoordsradius (0..1), softness (0..0.5)A soft disc.
BoxMSECoordswidth (0..1), height (0..1), softness (0..0.5)A soft rectangle.
Wood ringsMSCoordsscale (0.1..50), wobble (0..2)Tree-ring pattern for wood.
Marble veinsMSCoordsscale (0.05..20), warp (0..20)Wavy veins for marble.
Grid linesMSECoordscells (1..200), line width (0.001..0.5)A grid of thin lines (white lines on black).
PlanksMSECoordsrows (1..100), plank length (0.2..40), gap (0..0.3)Wooden floor boards with random tones and gaps.
WeaveMSECoordsthreads (1..200)Over-under fabric weave pattern.
Wave textureMSEVector, Scale, Distortion, Detailtype (0..1), profile (0..2)Bands or rings with sine, saw or triangle profile, bent by noise.
Gradient textureMSEVectortype (0..6)Linear, quadratic, eased, diagonal, radial or spherical gradient.
Brick textureMSEVector, Colour 1, Colour 2, Mortar, Scalebrick ratio (0.2..6), row offset (0..1), mortar size (0..0.3), mortar smooth (0..0.3), colour variation (0..1)Bricks with two colours, mortar, row offset and a value per brick.

Colour ​

Color ramp, blend modes, HSV, colour correction.

NodeWhereInputsParametersDescription
Hue shiftMSEColourturns (-1..1)Rotates the colours around the colour wheel.
SaturationMSEColouramount (0..3)0 = grey, 1 = unchanged, above 1 = more vivid.
ContrastMSEColouramount (0..3)Pushes values away from mid grey.
BrightnessMSEColourscale (0..10)Multiplies the colour.
GradientMSEPosition, From, To-Blends two colours by a 0..1 position.
To greyMSEColour-Converts a colour to its brightness.
OverlayMSEBase, Blend-Overlay blend: multiplies darks and screens lights.
Screen blendMSEBase, Blend-Screen blend: always lightens.
ColourizeMSEValue, Tint-Tints the brightness of a colour with another colour.
Ramp 3 coloursMSEPosition, Low, Middle, High-Maps 0..1 to a three-colour gradient.
GammaMSEColourgamma (0.1..5)Gamma correction.
ExposureMSEColourstops (-8..8)Brightens or darkens by photographic stops.
LevelsMSEColourblack (0..1), white (0..2)Sets the black and white points.
ThresholdMSEColourlevel (0..1)Black and white by a brightness threshold.
Tone mapMSEColour-Filmic (ACES) tone mapping of HDR colour.
Color rampMSEPosition, Stop 1, Stop 2, Stop 3, Stop 4position 1 (0..1), position 2 (0..1), position 3 (0..1), position 4 (0..1), interpolation (0..2)Maps 0..1 to a gradient of four colour stops placed at four positions.
Blend coloursMSEA, B, Factormode (0..12)Photoshop-style blend modes: 0 mix, 1 multiply, 2 screen, 3 overlay, 4 add, 5 subtract, 6 difference, 7 darken, 8 lighten, 9 soft light, 10 dodge, 11 burn, 12 hard light.
HSV adjustMSEColourhue shift (-0.5..0.5), saturation (0..3), value (0..3)Shifts hue and scales saturation and brightness.
HSV to RGBMSEHue, Saturation, Value-Builds a colour from hue, saturation and value.
RGB to HSVMSEColour-Splits a colour into hue (red), saturation (green), value (blue).
Lift gamma gainMSEColourlift (-0.5..0.5), gamma (0.1..4), gain (0..4)Classic three-way colour correction.
Colour temperatureMSEColourwarmth (-1..1)Warm (orange) or cool (blue) tint.
Colour keyMSEColourcolour, tolerance (0..1.75), softness (0..1)White where the colour is close to the key colour.
S-curveMSEValueamount (0.05..0.95)Contrast curve that keeps black and white fixed.
Bias curveMSEValuebias (0.01..0.99)Bends mid-tones towards dark or light.
Mix colourMSEFactor, A, Bblend mode (0..12), clamp result (0..1)Blends A and B with a mode (mix, multiply, overlay, screen...) by a factor.
Hue saturation valueMSEColour, Hue, Saturation, Value, Factor-Shifts hue and scales saturation and brightness.
InvertMSEColour, Factor-Inverts a colour by a factor.
RGB curvesMSEColour, Factory at 0 (-1..2), y at 0.25 (-1..2), y at 0.5 (-1..2), y at 0.75 (-1..2), y at 1 (-1..2)Tone curve for colours through five points.
Bright contrastMSEColour, Bright, Contrast-Brightness and contrast as inputs.

Math ​

Arithmetic, curves, comparisons, transitions.

NodeWhereInputsParametersDescription
AddMSEA, B-A + B.
SubtractMSEA, B-A - B.
MultiplyMSEA, B-A * B (tinting, masking).
DivideMSEA, B-A / B (safe: never divides by zero).
MixMSEA, B, Factor-Blends A and B by Factor (0 = A, 1 = B).
PowerMSEValue, Exponent-Raises to a power (curves, sharpening masks).
ClampMSEValuemin (-100..100), max (-100..100)Limits a value to a range.
One minusMSEValue-1 - value (inverts a mask).
SineMSEValuefrequency (0..100)A sine wave remapped to 0..1.
SmoothstepMSEValueedge 0 (-10..10), edge 1 (-10..10)Smooth 0..1 transition between two edges.
AbsMSEValue-Absolute value.
MinMSEA, B-The smaller of two values.
MaxMSEA, B-The larger of two values.
FractMSEValue-The fractional part (repeats 0..1).
StepMSEValueedge (0..1)0 below the edge, 1 above it.
RemapMSEValuein min (-10..10), in max (-10..10), out min (-10..10), out max (-10..10)Maps a range to another range (not clamped).
NegateMSEValue-Changes the sign.
Square rootMSEValue-Square root.
FloorMSEValue-Rounds down.
CeilMSEValue-Rounds up.
RoundMSEValue-Rounds to the nearest whole number.
SignMSEValue--1, 0 or 1.
SaturateMSEValue-Clamps to 0..1.
ModuloMSEA, B-The remainder of A / B (repeating).
Multiply addMSEA, B, C-A * B + C in one node.
CosineMSEValuefrequency (0..100)A cosine wave remapped to 0..1.
Triangle waveMSEValuefrequency (0..100)A zig-zag wave 0..1..0.
SawtoothMSEValuefrequency (0..100)A ramp that jumps back to 0.
Square waveMSEValuefrequency (0..100)Alternates between 0 and 1.
PosterizeMSEValuesteps (2..64)Reduces the number of distinct levels.
Greater thanMSEA, B-1 where A > B, otherwise 0.
BranchMSEA, B, If A > B, Otherwise-If A > B returns the third input, otherwise the fourth.
Height blendMSEHeight A, Height B, Blendsharpness (0.001..2)A blend mask where the higher of two heights wins (rock through snow, moss in cracks).
ExponentialMSEValue-e raised to the value.
LogarithmMSEValue-Natural logarithm.
ReciprocalMSEValue-1 divided by the value.
Inverse lerpMSEValuefrom (-100..100), to (-100..100)Where the value lies between from and to (0..1 inside).
Map rangeMSEValuein min (-100..100), in max (-100..100), out min (-100..100), out max (-100..100)Remaps a range to another and clamps the result.
SnapMSEValuestep (0.0001..100)Rounds to the nearest multiple of the step.
Arc tangent 2MSEY, X-Angle of the point (X, Y) in radians.
SmootherstepMSEValueedge 0 (-10..10), edge 1 (-10..10)A smoother version of Smoothstep.
Less thanMSEA, B-1 where A < B, otherwise 0.
AverageMSEA, B-Mean of two values.
MathMSEA, B, Coperation (0..25), clamp (0..1)One node for 26 operations on numbers (add, power, smooth min, snap, ping-pong...). Pick the operation in the list.
Float curveMSEValuey at 0 (-1..2), y at 0.25 (-1..2), y at 0.5 (-1..2), y at 0.75 (-1..2), y at 1 (-1..2)Reshapes a value by a smooth curve through five points.
Clamp rangeMSEValue, Min, Max-Keeps a value between two inputs.

Vectors ​

Components, dot and cross products, rotations, coordinates.

NodeWhereInputsParametersDescription
RedMSEVector-Copies the red channel to all channels.
GreenMSEVector-Copies the green channel to all channels.
BlueMSEVector-Copies the blue channel to all channels.
CombineMSER, G, B-Builds a vector from the red channels of three inputs.
LengthMSEVector-Length of a vector.
DistanceMSEA, B-Distance between two points.
DotMSEA, B-Dot product (how much two directions agree).
CrossMSEA, B-Cross product (a direction perpendicular to both).
NormalizeMSEVector-Scales a vector to length 1.
ReflectMSEIncident, Normal-Mirrors a direction around a normal.
Rotate coordsMSECoordsangle (-6.3..6.3)Rotates texture coordinates around the centre.
Scale offset coordsMSECoordsscale x (0.01..100), scale y (0.01..100), offset x (-100..100), offset y (-100..100)Tiles and shifts texture coordinates.
Scroll coordsMSECoordsspeed x (-10..10), speed y (-10..10)Moves coordinates over time (flowing water, conveyor belts).
Polar coordsMSECoords-Converts coordinates to angle and radius.
Mirror tileMSECoordstiles (0.1..50)Repeats coordinates mirrored, so the seams disappear.
FlipbookMSECoordscolumns (1..32), rows (1..32), frames per second (0..60)Plays a grid of frames (sprite sheet) as animation.
Distort coordsMSECoords, Amountscale (0.1..100)Wobbles coordinates with noise (heat haze, water).
Rotate around axisMSEVector, Axisangle (-6.3..6.3)Rotates a vector around an axis by an angle (radians).
RefractMSEIncident, Normalindex ratio (0.1..2)Bends a direction through a surface (glass, water).
Twirl coordsMSECoordsamount (-20..20)Swirls coordinates around the centre.
Vector mathMSEA, Boperation (0..16)Operations on vectors: cross, dot, project, reflect, distance, normalize...
Separate RGBMSEColour-Splits a colour into R, G and B.
Separate XYZMSEVector-Splits a vector into X, Y and Z.
Combine XYZMSEX, Y, Z-Builds a vector from three numbers.
MappingMSEVectorlocation x (-100..100), location y (-100..100), location z (-100..100), rotation (-1..1), scale x (-100..100), scale y (-100..100), scale z (-100..100)Moves, turns and scales texture coordinates.
Jitter coordsMSEVector, Amountscale (0.01..100)Adds smooth noise to coordinates to break visible repetition.

Utility ​

Reroute, comments, number from the Inspector.

NodeWhereInputsParametersDescription
RerouteMSEValue-A tiny pass-through point to tidy long links.
CommentMSE--A frame with a note. Nodes inside it move with it.
Inspector numberMSE-slot 0-7 (0..7), default (-1000..1000), zero uses default (0..1)A number you can change per object in the Inspector (MeshRenderer user 1..8) or from a script.
Time scaledMSE-speed (-50..50)Time multiplied by a speed.
PulseMSE-hertz (0..20)A smooth 0..1 wave over time.

Camera ​

Only in camera effect graphs (.kfx).

NodeWhereInputsParametersDescription
Screen colorECoords-Colour of the camera image at the given coordinates (blur, distortion).
Pixel colourE--The current pixel of the camera image.
Pixel sizeE--Size of one screen pixel in 0..1 units.
Aspect ratioE--Screen width divided by height.
BlurECoordsradius px (0..30)Cheap 5-tap blur of the camera image.
Chromatic splitECoordsamount px (0..30)Shifts the red and blue channels apart.
Edge detectECoordsstrength (0..20)White where the picture changes sharply.
PixelateECoordscells across (8..1000)Blocky retro look.
VignetteECoordsstrength (0..2)Darkens the screen edges.
ScanlinesECoordslines (10..2000)CRT-like horizontal lines.

Output nodes ​

GraphNodeInputs
MaterialOutputBase color, Roughness, Metallic, Emission, Alpha, Occlusion, Normal, Height
Object shaderShader outputColor, Alpha, Emission, Light amount, Roughness, Vertex offset
Camera effectEffect outputColor

Kvas Engine