Prob. With Strubi's Script.

(jorx) #1

After all the hard work in finding Strubi’s unwrapper script,

(Link on the page)
I try running it and it says:

Traceback (most recent call last):
File “Unwrapper”, line 14 in ?
ImportError: No module named mesh

?? There are times I wish I knew Python.

(acasto) #2

I assume you copied the new module classes to the right directory?

(jorx) #3

What do you mean? What modules?

(acasto) #4

In strubis package, there is a set of module classes you must copy, that is why it is say no mdule mesh, it can’t find it.

(jorx) #5

How do I do that??? What files are the modules?

(acasto) #6

I’m not for sure off the top of my head, in the folder though there is instructions that explain how to install everything.

(jorx) #7

I don’t get it. I read the Install.txt and Readme.txt
but it said “Set your path for the modules, or edit your PYTHONPATH” But what exactly do I do?

(acasto) #8

In that download, there is some python files , I think in the folders of python then mesh…??? You can copy them to you python library directory or set you path to reference them.

(jorx) #9

I copied the ‘mesh’ directory to the /python20/lib/ but doesn’t work still. How do I set the path? I mean, do I add an environment variable, then what do I put in the env variable name?

(acasto) #10

I’m not sure about windows, I’m using linux right now. All I know is this is how it works. In the script the modules are called in by ‘import’, so then python goes looking for the modules, but it has to know where, this would be your pythonpath I guess??? So you just have to make sure that when it goes looking, it finds it.

Check your environment variables and see where the pythonpath is, then see if that is the same as where you moved the mesh libraries. If not you can either set a variable or move the libraires to where the path is set.

(theeth) #11

you can also set the PythonPath directly from the scipt this way.

import sys
sys.path.append("insert path here")


import sys
sys.path.extend(["insert path ", "insert path 2", "insert path 3"])


(jorx) #12

Ok. I put that code on the beginning of the script. I told it to go to
c:\Program Files\blender-creator-2.23-windows\python\mesh
but now it comes up with

Traceback (most recent call last):
File “Unwrapper”, line 16, in ?

When I unzipped Strubi’s zip file, there was a folder, “blend” where the blend file was, and a folder “python” which had other folders. I tried it with the directory “mesh”, and “python”.
If I can get this to work so I can make custom textures, that would be SO COOL!
I appreciate your help.

(acasto) #13

if you could do me a favor, when you get it to work, post you specs (blender version, exact name of script, links, etc…) and what you did to make it work so I can get it in the Blender Integration Effort files so that we can test, modify, and provide the info to others.

(jorx) #14

I just can’t get it to work! I’ve used Blender 2.23, blender 2.21 and I still need help!

(overextrude) #15

In the info window (the one at the very top), Blender has a field “Python:” that allows you to specify a directory where the python files are located. Create a subdirectory inside your Blender directory, and move the python files here. Then, enter the full pathname into the “Python:” field. I’ve done it this way on a Linux box, and I don’t see why it wouldn’t work on 'Doze.

(jorx) #16

I’ve got Python to work. I just can’t tell it to find the .py files that came with the script. What folder do I set the path to? Try Strubi’s script yourself and tell me how to install it properly.

(overextrude) #17

Ok, let’s say that you create a “Python” subdirectory inside “C:\Program Files\Blender”. Set the directory name in the info window to “C:\Program Files\Blender\Python”. This tells Blender where the script files are located, and once this is done, the unwrapper script should run. Since I’m not running on 'Doze, there’s something I could be missing, and if so, my apologies.

(jorx) #18

Thank you SOO MUCH! Now when I press Alt-P the script’ll run and come up with the buttons. Now, where can I find out how to use it??
With Gratitude,

(MoreK) #19

There’s a short guide in the unwrap.blend file. Just drag down the up frame of the top left window, it’s right there…

But HOW DID YOU GET SO FAR??? Getting dialog window with buttons and all? I have copied all stuff in F:\Program Files\Blender\python\ and tried all tricks: windows environment variable, inserting sys.path.append and setting Python field in Blender. No luck, I keep getting various error messages, the script can’t find modules etc. Where exactly did you copy all the files?!

  • MoreK -

(jorx) #20

Now I will reveal my secret to the world on how I got it to work.

  1. I unzipped Stubi’s zip file. There was a 2 folders, blend, and python.
    I unzipped these into my blender dir.
  2. I opened the .blend file in Blender, then to get the script to work, I pulled down the very top window, to give me access to the setup panel. I inserted the path to Strubi’s “python” folder, into the button labeled “Python: insert path here” so it looked like “Python: C:\program files\blender2.23\python”
  3. Voila! It worked!

(Python WAS installed. 2.0.1)