I don't understand what value range glFragCoord returns when accessing a texture.
I'm writing a color bayer demosaicing shader for raw digital camera photos, and I need to get the actual original image pixel location (based on the texture size) to determine whether I've accessed a red, green or blue pixel in the bayer pattern.
Example: The source texture is 2048 pixels wide and 1536 pixels high, so I need to know where the current fragment is located relative to this scale.
To be overly redundant, I want to get the x value in the range of 0-2047 and the y value in the range of 0-1535.
By the way, I'm using standard sample2D uniforms, NOT sampler2DRect.
I appreciate your help.