pulled swapchain out of shaderkernels

This commit is contained in:
2019-08-05 22:09:21 -07:00
parent 28878dc345
commit bb1f782168
6 changed files with 171 additions and 79 deletions

View File

@@ -42,7 +42,6 @@ use vulkano::descriptor::pipeline_layout::PipelineLayoutAbstract;
use vulkano::sync::GpuFuture;
use shaderc::CompileOptions;
use shade_runner::CompileError;
use crate::workpiece::{WorkpieceLoader, Workpiece};
use winit::{EventsLoop, WindowBuilder, WindowEvent, Event, DeviceEvent, VirtualKeyCode, ElementState};
use winit::dpi::LogicalSize;
use vulkano_win::VkSurfaceBuild;
@@ -54,7 +53,6 @@ mod input;
mod vkprocessor;
mod util;
mod button;
mod workpiece;
mod vertex_2d;
mod vertex_3d;
mod sprite;
@@ -76,6 +74,7 @@ fn main() {
processor.compile_kernel(String::from("simple-edge.compute"));
processor.compile_shaders(String::from("simple_texture"), &surface);
processor.load_buffers(String::from("background.jpg"));
processor.create_swapchain(&surface);
let mut timer = Timer::new();
let mut frame_future = Box::new(sync::now(processor.device.clone())) as Box<dyn GpuFuture>;