Skip to content
Snippets Groups Projects
Verified Commit d2fabd54 authored by Tobias Frisch's avatar Tobias Frisch
Browse files

[#56] Added warning to append method of push constants

parent be490a4e
No related branches found
No related tags found
1 merge request!45Resolve "Szene-Repräsentation"
Pipeline #26296 passed
......@@ -3,6 +3,8 @@
#include <vector>
#include <vulkan/vulkan.hpp>
#include "Logger.hpp"
namespace vkcv {
class PushConstants {
......@@ -48,6 +50,8 @@ namespace vkcv {
template<typename T = uint8_t>
bool appendDrawcall(const T& value) {
if (sizeof(T) != m_sizePerDrawcall) {
vkcv_log(LogLevel::WARNING, "Size (%lu) of value does not match the specified size per drawcall (%lu)",
sizeof(value), m_sizePerDrawcall);
return false;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment