Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question How to change the shader dropdown category order

Discussion in 'Shaders' started by xuanlane, Jun 15, 2022.

  1. xuanlane

    xuanlane

    Joined:
    Apr 9, 2021
    Posts:
    4
    upload_2022-6-15_16-21-57.png

    I wonder if I can customize the oreder of my shader categories in this shaders dropdown list
     
  2. Invertex

    Invertex

    Joined:
    Nov 7, 2013
    Posts:
    1,539
    This list is defined based on the names in each of the .shader files themselves at the very top of the file and generated from that. This is part of internal editor code, so you can't really change that short of renaming the name line inside those shaders to not be grouped that way. But then anything referencing those shaders by string name will need to be updated..
     
  3. xuanlane

    xuanlane

    Joined:
    Apr 9, 2021
    Posts:
    4
    Thanks for your reply. I understand that I can defined the names of my .shader files by editing the very top of the file. But what makes me confused is that I have found some shader categories can be placed on the top of the list even though their initials are not A. Does it means we can customize the order of the sorts? upload_2022-6-20_17-34-53.png
     
  4. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    2,983
    No, it's just based on the order in the underlying data container.