Questions tagged [threejs-editor]
80 questions
3
votes
1 answer
Not able to remove EventListener in Typescript
I am trying to remove an eventlistener in typescript. I am adding eventlisteners in an if-statement. In the else-statement I am trying to remove these eventlisteners, but for some reason it does not remove them.
FYI: I have a button where I set a…

Russix
- 33
- 4
3
votes
1 answer
ThreeJS: Subtract object B from object A
I have an object A. Object A is a 3D object (a scan of a cavity).
I have an object B. Object B is a simple plane. It passes though the centre of Object A.
I would like to split Object A into two separate objects using the plane. Is there a way to…

Mubashir Ali
- 349
- 1
- 10
3
votes
1 answer
Moving an object by changing its position in useFrame does not work
I have a code as below. Although I update the sphere position with every frame (useFrame), it does not reflect on my scene. Can someone please help me understand why it will not work.
PS : I am new to this and am trying to do some quick proof of…

stm
- 33
- 6
2
votes
1 answer
Equation of line from center of camera to plane in ThreeJS
I am working on a fork of threeJS editor and for a particular functionality, I need to get the world point where the center of camera is pointing at.
I believe that if I am able to get the equation of line from center of camera in the direction it's…

Muhammad Ijlal
- 21
- 3
2
votes
1 answer
Using useHitTest ("@react-three/xr": "^5.0.1") with the newer version of XR
I've seen a few examples of using useHitTest with versions of @react-three/xr lower than v5, but I'm not quite sure how to convert the syntax using the newer versions.. (and using useRef with Typescript, which might be a separate issue).
Here is an…

timhc22
- 7,213
- 8
- 48
- 66
2
votes
0 answers
Can I embed RSS feed within a json file
What I am asking is similar to Can I serve RSS in JSON? but I am not sure he is trying to achieve the same thing as me. I want to create a globe news app where a user can hover over different countries on a 3D globe and they can see the top news…

shange
- 77
- 7
2
votes
0 answers
GLTF is supposed to load but never shows up in chrome
I am new at threejs so please have patience thank you.
I have loaded this gltf file into my entire code which renders a 3D earth. I am trying to load this 3D model of a spacecraft onto that same page.
Aqua13();
function Aqua13 () {
new…

orengetangerine
- 21
- 1
2
votes
0 answers
How to render multiple skinned meshes in single draw calls? (Three Js)
I am using same model with skeleton animation multiple times in my scene and generally when you use multiple meshes with same geometry and material, you use instancedMesh in three js to reduce the draw calls but it's not possible to do with skinned…

Bhushan Wagh
- 56
- 6
1
vote
0 answers
multiDrawElementsInstancedWEBGL / select geometry to render using LOD
I'm looking for answer regarding the multiDrawElementsInstancedWEBGL api on the web, I'm hitting a wall on something and this is quite frustrating, and really afraid this could confirm my darkest fear haha
I did some experiments in implementing…

Samsy
- 365
- 1
- 2
- 12
1
vote
0 answers
How to display DecalGeometry from ThreeJs on Specific Mesh
I have this Mesh:
The specific mesh named OCounter
and I want to display the Decal on the front of the mesh.
I tried this:
textureDecal.side = THREE.DoubleSide
const euler = new THREE.Euler(0,0,0, "XYZ");
const decalImage = new…

Crapaud
- 9
- 1
1
vote
1 answer
Threejs 3D model implementation on Drupal
I am completely new to Drupal and Three.js, and I need help with implementing a Three.js 3D model in my Drupal website. I have created the 3D model using a 3D modeling software and exported it as a .glb or .gltf file format, which is compatible with…

Mike
- 11
- 2
1
vote
0 answers
Crack line in GLTF from texturing image
GLTF image
After UV unwrapping and texture painting the object looks fine but I am seeing a crack line If I see it from the certain angles or when I zoom it out. Looks fine when zoomed in.
I tried multiple UV unwrapping option but it didn’t…

Simranjit Kaur
- 11
- 2
1
vote
1 answer
Three JS adjust texture on GLTF model to show entire texture
When applying a texture to a flat GLTF model (Floor) I only get a single colour from the texture rather than the desired yellow & black stripe effect. Any help is much appreciated!
Could it be a UV map is required or an adjustment to the actual…

StMartin
- 89
- 7
1
vote
0 answers
Incorrect bone positions in Object3D after conversion to json
I want to export my scene (there is only one 3D humanoid object in the scene) and convert it to .json format. After that, I import that .json into threejs-editor. The result is that my model doesn't look right. As I understand it - all the bones are…

shikitos
- 92
- 5
1
vote
0 answers
in ThreeJs's instancedMesh, is there any way to add/remove instance?
I'm considering this problem for several days. still, I have no a beautiful answer.
How can i delete an instance between 0 and the limit? Someone recommended using updateRange. but, i still need move numbers' indices in the matrix.
That moving the…

Singhi John
- 307
- 2
- 10