Unravel Engine C++ Reference
Loading...
Searching...
No Matches
format_bytes.h File Reference
#include <cstddef>
#include <cstdint>
#include <string>

Go to the source code of this file.

Namespaces

namespace  unravel
 

Functions

auto unravel::format_bytes (std::uint64_t bytes, std::uint8_t num_frac) -> std::string
 
auto unravel::format_bytes (std::int64_t bytes, std::uint8_t num_frac=2) -> std::string
 Signed overload; negative values are clamped to zero.
 
void unravel::format_bytes (std::uint64_t bytes, char *out, std::size_t out_size, std::uint8_t num_frac=2)
 Write a formatted byte string into out (NUL-terminated). No-op if out or out_size is zero.