Duplicating an item under skin in the Materials tab

If your topic doesn't fit anywhere else, put it here.

Moderator: joepal

Duplicating an item under skin in the Materials tab

Postby blindsaypatten » Sat Mar 25, 2017 9:26 pm

If I want to duplicate and modify one of the skins in the Materials tab, specifically the Young caucasian special suit, and have it show up as another item in that tab, what are the steps I have to take?

Thanks!
blindsaypatten
 
Posts: 586
Joined: Tue Mar 14, 2017 11:16 pm

Re: Duplicating an item under skin in the Materials tab

Postby joepal » Sat Mar 25, 2017 10:10 pm

Copy the mhmat file, copy the texture file referred to in the mhmat file, edit the new mhmat file to point the "diffuseTexture" at the copy of the image. Edit the image.

The mhmat file is just a plain text file, which should be reasonably easy to understand.

Take a look at this mhmat file for example: http://www.makehumancommunity.org/sites ... tals.mhmat

You might want to change the "name" and "tag" entries too. They are arbitrary strings, but make it easier to sort the skins in MH.
Joel Palmius (LinkedIn)
MakeHuman Infrastructure Manager
http://www.palmius.com/joel
joepal
 
Posts: 4626
Joined: Wed Jun 04, 2008 11:20 am

Re: Duplicating an item under skin in the Materials tab

Postby Nick_Angel » Mon Mar 27, 2017 2:20 pm

Today I tried something like this with the "high res suit". In ver 1.1.1, it is titled "male_elegantsuit01" (@Joe, Brian set the laptop up with newest version on another drive partition, just because I asked.) Now when I made a copy of the entire folder makehuman/data/clothes/male_elegantsuit01/ and renamed it makehuman/data/clothes/male_elegantsuit02 then I changed the line #30, of the mhmat from; diffuseColor 1.0 1.0 1.0 to diffuseColor 0.0 0.3 1.0 to make the suit blue. It failed to work, I directly opened the PNG in Gimp and changed it with a blue filter and that worked.

This information is just to better understand and acknowledge the workings of the program, and has no bearing on the company project. They have all the mesh skins running through yet another process, go figure. Would all that I did above, really be needed, or could I just duplicate the PNG or the mhmat file alone under the materials for "Blue Suit"? As to my grasp of how the materials file is handling the PNG, it is setting the filter over a neutral grey image. But this doesn't seem to be the case for the black suit.
User avatar
Nick_Angel
 
Posts: 23
Joined: Fri Feb 24, 2017 12:19 am

Re: Duplicating an item under skin in the Materials tab

Postby punkduck » Mon Mar 27, 2017 7:10 pm

Hi

This is happening, when a litsphere is used, in case of the suit it is used. I'm also often using it to make the normalmap visible in MH.

For the suit:

Use Utilities/Material Editor (you must activate the editor in Settings/Plugins if not allready done).

Select clothes, male_elegantsuit01 and set the shader to none. Now you can change material diffuse settings. Save the .mhmat-file. Of course you can also do it by changing only the mhmat file (by deleting the line with litsphere I guess). But I prefer this method to see the result at least once.
User avatar
punkduck
 
Posts: 1260
Joined: Mon Oct 17, 2016 7:24 pm
Location: Nuremberg, Germany

Re: Duplicating an item under skin in the Materials tab

Postby blindsaypatten » Mon Mar 27, 2017 7:25 pm

joepal wrote:Copy the mhmat file, copy the texture file referred to in the mhmat file, edit the new mhmat file to point the "diffuseTexture" at the copy of the image. Edit the image.


Sorry I didn't say thanks for this earlier, thanks!

Just to make sure I could do this I created a white image which I have added as a "plaster" skin ;) I've got bigger plans but for now I do like to be able to view the models in white.
blindsaypatten
 
Posts: 586
Joined: Tue Mar 14, 2017 11:16 pm

Re: Duplicating an item under skin in the Materials tab

Postby Nick_Angel » Tue Mar 28, 2017 1:24 am

Thanks a bunch punkduck! Worked like a charm...

na1.png
User avatar
Nick_Angel
 
Posts: 23
Joined: Fri Feb 24, 2017 12:19 am


Return to General discussions about makehuman

Who is online

Users browsing this forum: No registered users and 7 guests