MCPcopy Create free account
hub / github.com/OpenImageDebugger/OpenImageDebugger / export_octave_raw

Function export_octave_raw

src/io/buffer_export_core.cpp:247–275  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

245}
246
247bool export_octave_raw(const std::uint8_t* data,
248 const BufferType type,
249 const int width,
250 const int height,
251 const int channels,
252 const int step,
253 const std::string& path) {
254 using enum BufferType;
255 switch (type) {
256 case UnsignedByte:
257 return export_octave_impl<std::uint8_t>(
258 data, width, height, channels, step, path);
259 case UnsignedShort:
260 return export_octave_impl<std::uint16_t>(
261 data, width, height, channels, step, path);
262 case Short:
263 return export_octave_impl<std::int16_t>(
264 data, width, height, channels, step, path);
265 case Int32:
266 return export_octave_impl<std::int32_t>(
267 data, width, height, channels, step, path);
268 case Float32:
269 [[fallthrough]];
270 case Float64:
271 return export_octave_impl<float>(
272 data, width, height, channels, step, path);
273 }
274 return false;
275}
276
277} // namespace oid::BufferExporter

Callers 2

export_octaveFunction · 0.85
TESTFunction · 0.85

Calls

no outgoing calls

Tested by 1

TESTFunction · 0.68