Pcjoko / saitoobjloader

Automatically exported from code.google.com/p/saitoobjloader
0 stars 0 forks source link

Texture not showing up on 3D model even when mtl,obj, and jpg files are included in the data folder #16

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Included the libraries ObjLoader and Artoolkit for Processing, which allows 
3D model to pop out via webcam
2. Runs
3. Show the hiro picture to the webcam and texture-less model comes out

What is the expected output? What do you see instead?
When you show the hiro picture 
(http://www.neo-tech-lab.co.uk/arsensor/Article.files/HiroPattern.png) to the 
webcam, I expected the 3D model to be textured. Everything works fine except it 
has no texture on it. The model is entirely white. 

What version of the product are you using? On what operating system?
Processing 2.2.1
NyAR4psg/2.0.0;NyARToolkit/4.1.1
Win 8.1

Please provide any additional information below.

Error:
...
texture diffuse 
        'C:Users/homar_000/Documents/Processing/sketch_3D_model_via_camera/data/BL_WHA
LEtexture.jpg'
The file 
"C:Users/homar_000/Documents/Processing/sketch_3D_model_via_camera/data/BL_WHALE
texture.jpg" is missing or inaccessible, make sure the URL is valid or that the 
file has been added to your sketch and is readable.

I have attached the rar folder here.

Original issue reported on code.google.com by Homare.T...@gmail.com on 18 Jan 2015 at 8:42

Attachments:

GoogleCodeExporter commented 8 years ago
Okay guys, I figured it out. If you are having trouble with your 3D model not 
showing any texture, the issue is in the mtl file.
When you open up its code (NotePad is fine), you have to delete all the 
characters between map_Kd to your image file. 

Example:
Change "map_Kd ../images/texture0.jpg" to 
"map_Kd texture0.jpg"

Credit: https://processing.org/discourse/beta/num_1260273167.html

Original comment by Homare.T...@gmail.com on 19 Jan 2015 at 8:13