objloader

Three.js -> FileLoader(scope.manager) not constructor

ε祈祈猫儿з 提交于 2020-01-02 07:19:11
问题 This might seems as a duplicated question, since it is very similar to this one or many others, but none of the posts I have seen really helped me to figure out where the problem is ( sure, it's me ;) ...), hence I dare to post it here, since it makes me going really crazy. Well, I am working on a project in Angular2 generated with Angular CLI (no backend task or any trafficking, just HTML + CSS + JS files at the moment ... all up to date and latest). I have imported Three.js and three-obj

Error in OBJFileLoader

ぐ巨炮叔叔 提交于 2019-12-11 17:32:03
问题 There's error in OBJFILELOADER.py file from the link - https://www.pygame.org/wiki/OBJFileLoader . I think there's python2 to python3 version error, however I tried changing the raise ValueError thing and used obj as obj=(filename) But still there's lots of errors. I took the .obj file from blender, I don't think that's the issue. Can anyone tell me the exact objfileloader for Python3 Error - Traceback (most recent call last): File "/home/warted/anaconda3/lib/python3.6/site-packages/OpenGL

Uncaught TypeError: THREE.MTLLoader is not a constructor 2.0

雨燕双飞 提交于 2019-12-08 02:56:32
问题 I earlier asked this question in here: Uncaught TypeError: THREE.MTLLoader is not a constructor Where I got it to work by changing the three-mtl-loader file. But as I am going to upload my work to github later, I have to create a solution without changing these files. I am therefore instead trying to load in the obj and mtl files using the loaders used in the classic example: https://github.com/mrdoob/three.js/blob/master/examples/webgl_loader_obj_mtl.html But I still get the error 'Uncaught

Uncaught TypeError: THREE.MTLLoader is not a constructor 2.0

自闭症网瘾萝莉.ら 提交于 2019-12-06 11:28:15
I earlier asked this question in here: Uncaught TypeError: THREE.MTLLoader is not a constructor Where I got it to work by changing the three-mtl-loader file. But as I am going to upload my work to github later, I have to create a solution without changing these files. I am therefore instead trying to load in the obj and mtl files using the loaders used in the classic example: https://github.com/mrdoob/three.js/blob/master/examples/webgl_loader_obj_mtl.html But I still get the error 'Uncaught TypeError: THREE.MTLLoader is not a constructor' I am a bit unsure about how I would load in these

Three.js -> FileLoader(scope.manager) not constructor

牧云@^-^@ 提交于 2019-12-06 02:30:51
This might seems as a duplicated question, since it is very similar to this one or many others, but none of the posts I have seen really helped me to figure out where the problem is ( sure, it's me ;) ...), hence I dare to post it here, since it makes me going really crazy. Well, I am working on a project in Angular2 generated with Angular CLI (no backend task or any trafficking, just HTML + CSS + JS files at the moment ... all up to date and latest). I have imported Three.js and three-obj-loader through npm and declared it in my component like this: import * as THREE from 'three'; declare var

OBJFILELOADER - pygame

家住魔仙堡 提交于 2019-12-03 00:49:56
问题 So I tried running the code but it gives list out of index range error. I changed the index from 1 to 0, but the screen only pops up black. How could I change the code to make it work? 回答1: You just have to pass the filename/path of the .obj file to the OBJ class: obj = OBJ('suzzane.obj') Also, the script was written in Python 2 and if you want to use it with Python 3, you have to update a few things. Change this line, raise ValueError, "mtl file doesn't start with newmtl stmt" to: raise

OBJFILELOADER - pygame

◇◆丶佛笑我妖孽 提交于 2019-12-02 14:23:14
So I tried running the code but it gives list out of index range error. I changed the index from 1 to 0, but the screen only pops up black. How could I change the code to make it work? You just have to pass the filename/path of the .obj file to the OBJ class: obj = OBJ('suzzane.obj') Also, the script was written in Python 2 and if you want to use it with Python 3, you have to update a few things. Change this line, raise ValueError, "mtl file doesn't start with newmtl stmt" to: raise ValueError("mtl file doesn't start with newmtl stmt") And all the map iterators have to be turned into lists:

three.js OBJLoader not loading in react

戏子无情 提交于 2019-11-30 20:16:23
I am trying to load an object (.obj) file to use with three.js and react (with react-three-renderer), yet get an My code looks like: import React from 'react'; import ReactDOM from 'react-dom'; import React3 from 'react-three-renderer'; import TrackballControls from './TrackballControls'; import * as THREE from 'three'; import * as OBJLoader from 'three-obj-loader'; OBJLoader(THREE); class MyClass extends React.Component { ... render() { ... const objLoader = new THREE.OBJLoader(); } } However, I keep on getting: "export 'OBJLoader' (imported as 'THREE') was not found in 'three' Anyone with an