mirror of
https://codeberg.org/icewind/vmdl.git
synced 2026-06-03 16:44:11 +02:00
tangents
This commit is contained in:
parent
9e2ca40d29
commit
922699a089
5 changed files with 60 additions and 6 deletions
|
|
@ -295,12 +295,14 @@ fn model_to_model(model: &Model, loader: &Loader, skin: usize) -> CpuModel {
|
|||
y: vertex.texture_coordinates[1],
|
||||
})
|
||||
.collect();
|
||||
let tangents: Vec<Vec4> = mesh.tangents().map(|tangent| tangent.into()).collect();
|
||||
|
||||
CpuMesh {
|
||||
positions: Positions::F32(positions),
|
||||
normals: Some(normals),
|
||||
uvs: Some(uvs),
|
||||
material_name: Some(texture.into()),
|
||||
tangents: Some(tangents),
|
||||
..Default::default()
|
||||
}
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue