Announcement

Collapse
No announcement yet.

Revealing message/actor/decal when shined by a flashlight

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Revealing message/actor/decal when shined by a flashlight

    Hi I would like to reveal a message on a mesh when shined by a flashlight. What can I do to achieve this material? I know some people are trying to use 2 normal/spec maps but how to reveal only the letter being shined?

    This is the example

    Click image for larger version

Name:	gtavsecretmap.jpg
Views:	1
Size:	153.3 KB
ID:	1208464


    Firing a trace line from the player camera and hide/unhide the object seems like an alternative but is there a better way of doing it? If possible I want the problem to be tackled from the material it self.

    #2
    This is actually pretty straightforward. If you use decals, not Dbuffer but regular deferred decals, then the color of those decals will only show up under a realtime light, but not static lighting. This is because deferred decals are applied after static lighting.

    Comment


      #3
      There will be dynamic light in some of the room and I only want to show the msg if a player is shining the decal/actor with a specific flashlight, is there other workaround ?

      Comment


        #4
        Originally posted by LoveTune View Post
        There will be dynamic light in some of the room and I only want to show the msg if a player is shining the decal/actor with a specific flashlight, is there other workaround ?
        What exactly is wrong with this solution?

        Comment


          #5
          This thread talks about doing something similar to what you want.

          HTH
          Never say Never, Because Never comes too soon. - ryan20fun

          Frames Per Second is NOT a proper performance metric, You should use frame time. You can read this or this as to why.
          (Profiling) Tools: RenderDoc (UE4 Plugin), NVIDIA nSight, AMD GPU PerfStudio, CodeXL
          Good articles/Series: A trip through the Graphics Pipeline 2011

          Comment


            #6
            Originally posted by JamesEmory View Post
            What exactly is wrong with this solution?
            Umm I might have misunderstand something but didn't he say the decal will only appear when shined by real time lighting? And I would have some real time lighting next to the decal at the start of the game which ultimately reveal the msg? And how can I have the decal to appear only when shined by a certain type of light?

            Edit: Checking the post now seems like something I just need, thanks for the help all

            Comment

            Working...
            X