mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-03 16:35:36 +00:00
gpu/internal/convertshaders,gpu: represent converted shaders with raw literals
Raw strings with linebreaks are easier to read and produce smaller diffs. Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
@@ -2,16 +2,18 @@
|
||||
|
||||
// SPDX-License-Identifier: Unlicense OR MIT
|
||||
|
||||
#extension GL_GOOGLE_include_directive : enable
|
||||
|
||||
precision highp float;
|
||||
|
||||
#include <common.inc>
|
||||
#include "common.h"
|
||||
|
||||
layout(binding = 0) uniform Block {
|
||||
vec4 transform;
|
||||
vec4 uvTransformR1;
|
||||
vec4 uvTransformR2;
|
||||
float z;
|
||||
};
|
||||
} _block;
|
||||
|
||||
layout(location = 0) in vec2 pos;
|
||||
|
||||
@@ -20,7 +22,7 @@ layout(location = 1) in vec2 uv;
|
||||
layout(location = 0) out vec2 vUV;
|
||||
|
||||
void main() {
|
||||
vec2 p = pos*transform.xy + transform.zw;
|
||||
gl_Position = toClipSpace(vec4(p, z, 1));
|
||||
vUV = transform3x2(m3x2(uvTransformR1.xyz, uvTransformR2.xyz), vec3(uv,1)).xy;
|
||||
vec2 p = pos*_block.transform.xy + _block.transform.zw;
|
||||
gl_Position = toClipSpace(vec4(p, _block.z, 1));
|
||||
vUV = transform3x2(m3x2(_block.uvTransformR1.xyz, _block.uvTransformR2.xyz), vec3(uv,1)).xy;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user