Loading...
Processing Forum
Recent Topics
All Forums
Screen name:
corpius4
corpius4's Profile
1
Posts
0
Responses
0
Followers
Activity Trend
Last 30 days
Last 30 days
Date Interval
From Date :
To Date :
Go
Loading Chart...
Posts
Responses
PM
Show:
All
Discussions
Questions
Expanded view
List view
Private Message
saito obj loader - processing.org does not read my .obj
[0 Replies]
27-May-2012 07:22 PM
Forum:
Contributed Library Questions
The code I wrote has a problem. When I try to load "cello.obj" into OPENGL or P3D, It says:
cello.obj
cello.mtl
objloader version 015
16 April 2009
http://code.google.com/p/saitoobjloader/
local tex:
on
draw mode:
POLYGON
IT DOES NOT GIVE an error message, but does not read the object ("cello.obj") either! I WANT it to say this:
"Loaded OBJ from file '/Users/Caroline/Documents/Processing/MIJN PROGRAMMA/vogelobj/data/cello.obj'
4568 vertices.
5586 normals.
2811 textures coordinates"
Help will be very much appreciated.
My Code:
import processing.opengl.*;
import saito.objloader.*;
OBJModel obj;
void setup(){
size(900, 900,P3D);//can use OPENGL too
background(0);
lights();
translate(0,0,0);
obj = new OBJModel(this,"cello.obj");
obj.debugMode();
// enableLocalTexture is usefull if you're modeling package uses absolute paths when pointing to the diffuse testure (like XSI)
// see mtl file in data folder for example
obj.enableLocalTexture();
//setting the draw mode
// model.drawMode(TRIANGLES);
obj.drawMode(POLYGON);
//print( screenY(500,500,500));
}
void draw(){
translate(0,0,0);
obj.draw();
}
«Prev
Next »
Moderate user : corpius4
Forum