.obj

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

Add color to .obj in ThreeJS

99封情书 提交于 2020-01-01 16:52:10
问题 I am new to ThreeJS and have a simple question. I have the following code that will work properly, but I cannot add color to my .obj. The short and narrow of it is that I designed a game controller in Solidworks 2012, then I exported the CAD file as a .stl. I then used MeshLab to export the .stl as a .obj. Now I use the .obj in ThreeJS and it works, but I cannot for the life of me get color added to the .obj. Here is the code <!DOCTYPE html> <html lang="en"> <head> <title>three.js webgl -

A-Frame .obj model displaying but broken

痞子三分冷 提交于 2019-12-31 05:36:16
问题 Total beginner to a-frame here, have been through the tutorial scenes and am now setting up my first using .obj models. Using a remote server, feel like that's important information. I've seen questions about models not showing up but mine is displaying broken and I'm not sure where to start fixing it. This is how it looks in windows 3D builder: And this is how it looks in my project (backed on pink plane for contrast): Here's the html: <!DOCTYPE html> <html> <head> <meta charset="utf-8">

How to setup/calculate texturebuffer in glTexCoordPointer when importing from OBJ-file

£可爱£侵袭症+ 提交于 2019-12-30 06:57:22
问题 I'm parsing an OBJ-file in Android and my goal is to render & display the object. Everything works fine except the correct texture mapping (importing the resource/image into opengl etc works fine). I don't know how to populate the texture related data from the obj-file into an texturebuffer-object. In the OBJ-file I've vt-lines: vt 0.495011 0.389417 vt 0.500686 0.561346 and face-lines: f 127/73/62 98/72/62 125/75/62 My draw-routine looks like (only relevant parts): gl.glEnableClientState(GL10

Can't use 'defined(@array)' warning in converting .obj to .h

心已入冬 提交于 2019-12-25 18:41:40
问题 I'm trying to convert my .obj file to a .h header file, but i'm getting "Can't use 'defined(@array)' (Maybe you should just omit the defined()?)" warning and no .h files has created. I've tried replacing @center to $center or omintting defined() but it creates .exe file! I've read somewhere that it may be a perl version problem, mine is 5.22 and I couldn't find higher versions to try. Update1: I've put the "obj2opengl.pl " and "myobject.obj" in the same folder. and trying to convert it with

Three .js object rotation on keypress

烈酒焚心 提交于 2019-12-25 03:40:34
问题 I'm desperate. been trying for so long to simply rotate an object on key press event. I can't just figure it, can anyone please show how to do it? this is my model https://www.dropbox.com/s/8yefhx3yc11zbik/b.obj?dl=0 i need to keep rotating it on x axis, as long as keyboard button "B" is pressed down, so that that the shadow from the spotlight or direct light would be changing. anyone? i need to do that with the whole alphabet (i've got all the models) what's the best way to do it? 回答1: You

Loading 3D objects and textures for OpenGL ES rendering

那年仲夏 提交于 2019-12-23 02:53:42
问题 I have some 3D objects stored in 3D editor application specific (Blender/Solid/3DS) file format exported to OBJ+MTL files with optional textures in PNG/JPG files. I would like to load these objects in OpenGL ES application on mobile phone (today for Android and in the near future for iOS too). And I don't want to write my own OBJ+MTL (or any other 3D format) parser. So I would like to use some 3D engine with support for loading 3D models (from OBJ+MTL or exported to 3D engine specific header

Mapping Wavefront .obj texture vertex on OpenGL

给你一囗甜甜゛ 提交于 2019-12-22 06:56:01
问题 An artist gave me all 3D models for me exporting to .obj and .mtl in order that I can render it using OpenGL. But I can't figure out why the texture vertex are greater than 1 and sometimes negative. Take a look at this example: (...) vn -0.000717425 0.00106739 -0.00991695 vn 3.49779e-09 -5.22866e-09 -0.01 vn -0.00142294 0.00211706 -0.00966919 vn -0.00831486 -0.00555545 0 vt 5.82424 -20.091 vt 6.97527 -20.1873 vt 5.81848 -20.1618 vt -7.48189 8.29159 (...) He sent me all textures on TGA format,

Three.js mouse picking object

 ̄綄美尐妖づ 提交于 2019-12-18 18:40:04
问题 So i found a lot of tutorials on how to use mouse picking on default objects available in Threejs itself, but is it possible to use mouse picking on imported models like a .obj file and displaying a sphere at the exact position where the user clicks the model? If so, can someone give me a tutorial or at least an example with source code so i can use it. I prefer a tutorial, because thats a better way to learn it. ;) EDIT: So i got mouse picking working for the model! But now i want to show a

Do Wavefront .obj files support animation?

*爱你&永不变心* 提交于 2019-12-17 19:57:39
问题 How does one export a 3D Studio animated model to OBJ format (if possible)? What will be the resulting file like? How would I read that? 回答1: No, .obj files do not support animation. You can check the .obj specification for details of what it does support. You could potentially export one .obj per frame, but that would be cumbersome. Depending on the tools, it may be possible to export one .obj per keyframe. 回答2: Blender 2.63 can export animations in .obj, with each keyframe (as hypothesized