mirror of https://github.com/mosra/magnum.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
398 B
18 lines
398 B
uniform highp int level; |
|
uniform highp sampler2D textureData; |
|
|
|
#ifndef GL_ES |
|
layout(pixel_center_integer) in highp vec4 gl_FragCoord; |
|
#endif |
|
|
|
out highp uvec4 fragmentOutput; |
|
|
|
void main() { |
|
#ifndef GL_ES |
|
ivec2 pos = ivec2(gl_FragCoord.xy); |
|
#else |
|
ivec2 pos = ivec2(gl_FragCoord.xy - vec2(0.5)); |
|
#endif |
|
|
|
fragmentOutput = floatBitsToUint(texelFetch(textureData, pos, level)); |
|
}
|
|
|