Search Unity

Question Masking and clipping textures

Discussion in 'Shader Graph' started by MLGoatStudios, Apr 21, 2020.

  1. MLGoatStudios

    MLGoatStudios

    Joined:
    Aug 3, 2018
    Posts:
    7
  2. Olmi

    Olmi

    Joined:
    Nov 29, 2012
    Posts:
    1,553
  3. MLGoatStudios

    MLGoatStudios

    Joined:
    Aug 3, 2018
    Posts:
    7
    Thanks for the quick reply, but I want to apply this to a mesh, so I need a material.
     
  4. Olmi

    Olmi

    Joined:
    Nov 29, 2012
    Posts:
    1,553
    Well, in that case just create a shader graph that draws a shape to the alpha channel of your texture? What are you looking for, exacty, as many shapes are very easy to create with a bit of math.

    Or just use a bitmap texture.
     
  5. MLGoatStudios

    MLGoatStudios

    Joined:
    Aug 3, 2018
    Posts:
    7
    So, I'm trying to texture my terrain and what I was thinking about is having basically multiple layers of textures (for example: sand, grass, snow, etc.) and masking according to each point of my heightmap's biome in a circular gradient (or something similar).
     
  6. Olmi

    Olmi

    Joined:
    Nov 29, 2012
    Posts:
    1,553
    Well, you should have said that instead of posting some links about UI effects...When you say "terrain", you mean Unity's built-in Terrain (https://docs.unity3d.com/Manual/CreatingEnvironments.html) or something else, like a mesh you've imported. It would help if you were a bit more precise.
     
  7. MLGoatStudios

    MLGoatStudios

    Joined:
    Aug 3, 2018
    Posts:
    7
    Ok, so I already have my crude procedurally generated terrain, which are consisted of 'chunks' which are just meshes and mesh colliders created of a heightmap... but they are not textured yet, and as I said I've never worked with shaders and materials before :c So in this sense, yes its more like a mesh that I imported.