Announcement

Collapse
No announcement yet.

SpotLight, starting cone shape

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

    SpotLight, starting cone shape

    Hello

    I've realized that all spot lights are started from a point, that is not what of want , in fact I want just clip the sharp starting point and make it like a clamped cone.
    like the image .
    is it possible to do it ?
    thank you in advance

    #2
    anyone please!

    Comment


      #3
      Hello
      I really appreciate if someone can guide me through this.
      is there any possible way to do it ?

      thank you

      Ps : I think I post this in the wrong topics. can I move it to other sections?
      Last edited by hadi jam; 06-29-2020, 01:52 AM.

      Comment


        #4
        The best I could suggest is do a search for "IES Light Profiles" in the doc pages...or in the forums too.

        Comment


          #5
          You could also use Rect lights but it depends on what you try to achieve.

          https://docs.unrealengine.com/en-US/...hts/index.html

          My Artstation Profile
          Currently working on A Story of Hope : WIP Thread // Website

          Comment


            #6
            Originally posted by YourDownfall View Post
            You could also use Rect lights but it depends on what you try to achieve.

            https://docs.unrealengine.com/en-US/...hts/index.html
            yes thanks, I saw that.

            in the doc:
            The forward renderer does not currently support Rect Lights. If you need to use forward rendering in your Project, use a Spot Light or Point Light instead.

            because I'm using raytracing and thus forward rendering, I can't use rectangle light unfortunately.

            Comment


              #7
              If you're trying to avoid the super-bright starting tip of the cone you get when you put the spotlight right to a surface, you can move the light point out from that surface, which will give it a softer top/start of the cone. Also, the spotlight start point doesn't have to be exactly in the center of your "light fixture" if you have geometry that goes with it. Try adjusting it out so it doesn't actually "hit" anything until a bit further away from the point, and see if that gets you where you need to go.

              If that doesn't work, you need to use a light function material. The IES curves unfortunately don't quite allow describing lights that aren't physical, as far as I can tell.

              Here's a material function example. It requires that you configure the length of the top cone cutoff, and the world position of the light. (The latter is very important!)
              You can rig it up for a single light in the level in the way I show in the second screen shot.
              If you're doing lots of these, you'll want to turn the "create a material instance, configure the light position, and set it as the light function on the spotlight" functionality into a blueprint you can drop in the level.

              Click image for larger version

Name:	light-function.png
Views:	66
Size:	163.6 KB
ID:	1782552


              Click image for larger version

Name:	light-function-configured.jpg
Views:	43
Size:	551.2 KB
ID:	1782553

              Comment


                #8
                You can see that the distance from the point is cut off as a globe (which gives you a conical section on the ground below it.)
                If you want the cutoff to be a flat plane, you can update the shader to do the appropriate dot product math instead of cutting off by distance.

                Comment


                  #9
                  very very useful.
                  thank you very much.

                  I think the source of light ( the bright spot ) should be behind the projector.
                  I assume this can result in something like this (this is what it should look like I suppose)

                  https://www.unrealengine.com/marketp...validated=true
                  Attached Files
                  Last edited by hadi jam; 07-01-2020, 03:42 AM.

                  Comment


                    #10
                    Here I rendered a spot light to demonstrate what I'm looking for.
                    but I get a few problems.

                    - when the spot light is outside the cylinder ( projector) well, not quite right what I want.
                    -when i pull it back inside cylinder, the fog is not occluded by the cylinder .

                    how can I avoid the fog being generated form the spot light point( inside the cylinder)?
                    this "light function material" method kinda eliminates this problem, right?

                    thank you
                    Attached Files
                    Last edited by hadi jam; 07-01-2020, 04:46 AM.

                    Comment


                      #11
                      hello

                      Is there any advice for avoiding this effec?
                      please share your idea .
                      thank you in advance

                      Comment

                      Working...
                      X