1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 varying mediump vec4 vColor;
9 #ifdef WR_VERTEX_SHADER
10 PER_INSTANCE in vec4 aRect;
11 PER_INSTANCE in vec4 aColor;
14 vec2 pos = mix(aRect.xy, aRect.zw, aPosition.xy);
15 gl_Position = uTransform * vec4(pos, 0.0, 1.0);
16 gl_Position.z = gl_Position.w; // force depth clear to 1.0
21 #ifdef WR_FRAGMENT_SHADER