weird old canvas version hanging around

This commit is contained in:
2020-02-04 19:56:43 -08:00
parent 4b8fffc6bf
commit bb5617420e
31749 changed files with 576 additions and 1220832 deletions

View File

@@ -32,7 +32,7 @@ use std::fs::File;
use std::io::Read;
use rusttype::{Font, PositionedGlyph, Scale, Rect, point, GlyphId};
use vulkano::pipeline::vertex::VertexDefinition;
use crate::canvas::{CanvasTextureHandle, CanvasImageHandle, CanvasFontHandle, CompiledGraphicsPipelineHandle};
use crate::canvas::{CanvasTextureHandle, CanvasImageHandle, CompiledGraphicsPipelineHandle, Handle};
use crate::canvas::shader::dynamic_vertex::RuntimeVertexDef;
@@ -72,6 +72,17 @@ pub trait Drawable {
}
}
/// Typed wrapper for a u32 font handle (index id)
#[derive(Clone, Debug, Default, PartialEq, Eq, Hash)]
pub struct CanvasFontHandle {
handle: u32
}
impl Handle for CanvasFontHandle {
fn get_handle(&self) -> u32 {
self.handle
}
}
/// Canvas state is used for storage of texture and image buffers in addition to vertex buffers