mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-07-03 11:12:30 +08:00
Allow shader names with underscores
This commit is contained in:
@@ -1,2 +1,2 @@
|
||||
uniform vec4 src_rect, dest_rect;
|
||||
#pragma kitty_include_shader <blit_common_vertex.glsl>
|
||||
#pragma kitty_include_shader <blit_common.glsl>
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
uniform vec4 src_rect, dest_rect;
|
||||
#pragma kitty_include_shader <blit_common_vertex.glsl>
|
||||
#pragma kitty_include_shader <blit_common.glsl>
|
||||
|
||||
2
setup.py
2
setup.py
@@ -1151,7 +1151,7 @@ def build_uniforms_header(skip_generation: bool = False) -> str:
|
||||
|
||||
for x in sorted(glob.glob('kitty/*.glsl')):
|
||||
name = os.path.basename(x).partition('.')[0]
|
||||
name, sep, shader_type = name.partition('_')
|
||||
name, sep, shader_type = name.rpartition('_')
|
||||
if not sep or shader_type not in ('fragment', 'vertex'):
|
||||
continue
|
||||
class_names[name] = f'{name.capitalize()}Uniforms'
|
||||
|
||||
Reference in New Issue
Block a user