dds import WIP
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
use std::time::SystemTime;
|
||||
|
||||
use gltf::Error;
|
||||
use gltf::{Document, Error};
|
||||
use gltf::mesh::util::{ReadJoints, ReadNormals, ReadPositions, ReadTangents, ReadTexCoords, ReadWeights};
|
||||
|
||||
use crate::vulkan::mesh::LoadError::{GltfError, MeshDataMissing, NoIndices};
|
||||
@@ -34,7 +34,7 @@ pub struct CPUMesh {
|
||||
pub name: Option<String>,
|
||||
}
|
||||
|
||||
pub fn load_mesh(mesh_path: &str, print_status: bool) -> Result<(Vec<CPUMesh>, Vec<gltf::image::Data>), LoadError> {
|
||||
pub fn load_mesh(mesh_path: &str, print_status: bool) -> Result<(Vec<CPUMesh>, Document), LoadError> {
|
||||
let mut start_time = None;
|
||||
let mut total_vertices = 0;
|
||||
let mut total_indices = 0;
|
||||
@@ -92,7 +92,7 @@ pub fn load_mesh(mesh_path: &str, print_status: bool) -> Result<(Vec<CPUMesh>, V
|
||||
println!("Finished loading file, total vertices: {}, total indices: {}", total_vertices, total_indices);
|
||||
}
|
||||
|
||||
Ok((meshes, textures))
|
||||
Ok((meshes, document))
|
||||
}
|
||||
|
||||
fn create_vertices(positions: Option<ReadPositions>,
|
||||
|
||||
Reference in New Issue
Block a user