
# Objective Fix #18546 by adding a variant to `MergeMeshError`, for incompatible primitive topologies. ## Solution Made `MergeMeshError` into an enum with two variants; `IncompatibleVertexAttributes` and `IncompatiblePrimitiveTopology`. Added an if statement in `Mesh::merge` to check if the `primitive_topology` field of `self` matches `other`. Also renamed `MergeMeshError` to `MeshMergeError` to align with the two other `MeshSomethingError`'s. ## Testing Didn't do any.
639 B
639 B
title | pull_requests | |
---|---|---|
Rework `MergeMeshError` |
|
MergeMeshError
was reworked to account for the possibility of the meshes being merged having two different PrimitiveTopology
's, and was renamed to MeshMergeError
to align with the naming of other mesh errors.
- Users will need to rename
MergeMeshError
toMeshMergeError
- When handling
MergeMeshError
(nowMeshMergeError
), users will need to account for the newIncompatiblePrimitiveTopology
variant, as it has been changed from a struct to an enum Mesh::merge
now returnsResult<(), MeshMergeError>
instead of the previousResult<(), MergeMeshError>