Questions tagged [objloader]

75 questions
1
vote
2 answers

Transparent issue with model in threejs

I've been posting a lot on stackoverflow and other places trying to learn three js. This is my first project and using it as an experiment. I've successfully loaded an OBJ and MTL file. I have a problem where parts of the 3d model is transparent.…
0
votes
0 answers

TypeError: unhideTextInstance is not a function in react.js + three.js project

I was using Three.js in my React Project. I used OBJLoader to render 3D model in my web page, but when I refreshed the page, it occurred an error, which said "TypeError: unhideTextInstance is not a function". But sometimes it worked without…
0
votes
0 answers

showing black screen when rendering 3d model .obj file on webpage

I am trying to render 3d model .obj file on webpage using Three.js. I am not getting any error on console. But 3d model is not shown. I have tried previous related solutions but not worked for me.Like: Model not rendering on screen On rendering…
0
votes
0 answers

OBJLoader gives error when trying to load high poly models

I made a OBJFILELoader but when i try to load a high poly model it gives me a empty string error I Checked the file and it seems to be totally fine Im not really sure if the problem is with the code or with the model because it dosent work on any…
0
votes
0 answers

MTLLoader problem - object is black coloured

I'm having trouble loading textures. I've tried several ways but my object is still black. What am I doing wrong? const onProgress = function (xhr) { if (xhr.lengthComputable) { const percentComplete = (xhr.loaded / xhr.total) * 100; …
0
votes
0 answers

OBJ_Loader.h linking error when included in multiple files

I am using OBJ-Loader to load .obj. For my project, I need to include the OBJ_Loader.h in multiple files. It gives me the LNK2005 linking error on visual studio. It says something like "the object file is already defined". But if I include it twice…
Shuvo Sarker
  • 187
  • 9
0
votes
1 answer

THREE JS - how to impement the automatic 3d model scale

I have implemented a simple 3D model viewer with three.js. The project contains a database of 3D models, divided into different categories. In one category, the models are tall (with a relatively small width, the height is much higher than the…
Vitaly Vesyolko
  • 558
  • 5
  • 22
0
votes
1 answer

Can't load an obj file with three.js and ObjLoader2

I imported from cdn ObjLoader2(). I'm trying to load an obj file but on the console I get two errors: Access to XMLHttpRequest at 'myfilepath.obj' from origin 'null' has been blocked by CORS policy: Cross origin requests are only supported for…
Jack_Dev
  • 3
  • 3
0
votes
0 answers

can we support IBL for obj-mtl/FBX Loader for three js

ThreeJs obj-mtl/fbx loader uses default MeshPhongMaterial, which does not support IBL. To support IBL we had to change materials at the time of loading. Can we do changes in the library itself to use MeshStandardMaterial or MeshPhysicalMaterial for…
0
votes
1 answer

Dragging vertices from a imported .obj model

This might be a rookie mistake but im stuck with it for many hours, so i thought i would ask here. I´m new to three.js but looking through the forum i found some good examples of mesh editing and managing a imported model but after adapting my code…
0
votes
1 answer

Do I need the three.js.master folder to use OBJLoader2.js ? 404 not found

So i'm beginning to use three.js, trying to import a OBJ file using OBJLoader2.js locally (no npm). But when try to add import {OBJLoader2} from 'https://threejsfundamentals.org/threejs/resources/threejs/r115/examples/jsm/loaders/OBJLoader2.js'; It…
SpikeThea
  • 340
  • 1
  • 3
  • 13
0
votes
1 answer

How to show ThreeJs .obj file in botstrap responsive modal?

I have below code to show .obj file using OBJLoader. this.renderer = new THREE.WebGLRenderer({ canvas: this.canvasRef.nativeElement }); this.renderer.setSize( window.innerWidth, window.innerHeight ); // scene this.scene = new…
0
votes
1 answer

ThreeJs OBJLoader output looks very pixelated

I am trying to load .obj file through OBJLoader in angularjs. But the output is very pixelated. Tried changing camera position & perspective(codes are commented), then it results in very smaller output, i need to zoom in through mouse in that…
0
votes
0 answers

three.js - Colors won't appear when I'm trying to load an object

I'm having a problem with loading objects in three.js. As I said, colors won't appear and the object is black and white! Here is my code: Getting Started (I'm not really sure if this section works fine, so I put it here.) const width =…
Arshan
  • 1
  • 3
0
votes
1 answer

How to apply SVG texture on OBJ file in Three.js

I'm using Threejs for a project of mine, i render an Object file using OBJ loader and it displays the object on the screen. But I don't know how to map a SVG image to that object how to apply texture on that object file. please help me this is my…