Hi everyone, thank you in advance for any assistance you can give. I have a question about the Depthkit.js plugin. I’m new to the community so please excuse me if I miss any best practices in this post.
I am using the DepthKit.js plugin, with Three.js. I have created a character (3D object) using the DepthKit class as explained on the npm page: depthkit - npm
character = new DepthKit( ‘points’, ‘…/assets/dale/TAKE_02.txt’, ‘…/assets/dale/TAKE_02.mp4’ ); character.depthkit.setPointSize(30);
Then called the setPointSize method on that object but it does not work.
The above code works when setting the first argument as “mesh” or “wire” but not “points.”
I have been looking at the depthkit.js file and from what I can tell it should work. That said I am new developer and python is my main language, I am learning javascript on the fly, so it’s highly likely I have missed something obvious.
To test this I added the console.log(size) to the function on line 240 in the DepthKit.js file:
value: function setPointSize(size) {
if (this.material.uniforms.isPoints.value) {
this.material.uniforms.pointSize.value = size;
console.log(size);
}
else {
console.warn(‘Can not set point size because the current character is not set to render points’); }
That printed the value 30 (see image) that I had passed to the depthkit method but appears to have no effect.
I’d be grateful for any guidance. I’m wondering if anyone else has had this issue?