fix vkCmdDrawMeshIndirect() validation using wrong type (#2581)

This commit is contained in:
Firestar99 2024-10-18 11:14:17 +02:00 committed by GitHub
parent 123eda1a3b
commit 552caad394
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -4738,7 +4738,7 @@ impl RawRecordingCommandBuffer {
})); }));
} }
} else { } else {
if size_of::<DrawIndirectCommand>() as DeviceSize > indirect_buffer.size() { if size_of::<DrawMeshTasksIndirectCommand>() as DeviceSize > indirect_buffer.size() {
return Err(Box::new(ValidationError { return Err(Box::new(ValidationError {
problem: "`draw_count` is 1, but `size_of::<DrawMeshTasksIndirectCommand>()` \ problem: "`draw_count` is 1, but `size_of::<DrawMeshTasksIndirectCommand>()` \
is greater than `indirect_buffer.size()`" is greater than `indirect_buffer.size()`"