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. Dismiss Notice

How to use a lightmap texture in the shader graph

Discussion in 'Shader Graph' started by GamesStudioDreams, Jan 9, 2023.

  1. GamesStudioDreams

    GamesStudioDreams

    Joined:
    Jan 1, 2023
    Posts:
    15
    Hello everyone, I have a lightmap texture and I want to apply it to my shader, how do I do that?
     
  2. Magnilum

    Magnilum

    Joined:
    Jul 1, 2019
    Posts:
    142
    What do you mean ?

    Where does this lightmap come from ? What is on it ? An object, a entire scene ?
     
  3. GamesStudioDreams

    GamesStudioDreams

    Joined:
    Jan 1, 2023
    Posts:
    15
    is the light map of the entire scene
     
  4. Magnilum

    Magnilum

    Joined:
    Jul 1, 2019
    Posts:
    142
    Where did you do the scene ? In a 3D software or in Unity ?

    If you did it in a 3D software, you should probably import the scene in Unity and bake the lightmap with it. Change parameters to get a result as close as possible as you have already done.

    Or else, if it is from Unity, you do not need shader to see. It is already visible normaly when you are in the editor or in game.

    Can you provide some images ?
     
  5. GamesStudioDreams

    GamesStudioDreams

    Joined:
    Jan 1, 2023
    Posts:
    15
    I made the scene in unity
     
  6. GamesStudioDreams

    GamesStudioDreams

    Joined:
    Jan 1, 2023
    Posts:
    15
    I wanted to put my own light map
     
  7. Magnilum

    Magnilum

    Joined:
    Jul 1, 2019
    Posts:
    142
    From where ? Where have you baked this lightmap ? Because Unity can make one for you directly usable.
     
  8. GamesStudioDreams

    GamesStudioDreams

    Joined:
    Jan 1, 2023
    Posts:
    15
    I made a procedural level system and also a light map generation system, but I don't know how to apply my light map that is being generated
     
  9. GamesStudioDreams

    GamesStudioDreams

    Joined:
    Jan 1, 2023
    Posts:
    15
    it creates the light map per pixel
     
  10. Murgilod

    Murgilod

    Joined:
    Nov 12, 2013
    Posts:
    9,685
  11. esanuriana08

    esanuriana08

    Joined:
    Jan 10, 2021
    Posts:
    13