Back to the Shapespark home page

I want to prevent the floor material from repeating

I am making a floor material picker.
If you change the floor material with the material picker, the floor pattern will change.
It will be repeated. I want to prevent the floor material from repeating.
The program is based on the following program.

var viewer = WALK.getViewer();

var brickMaterial = viewer.findMaterial(‘brick’);
var nodes = viewer.findNodesOfType(‘wall’);
for (var i = 0; i < nodes.length; ++i) {
viewer.setMaterialForMesh(brickMaterial, nodes[i].mesh);

The goemetry uvs determine if a texture will repeat. If the original ‘wall’ geometry has uvs that repeat the texture, the new brick material will be also repeated. The uvs need to be changed in a 3d modeling program that you use, Shapespark doesn’t have such function.

Thank you for answering