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

Point light lighting as a square?

Discussion in 'Editor & General Support' started by jamesjohnson88, Apr 25, 2010.

  1. jamesjohnson88

    jamesjohnson88

    Joined:
    Apr 17, 2010
    Posts:
    8
    I am really confused as to why they are doing this...

    I think an image will explain it the best -
     

    Attached Files:

  2. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    check the different textures on the light like the cookie etc
     
  3. jamesjohnson88

    jamesjohnson88

    Joined:
    Apr 17, 2010
    Posts:
    8
    There is no cookie. Should there be? As it won't let me add one...?
     

    Attached Files:

  4. Eric5h5

    Eric5h5

    Volunteer Moderator Moderator

    Joined:
    Jul 19, 2006
    Posts:
    32,400
    Probably something to do with the maximum number of pixel lights. Increase that in the quality settings or use vertex lighting.

    --Eric
     
  5. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    As an alternative reason it might be related to the object on which the light is / in which or its collision object. That potentially could explain it too as it looks like it is light rotation related so either cookie or some collision thats there and impacts it
     
  6. jamesjohnson88

    jamesjohnson88

    Joined:
    Apr 17, 2010
    Posts:
    8
    Ok, I guess it is probably do with the object then. Guess, i'll go back into the 3D modeller and see what might be causing it in there.

    Thanks for the help. It is greatly appreciated.
     
  7. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    for testing remove the collider on the object, that will show you if the collider / mesh is the cause
     
  8. jamesjohnson88

    jamesjohnson88

    Joined:
    Apr 17, 2010
    Posts:
    8
    Still square. Hmmm....
     
  9. vegenarie

    vegenarie

    Joined:
    Jan 5, 2011
    Posts:
    287
    This also happens to me, its not the collider or the number of pixel lights the problem it is something about the shader.
    Happens the same with spot lights when you dont use cookie attenuation, but something wrong happens with point lights. I am using the tutorial http://en.wikibooks.org/wiki/Cg_Programming/Unity/Cookies
    It works fine with spot lights but point lights use cubemaps and somehow the code is wrong.

    Anyone knows how to fix it without using surface shaders?
     
  10. Foo-Byte

    Foo-Byte

    Joined:
    Jun 26, 2015
    Posts:
    12
    I have the same problem with spotlights. With no cookie selected, they cast a square light. However, if I pause the game and change anything about the light in the editor, I get a nice circular light, just as I'd expect. By that I mean, if I change the light type from spotlight to point light and back again, or if I check then uncheck Halo, or select a cookie then set it back to None ... any of those things "fix" whatever is going on. Obviously, I can't have my end users do this. I'm not a lighting pro, but maybe this extra information might trigger an a-ha moment for someone who is...
     
  11. selvendranks

    selvendranks

    Joined:
    Apr 8, 2021
    Posts:
    3
    Go to edit, project setting , quality and increase the' pixel light count ' and your issue will be fixed
     
    drgavin likes this.