Blending object colors into a texture map

calendar_today

24.12.2022

label

Texturing

mouse

Houdini 18.0

1 Code discussion

A volumewrangle finds nearby points with pcopen(), blends their colors using pcfilter() and assigns them to a UV map.

int samples = chi('samples');
float radius = chf('radius');

vector tex = relbbox(0, v@P);
vector pos = uvsample(1, 'P', 'uv', tex);

int handle = pcopen(2, 'P', pos, radius, samples);
vector color = pcfilter(handle, 'Cd');
v@Cd = color;
download

Downloads