rust_vulkan_test/src/renderer/mod.rs

22 lines
570 B
Rust

mod app;
mod pipelines;
mod render_context;
mod vertex;
pub use app::App;
pub use pipelines::create_triangle_pipeline;
mod scene;
pub use scene::Scene;
pub use vertex::Vertex2D;
use std::sync::Arc;
use vulkano::image::view::ImageView;
use vulkano::image::Image;
/// This function is called once during initialization, then again whenever the window is resized.
fn window_size_dependent_setup(images: &[Arc<Image>]) -> Vec<Arc<ImageView>> {
images
.iter()
.map(|image| ImageView::new_default(image.clone()).unwrap())
.collect::<Vec<_>>()
}