Page 1 of 1

It is good and it is bad

PostPosted: Fri Sep 11, 2020 2:37 pm
by jpujolar
Hello,

It may be a bug. Maybe I do something unexpected. The issue is:

1. I have created through Blender a set of eyeglasses that work fine in MakeHuman, except...
2. MH does not display its texture correctly; it displays the default texture design.

But

3. If I import the character and eyeglasses back to blender, they appear fine. See attached.

I have tried changing the name of the PNG that defines the colour in various ways (also attached)

Re: It is good and it is bad

PostPosted: Fri Sep 11, 2020 3:03 pm
by joepal
Can you attach the MHCLO and the MHMAT files too? Or paste their contents in a reply?

Re: It is good and it is bad

PostPosted: Sat Sep 12, 2020 9:45 am
by jpujolar
joepal wrote:Can you attach the MHCLO and the MHMAT files too? Or paste their contents in a reply?


Here they are. It seems that these extensions are not allowed as attachment. So I have simply entered the extension "zip." Do not unzip it. Just change the extension.

It does not happen now with other trials I have made. Now the eyeglasses appear colorless, whether I activate "use skin" or not. I may have to do with the way Blender handles textures and the texture paint function, which I find somewhat unpredictable.

Re: It is good and it is bad

PostPosted: Sat Sep 12, 2020 2:42 pm
by punkduck
this was easy to find.

Code: Select all
diffuseTexture Pasta ulleres.png


(it is a line in the .mhmat file, both files are text-files)

instead of using the Catalan version for the glasses MakeHuman tries to read a texture named "Pasta". :?

I don't know, I first thought, our module replaces letters to "clean the names" (especially letters like "/" will create trouble), but I am pretty sure the texture-names we do not change, because then we have to change the filenames not created with our tools also.

There must be a message in the left lower corner in MakeHuman when you try to load it, like "cannot get texture for file path Pasta"

Atm you must rename it to something without blanks. That's a limit inside Makehuman. I also tried a version with diffuseTexture "Pasta ulleres.png" but that does not work,

The fastest way to repair that: rename the .png file and use a simple text-editor to replace the line in the .mhmat file. Otherwise recreate the glasses with a different texture name the same way you did before.

Re: It is good and it is bad

PostPosted: Sat Sep 12, 2020 2:59 pm
by jpujolar
It was silly enough... Thanks!

Re: It is good and it is bad

PostPosted: Sat Sep 12, 2020 4:18 pm
by flute
Very pretty glasses: once "repaired", don't you want to put them in the assets? It would be very useful to me! :)

Re: It is good and it is bad

PostPosted: Sun Sep 13, 2020 5:08 am
by MTKnife
I assume putting quotes around the filename will also work.

Re: It is good and it is bad

PostPosted: Sun Sep 13, 2020 8:28 am
by Aranuvir
MTKnife wrote:I assume putting quotes around the filename will also work.

Unfortunately no. The parser is kept quite simple. Each line of the file is piped through Python's split() function, using white spaces as separator. The expected result is something like key, value1, [value2 ...]. If you split up a line like word1 "word2 word3", you'll get the result key = word1, value1 = "word2, value2 = word3". This still won't work. That's the reason why it is good practice to avoid white spaces in file names, not only for Python but also for example in shell environments this could quite a pain in the a...