rust_vulkan_test/src/renderer/mod.rs

23 lines
570 B
Rust
Raw Normal View History

2024-12-08 18:19:37 +01:00
mod app;
mod pipelines;
2024-12-11 20:41:04 +01:00
mod render_context;
mod vertex;
2024-12-08 18:19:37 +01:00
pub use app::App;
pub use pipelines::create_triangle_pipeline;
2024-12-08 18:19:37 +01:00
mod scene;
pub use scene::Scene;
pub use vertex::Vertex2D;
2024-12-08 18:19:37 +01:00
2024-11-27 22:16:26 +01:00
use std::sync::Arc;
2024-12-08 18:19:37 +01:00
use vulkano::image::view::ImageView;
2024-12-11 20:41:04 +01:00
use vulkano::image::Image;
2024-11-27 21:27:50 +01:00
2024-12-08 18:19:37 +01:00
/// 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<_>>()
}