OSDN Git Service
(root)
/
meshio
/
pymeshio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
version 2.0.0
[meshio/pymeshio.git]
/
examples
/
pmdbuilder.py
diff --git
a/examples/pmdbuilder.py
b/examples/pmdbuilder.py
index
e41112c
..
846c7b2
100644
(file)
--- a/
examples/pmdbuilder.py
+++ b/
examples/pmdbuilder.py
@@
-36,7
+36,6
@@
def build(path):
yield i
\r
indexGen=indices()
\r
for i, m in enumerate(io.materials):
\r
yield i
\r
indexGen=indices()
\r
for i, m in enumerate(io.materials):
\r
- print(i, m)
\r
material=opengl.material.MQOMaterial()
\r
material.vcol=True
\r
material.rgba=(
\r
material=opengl.material.MQOMaterial()
\r
material.vcol=True
\r
material.rgba=(
\r
@@
-44,8
+43,9
@@
def build(path):
m.diffuse[1],
\r
m.diffuse[2],
\r
m.diffuse[3])
\r
m.diffuse[1],
\r
m.diffuse[2],
\r
m.diffuse[3])
\r
- if m.texture!="":
\r
- texturepath="%s/%s" % (basedir, m.texture)
\r
+ texturefile=m.texture.decode('cp932')
\r
+ texturepath=os.path.join(basedir, texturefile)
\r
+ if os.path.isfile(texturepath):
\r
if not texturepath in textureMap:
\r
texture=opengl.texture.Texture(texturepath)
\r
textureMap[texturepath]=texture
\r
if not texturepath in textureMap:
\r
texture=opengl.texture.Texture(texturepath)
\r
textureMap[texturepath]=texture
\r