1
1
mirror of https://github.com/wez/wezterm.git synced 2024-11-23 23:21:08 +03:00

be explicit about shaders outputting srgb

This helps correct the color brightness on windows
This commit is contained in:
Wez Furlong 2019-02-17 16:42:21 -08:00
parent a8b899e25d
commit 3302b3bb64
2 changed files with 12 additions and 2 deletions

View File

@ -140,7 +140,7 @@ impl TerminalWindow {
let mut_loop = event_loop.event_loop.borrow_mut();
glium::Display::new(window, pref_context, &*mut_loop)
.map_err(|e| format_err!("{:?}", e))?
.map_err(|e| format_err!("{:?}", e))?
};
let window_id = display.gl_window().id();
let window_position = display.gl_window().get_position();

View File

@ -370,7 +370,17 @@ impl Renderer {
f32::from(height),
)?;
let program = glium::Program::from_source(facade, VERTEX_SHADER, FRAGMENT_SHADER, None)?;
let source = glium::program::ProgramCreationInput::SourceCode {
vertex_shader: VERTEX_SHADER,
fragment_shader: FRAGMENT_SHADER,
outputs_srgb: true,
tessellation_control_shader: None,
tessellation_evaluation_shader: None,
transform_feedback_varyings: None,
uses_point_size: false,
geometry_shader: None,
};
let program = glium::Program::new(facade, source)?;
let atlas = RefCell::new(Atlas::new(facade, TEX_SIZE)?);