Skip to main content
How are we doing? Please help us improve Stack Overflow. Take our short survey

Questions tagged [three.js]

Three.js is a lightweight cross-browser JavaScript library/API used to create and display animated 3D computer graphics on a Web browser. Three.js scripts may be used in conjunction with the HTML5 canvas element, SVG or WebGL.

0 votes
1 answer
21 views

When I apply the image to the canvas, it gets rotated and pasted on the mesh in the model

When I apply a texture uploaded using fabric canvas to the model, the texture gets rotated and applied. [intial model] (https://i.sstatic.net/4avgVUGL.png) after upload of picture and application ...
arjun lokesh's user avatar
0 votes
0 answers
22 views

Instanced geometry in react-three-fiber porting from three.js

I am porting a working code from three.js r167 to react-three-fiber. In three.js I have something like that const baseGeoemtry = new THREE.PlaneGeometry(1, 1, 1, 1); const geometry = new THREE....
lezan's user avatar
  • 779
0 votes
0 answers
9 views

Mapbox/Maplibre raycast with only a projection matrix and georeferenced objects

I guess this could be considered a continuation of this question so please check it out for context about his one, especially the JSFiddle reported in said question. I'm basically trying to achieve ...
QcFe's user avatar
  • 88
0 votes
0 answers
17 views

How to Convert GeoJSON Points and Polygons to 3D Objects using Three.js in JavaScript?

I am working on a project where I need to convert GeoJSON data into 3D objects using Three.js in JavaScript. My GeoJSON data contains two types of features: points and polygons. I want to render these ...
sphynx's user avatar
  • 1
1 vote
0 answers
49 views

How to fix 'Cannot find namespace 'THREE'' in vagran/dxf-viewer lib?

I am trying to use vagran/dxf-viewer with angular 16 project. I get error when launching project with ng serve command. All I did is just installed packages and added import to component. I was trying ...
Vadim Khismatov's user avatar
1 vote
1 answer
47 views

Three JS loop through materials

I want to search for the material called COIN and assign a new texture to it. I know it's material number 0, but what I want is to search through the materials and if it finds a name match, assign the ...
Nicoli's user avatar
  • 864
1 vote
1 answer
65 views

Placing object at mouse position has offset

I'm using ThreeJS with MindAR, and I'm trying to put an object in the place where I clicked with my mouse. const mousePositionX = (e.clientX / window.innerWidth) * 2 - 1; const mousePositionY = -(e....
Amir's user avatar
  • 135
0 votes
1 answer
31 views

Threejs cube is black and has no unexpected light

I see other people demo has light but my local 5173 cannot see the light on some sides for the MeshPhongMaterial. I tested light position , tested pointlight , tested ambientlight and still cannot ...
Raii's user avatar
  • 172
0 votes
0 answers
37 views

(R3F/React-three-fiber/Ecctrl) gltfpack with gltfjsx - my packed .glb model is not loading

code sandbox link here I'm using ecctrl and react-three-fiber. My character model isn't loading and I don't know how to debug it? Any ideas? I used something like `gltfpack -i ./inputfile.glb -o ./...
George's user avatar
  • 2,412
-3 votes
0 answers
22 views

Code sample: make only one point cloud render

I came across a threejs code here. When I run the program, I see 2 point clouds rendered. I dont understand what part of code makes that happen this. I see attribute 'offset' being used: ...
Mandroid's user avatar
  • 7,096
1 vote
1 answer
29 views

TypeError: THREE.BufferAttribute: array should be a Typed Array

I am trying to create a point cloud in threejs as: const pcGeom = new THREE.BufferGeometry(); const rows = 100; const columns = 3; const vertices = [...Array(rows)].map(() => [...Array(columns)]....
Mandroid's user avatar
  • 7,096
-2 votes
1 answer
71 views

Is it possible to create 3D Building Configurator with Autodesk APS ? or Three.js is better?

I am a Three.js developer. I know 'thatopencompany' recently for ifc files (BIM) too. We want to create a website like https://planner5d.com/. I need some data of .ifc files like space, floors, lamp ...
Parisa Shahbazi's user avatar
0 votes
1 answer
53 views

Applying Two Different Textures with Two Different Materials on the Same Mesh in Three.js/blender

I am working on a project where the user can cusotmise his/her shoes. I want them to color the individual parts which is easy to build (each part of the shoe is its own mesh). 1,2 and 3 are separate ...
arjun lokesh's user avatar
0 votes
1 answer
65 views

How to make the camera to follow the model from a third-person perspective

I’m working on a Three.js project where I need a third-person camera setup that follows a 3D model as it moves around the scene. I have a basic implementation with animations and controls, but I’m ...
Wildy Simanjuntak's user avatar
0 votes
0 answers
57 views

Flow Map generator for water effect in three.js

I am developing a project on three.js. I need to realize the effect of water flow; for this, I want to use Flow Map. Can you please tell me what generators are used to create such maps so that I can ...
ssebira's user avatar
  • 11

15 30 50 per page
1
2 3 4 5
1412