Use a $PWD independent method to determine the location of the data directory
pwaller opened this issue · 0 comments
pwaller commented
For testing purposes it will be desirable to run for example:
go run ${GOPATH}/src/github.com/go-gl/examples/nehe08/*.go
.. without being concerned about the run directory. Currently, I get [e] Failed to load texture: ../data/Glass.tga
.
This package provides what looks to me to be a reasonable way of figuring out package-relative paths - I use it in glh
to determine a font path.