I want to add custom ground material on my website using Meshphongmaterial

40 Views Asked by At

    var groundMaterial = new THREE.MeshPhongMaterial( { color: 0xff43fee, specular: 0x360000 ,} );
    groundMesh = new THREE.Mesh( new THREE.PlaneBufferGeometry( 2000, 2000 ), groundMaterial );
    groundMesh.rotation.x = - Math.PI / 2;
    scene.add( groundMesh );
    

I want to add grass texture down but not getting any possible solution this code is taken from https://github.com/schteppe/gpu-physics.js this following github repo.

1

There are 1 best solutions below

2
On

You need to create a Texture and send it as map property in the MechPhongMaterial constructor