Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Can't get the Detail Mask to work on my Secondary Maps

Discussion in 'General Graphics' started by dvaillancourt, Apr 16, 2015.

  1. dvaillancourt

    dvaillancourt

    Joined:
    Apr 8, 2015
    Posts:
    5
    I've got a material that has a secondary normal map. However I don't want this normal map applied to the entire surface of the object. I made a Detail Mask (a black and white png file attached). But it doesn't have any effect on the secondary maps. Am I setting up the mask texture wrong?
     

    Attached Files:

  2. theANMATOR2b

    theANMATOR2b

    Joined:
    Jul 12, 2014
    Posts:
    7,790
    I'd set up proper UV's in a 3D package instead of trying to work this into the game engine.

    Just my opinion though. I'm an artist.
     
  3. dvaillancourt

    dvaillancourt

    Joined:
    Apr 8, 2015
    Posts:
    5
    Looks like the Detail Mask works similar to the Metallic. The relevant data needs to be in the alpha channel. The secondary maps go where the alpha map is white and not show where it's black. I've saved it as a 32 bit BMP file to accomplish this. Wish we didn't have to use BMP files though, a greyscale PNG file is a fraction the size of a 32 bit BMP file.
     
    Almakos likes this.
  4. Pawige

    Pawige

    Joined:
    Nov 26, 2012
    Posts:
    40
    Can't you use the transparency channel in a .PNG or just save a black and white image and check "Alpha from Greyscale" in the import settings?
     
  5. dvaillancourt

    dvaillancourt

    Joined:
    Apr 8, 2015
    Posts:
    5
    I tried the black and white image and checking the "Alpha from Greyscale" and that was a no go. However the transparency channel in a .PNG file did the trick. And now my file size is 20 times smaller. Big Thanks!
     
    DerrickMoore, Pawige and theANMATOR2b like this.
  6. dvaillancourt

    dvaillancourt

    Joined:
    Apr 8, 2015
    Posts:
    5
    Looks like the "Alpha from Grayscale" check box does work with a black and white png file. It didn't work earlier because I probably forgot to press the "Apply" button after I turned on the checkbox.
     
    DerrickMoore likes this.