2024-12-28 18:36:05 -05:00
|
|
|
#![cfg_attr(target_arch = "spirv", no_std)]
|
|
|
|
|
|
2024-12-29 20:00:14 -05:00
|
|
|
use spirv_std::glam::{Mat4, Vec3, Vec4};
|
2024-12-28 18:36:05 -05:00
|
|
|
|
|
|
|
|
#[repr(C)]
|
|
|
|
|
#[derive(Clone)]
|
|
|
|
|
pub struct UniformBufferObject {
|
|
|
|
|
pub model: Mat4,
|
|
|
|
|
pub view: Mat4,
|
|
|
|
|
pub proj: Mat4,
|
2024-12-29 12:00:32 -05:00
|
|
|
pub model_color: Vec3,
|
2024-12-28 18:36:05 -05:00
|
|
|
}
|
2024-12-29 20:00:14 -05:00
|
|
|
|
|
|
|
|
#[repr(C)]
|
|
|
|
|
#[derive(Debug, Clone, Copy)]
|
|
|
|
|
pub struct PushConstants {
|
|
|
|
|
pub texture_size: Vec4,
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
unsafe impl bytemuck::Pod for PushConstants {}
|
|
|
|
|
unsafe impl bytemuck::Zeroable for PushConstants {}
|