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. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more..
    Dismiss Notice
  3. Dismiss Notice

Get the maximum scale in lightmap for any renderer!

Discussion in 'Editor & General Support' started by raptcha, Jul 20, 2017.

  1. raptcha

    raptcha

    Joined:
    Jan 16, 2017
    Posts:
    4
    Hey,

    I'm trying to create an editor script to set the 'scale in lightmap' value to its maximum for any selected game object with a mesh renderer on it. So as a result each object that I do this to, will get a full light map allocated only for that particular object. I have noticed in the editor that, if we increase the scale above the max possible scale, it shows a warning that says 'Object's size in lightmap has reached the max atlas size'. Is there a way to see how they are actually calculating that limit in the mesh renderer component?? . I have tried pretty much everything else I can think of. If anyone is interested I can post my half done solution.

    Thanks
     

    Attached Files:

  2. raptcha

    raptcha

    Joined:
    Jan 16, 2017
    Posts:
    4
    Bumping this question. Any have any ideas??
     
  3. Chipboard

    Chipboard

    Joined:
    Aug 26, 2017
    Posts:
    4
    Bumping, this should really be a thing