lyra-engine/src/render/render_job.rs

24 lines
582 B
Rust
Executable File

use edict::EntityId;
use crate::math::Transform;
pub struct RenderJob {
pub entity: EntityId,
pub shader_id: u64,
pub mesh_buffer_id: uuid::Uuid,
pub transform: Transform,
pub last_transform: Option<Transform>, // TODO: render interpolation
}
impl RenderJob {
pub fn new(entity: EntityId, shader_id: u64, mesh_buffer_id: uuid::Uuid, transform: Transform, last_transform: Option<Transform>) -> Self {
Self {
entity,
shader_id,
mesh_buffer_id,
transform,
last_transform,
}
}
}