Search Unity

Polygon offset line mode

Discussion in 'Shaders' started by sstephane, Jul 20, 2011.

  1. sstephane

    sstephane

    Joined:
    Nov 5, 2009
    Posts:
    30
    Hi,

    I know it is possible to enable polygon offset through shader lab to offset fragments depth. In OpenGL api, it is possible to set the polygon offset mode like : GL_POLYGON_OFFSET_FILL for offsetting polygons or GL_POLYGON_OFFSET_LINE for lines.

    http://pyopengl.sourceforge.net/documentation/manual/glPolygonOffset.3G.html

    I may be mistaken but I noticed that ShaderLab Offset parameter has no effect on lines and only on triangles. Is there any ShaderLab parameter to set the polygon Offset mode?

    Thanks.