Open erisdev opened 13 years ago
Thought I'd fixed the problem, I'll take another look. I've rewritten the function I'll do some testing to see if it works. If not I'll take a look at closer look at js-uri, it just seems a little bit overkill adding external dependency for path lookups.
I'm trying to load a wavefront model,
model/steve.obj
that references an mtl file in the same directory. When I try to load the model withsteve.setSrc('model/steve.obj', location.href)
, I get this strange error that seems to point to a problem in the path munging.The obj file references it as simply
steve.mtl
, and I've traced the origin of the extra/undefined/
toGLGE.Wavefront.prototype.getAbsolutePath
—I'm just not sure what to make of it. It might be worth the effort to refactor it to use a preexisting path parsing library that knows how to handle some of the edge cases that can come up.