Skip to content

Commit 298648b

Browse files
committed
dynamic resolution WIP; remove stalling gpu with glFinish
1 parent 7bc7516 commit 298648b

File tree

22 files changed

+223
-172
lines changed

22 files changed

+223
-172
lines changed
File renamed without changes.
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
2+
$include ../shaderConventions.h
3+
4+
$define shader vertex
5+
6+
layout(location = CAGE_SHADER_ATTRIB_IN_POSITION) in vec3 inPosition;
7+
layout(location = CAGE_SHADER_ATTRIB_IN_UV) in vec3 inUv;
8+
out vec2 varUv;
9+
10+
void main()
11+
{
12+
gl_Position = vec4(inPosition.xy * 2 - 1, inPosition.z, 1);
13+
varUv = inUv.xy;
14+
varUv.y = 1 - varUv.y;
15+
}
16+
17+
$define shader fragment
18+
19+
layout(binding = 0) uniform sampler2D texColor;
20+
in vec2 varUv;
21+
out vec4 outColor;
22+
23+
void main()
24+
{
25+
outColor = textureLod(texColor, varUv, 0);
26+
}

data/cage/shader/engine/engine.assets

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,9 @@ engine.pack
55
[]
66
scheme = shader
77
billboard.glsl
8-
blit.glsl
8+
blitPixels.glsl
9+
blitScaled.glsl
910
decal.glsl
10-
font.glsl
1111
skybox.glsl
1212
standard.glsl
13+
text.glsl
Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
[]
2-
blit.glsl
3-
font.glsl
2+
blitPixels.glsl
3+
blitScaled.glsl
44
standard.glsl
5+
text.glsl
File renamed without changes.

data/cage/shader/shader.assets

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
[]
32
scheme = pack
43
shader.pack

data/cage/shader/shader.pack

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
21
[]
32
effects/effects.pack
43
engine/engine.pack
5-
visualize/visualize.pack
64
gui/gui.pack

data/cage/shader/visualize/color.glsl

Lines changed: 0 additions & 14 deletions
This file was deleted.

data/cage/shader/visualize/depth.glsl

Lines changed: 0 additions & 20 deletions
This file was deleted.

data/cage/shader/visualize/monochromatic.glsl

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)