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

What does "real" in shaders of lightweight pipeline means? It seems some sort of number.

Discussion in 'Shaders' started by hong1991, Aug 28, 2018.

  1. hong1991

    hong1991

    Joined:
    Sep 16, 2017
    Posts:
    14
    I found there is some shader functions use real as return type, it seems some sort of number. What does it exactly means, and what's the difference between it and others(float, half, fixed).
     
  2. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    2,864
    Hi!

    Real is either float or half, depending on the platform. You can check the file Common.hlsl.
     
    rrtt_2323 likes this.
  3. hong1991

    hong1991

    Joined:
    Sep 16, 2017
    Posts:
    14
    thanks a lot, it helps! I should have thought of it.