embed the simple shader
This commit is contained in:
parent
96e5c78a59
commit
707bb6f66e
|
|
@ -57,10 +57,9 @@ impl Pipeline {
|
||||||
mapped_at_creation: false,
|
mapped_at_creation: false,
|
||||||
});
|
});
|
||||||
|
|
||||||
let shader = std::fs::read_to_string("shaders/line.wgsl").unwrap();
|
|
||||||
let shader = device.create_shader_module(wgpu::ShaderModuleDescriptor {
|
let shader = device.create_shader_module(wgpu::ShaderModuleDescriptor {
|
||||||
label: None,
|
label: None,
|
||||||
source: wgpu::ShaderSource::Wgsl(shader.into()),
|
source: wgpu::ShaderSource::Wgsl(super::SIMPLE_SHADER.into()),
|
||||||
});
|
});
|
||||||
let pipeline = device.create_render_pipeline(&wgpu::RenderPipelineDescriptor {
|
let pipeline = device.create_render_pipeline(&wgpu::RenderPipelineDescriptor {
|
||||||
label: None,
|
label: None,
|
||||||
|
|
|
||||||
|
|
@ -1 +1,3 @@
|
||||||
pub mod lines;
|
pub mod lines;
|
||||||
|
|
||||||
|
static SIMPLE_SHADER: &str = include_str!("simple.wgsl");
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user