From 1b196dc831e026e951c2804ec1ffba7867bf2e56 Mon Sep 17 00:00:00 2001 From: Quaternions Date: Tue, 12 Mar 2024 20:39:50 -0700 Subject: [PATCH] hash by rbx_mesh VertexId2 --- src/mesh.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mesh.rs b/src/mesh.rs index 8cda1fb..79ac9db 100644 --- a/src/mesh.rs +++ b/src/mesh.rs @@ -21,7 +21,7 @@ fn ingest_vertices2< mut acquire_normal_id:AcquireNormalId, mut acquire_color_id:AcquireColorId, mut acquire_vertex_id:AcquireVertexId, -)->Result,Error> +)->Result,Error> where AcquirePosId:FnMut([f32;3])->Result, AcquireTexId:FnMut([f32;2])->TextureCoordinateId, @@ -32,7 +32,7 @@ where //this monster is collecting a map of old_vertices_index -> unique_vertices_index //while also doing the inserting unique entries into lists simultaneously Ok(vertices.into_iter().enumerate().map(|(vertex_id,vertex)|Ok(( - VertexId::new(vertex_id as u32), + rbx_mesh::mesh::VertexId2(vertex_id as u32), acquire_vertex_id(IndexedVertex{ pos:acquire_pos_id(vertex.pos)?, tex:acquire_tex_id(vertex.tex), @@ -53,7 +53,7 @@ fn ingest_vertices_truncated2< mut acquire_normal_id:AcquireNormalId, static_color_id:ColorId,//pick one color and fill everything with it mut acquire_vertex_id:AcquireVertexId, -)->Result,Error> +)->Result,Error> where AcquirePosId:FnMut([f32;3])->Result, AcquireTexId:FnMut([f32;2])->TextureCoordinateId, @@ -63,7 +63,7 @@ where //this monster is collecting a map of old_vertices_index -> unique_vertices_index //while also doing the inserting unique entries into lists simultaneously Ok(vertices.into_iter().enumerate().map(|(vertex_id,vertex)|Ok(( - VertexId::new(vertex_id as u32), + rbx_mesh::mesh::VertexId2(vertex_id as u32), acquire_vertex_id(IndexedVertex{ pos:acquire_pos_id(vertex.pos)?, tex:acquire_tex_id(vertex.tex),