Will the fragments out of the rect defined by glScissor() be processed by Pixel Shader ?

This topic contains 3 replies, has 2 voices, and was last updated by  Chrishoo 3 years, 8 months ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #31580

    Chrishoo
    Member

    HI all
    If I define a rect (x=0, y=0, w=300, h=300) using glScissor(), I want to know whether the clip operation executing before Pixel Shader or after it?

    If a fragment represents the pixel(301, 301) on screen, it cannot be drawn on screen buffer surely. But I want to know if it is cut off before entering the Pixel Shader.

    Thanks a lot!
    Chris

    #38301

    Chrishoo
    Member

    Sorry for “Pixel Shader” , I means “Fragments Shader”.

    #38302

    Joe Davis
    Member

    Hi Chris,

    The scissor is applied before fragment shaders execute. The only fragments that will be shaded are those that fall within the bounds of the scissor region.

    Thanks,
    Joe

    #38303

    Chrishoo
    Member

    Thank you, Joe.

Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic.