refactoring the shader container. To Trait or not to Trait? Probably Trait

This commit is contained in:
2019-09-22 01:37:58 -07:00
parent 34c23eebc0
commit 3db8eaf006
6 changed files with 165 additions and 187 deletions

View File

@@ -16,7 +16,7 @@ use crate::canvas::canvas_frame::CanvasFrame;
use crate::compute::compu_kernel::{CompuKernel, CompuKernelHandle};
use crate::compute::compu_buffer::{CompuBuffers, CompuBufferHandle};
use std::time::Duration;
use crate::canvas::canvas_shader::CanvasShaderHandle;
use crate::canvas::canvas_shader::{CanvasShaderHandle, CompiledGraphicsPipeline, CompiledGraphicsPipelineHandle};
use vulkano::pipeline::depth_stencil::{DynamicStencilValue, StencilFaceFlags};
/// VKProcessor holds the vulkan instance information, the swapchain, and the compute and canvas states
@@ -171,7 +171,7 @@ impl<'a> VkProcessor<'a> {
}
/// O(n) Lookup for the matching shader string
pub fn get_shader_handle(&self, shader_name: String) -> Option<Arc<CanvasShaderHandle>> {
pub fn get_shader_handle(&self, shader_name: String) -> Option<Arc<CompiledGraphicsPipelineHandle>> {
self.canvas.get_shader_handle(shader_name)
}