Search Unity

[LegacyGUI] How to change the default shaders ?

Discussion in 'Shaders' started by manutoo, Aug 29, 2015.

  1. manutoo

    manutoo

    Joined:
    Jul 13, 2010
    Posts:
    524
    Hello,

    I'd like to add a brightness setting to the Legacy OnGui() when using GUI.Button() & GUI.DrawTexture() and other stuff.

    To do so, I want to change the shaders used by these functions. I took Internal-GUITexture.shader & Internal-GUITextureBlit.shader & Internal-GUITextureClip.shader & Internal-GUITextureClipText.shader within builtin_shaders-5.1.3f1.zip , put them in "Assets\Resources\Shaders" with my other shaders and changed their output to black, but nothing changed on screen.

    I closed & restarted Unity, and still nothing.

    Anyone would know how to change these shaders..?

    Thanks in advance for any help ! :)
     
  2. manutoo

    manutoo

    Joined:
    Jul 13, 2010
    Posts:
    524
    According to this http://forum.unity3d.com/threads/replace-built-in-halo-shader.160273/ & that http://forum.unity3d.com/threads/re...aded-shadow-mapping-shader.72691/#post-470706 , it seems not possible to change Internal shaders (with a few exceptions).

    So OnGUI will stay in the long list of half-cooked Unity features that you can't do anything about to make them fully work... o_O

    I guess my only option left (without changing of GUI system & redoing all my GUIs) is to change all textures' brightness on load, pixel per pixel... Pffff....