MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ get_blob()

std::optional< std::vector< uint8_t > > MayaFlux::Core::InputValue::OSCMessage::get_blob ( size_t  index = 0) const
noexcept

Extract a blob argument by index.

Parameters
indexArgument index (0-based).
Returns
Raw bytes, or std::nullopt if out of range or wrong type.

Definition at line 163 of file InputBinding.cpp.

164{
165 if (index >= arguments.size())
166 return std::nullopt;
167 return std::visit([](const auto& v) -> std::optional<std::vector<uint8_t>> {
168 using T = std::decay_t<decltype(v)>;
169 if constexpr (std::is_same_v<T, std::vector<uint8_t>>)
170 return v;
171 return std::nullopt;
172 },
174}
uint32_t index
Definition VKDevice.cpp:142
std::vector< OSCArg > arguments
Typed arguments.

References index.