SourcePP
Several modern C++20 libraries for sanely parsing Valve's formats.
Loading...
Searching...
No Matches
Binary.h File Reference
#include <cstddef>
#include <fstream>
#include <string>
#include <sourcepp/Math.h>
Include dependency graph for Binary.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  sourcepp
 
namespace  sourcepp::parser
 
namespace  sourcepp::parser::binary
 

Functions

consteval uint32_t sourcepp::parser::binary::makeFourCC (const char fourCC[4])
 Creates a FourCC identifier from a string of 4 characters.
 
void sourcepp::parser::binary::readStringAtOffset (BufferStream &stream, std::string &str, std::ios::seekdir offsetFrom=std::ios::cur, std::size_t subtractFromOffset=sizeof(int32_t))
 Reads an integer from the stream, seeks there, reads a string, and seeks back.