Search Unity

Curious thing - wireframe of new skybox in unity 5 (sphere instead of box)

Discussion in 'General Graphics' started by Breyer, Mar 24, 2015.

  1. Breyer

    Breyer

    Joined:
    Nov 10, 2012
    Posts:
    412
    If you thinking on doing custom stuff with skybox and want to know how wireframe look there is two pics:

    wireframe skyboxpart1.png wireframe skyboxpart2.png

    keep in mind these pics show hemisphere (upper). lower hemisphere looks identical but flipped down of course. I managed achieve this effect thanks to scrawk's wireframe shader. I counted that there is 13 vertices in y dimension starting from middle of hemisphere (25 total, from down to up)
     
    Marco-Sperling likes this.
  2. Marco-Sperling

    Marco-Sperling

    Joined:
    Mar 5, 2012
    Posts:
    620
    Thanks for this useful insight.
    Do you know what kind of sphere they render? Is it a unit sphere?
     
  3. Breyer

    Breyer

    Joined:
    Nov 10, 2012
    Posts:
    412
    Unfortunetly no, didnt checked this. If u want to know this u probably could make custom skybox where vertex color is equal to one of (local?) dimension (i think easiest is y dimension). if vertex in middle will be completely black and last up vertex will be completely white then u can assume sphere is one unit in radius otherwise u have to calculate approximately how much upper hemisphere is white compared to black-white (because from black middle to first white is one unit)
     
    Last edited: Jul 23, 2015
    Marco-Sperling likes this.
  4. Marco-Sperling

    Marco-Sperling

    Joined:
    Mar 5, 2012
    Posts:
    620
    I did just that and it seems to be the case that the radius equals 1 unit.
     
  5. Breyer

    Breyer

    Joined:
    Nov 10, 2012
    Posts:
    412
    so diameter is 2unit. good to know.