Nebula
Loading...
Searching...
No Matches
Util::FourCC Class Reference

#include <fourcc.h>

Detailed Description

A four-character-code is a quasi-human-readable 32-bit-id.

Public Member Functions

 FourCC ()
 default constructor
 
constexpr FourCC (uint f)
 construct from 32-bit-value (e.g. FourCC('ABCD'))
 
 FourCC (const String &s)
 construct from string
 
bool operator== (const FourCC &rhs) const
 equality operator
 
bool operator!= (const FourCC &rhs) const
 inequality operator
 
bool operator< (const FourCC &rhs) const
 less-then operator
 
bool operator<= (const FourCC &rhs) const
 less-or-equal operator
 
bool operator> (const FourCC &rhs) const
 greater-then operator
 
bool operator>= (const FourCC &rhs) const
 greater-or-equal operator
 
bool IsValid () const
 return true if valid
 
void SetFromUInt (uint f)
 set from 32-bit-value
 
uint AsUInt () const
 get as 32-bit-value
 
void SetFromString (const String &s)
 set as string
 
String AsString () const
 get as string
 
uint32_t HashCode () const
 return a hashcode (just returns the fourcc)
 

Static Public Member Functions

static String ToString (const FourCC &f)
 convert fourcc to string
 
static FourCC FromString (const String &s)
 convert string to fourcc
 

Private Attributes

uint fourCC
 

Constructor & Destructor Documentation

◆ FourCC() [1/3]

Util::FourCC::FourCC ( )
inline

default constructor

◆ FourCC() [2/3]

Util::FourCC::FourCC ( uint f)
constexpr

construct from 32-bit-value (e.g. FourCC('ABCD'))

◆ FourCC() [3/3]

Util::FourCC::FourCC ( const String & s)
inline

construct from string

Member Function Documentation

◆ AsString()

String Util::FourCC::AsString ( ) const
inline

get as string

◆ AsUInt()

uint Util::FourCC::AsUInt ( ) const
inline

get as 32-bit-value

◆ FromString()

FourCC Util::FourCC::FromString ( const String & s)
inlinestatic

convert string to fourcc

◆ HashCode()

uint32_t Util::FourCC::HashCode ( ) const
inline

return a hashcode (just returns the fourcc)

◆ IsValid()

bool Util::FourCC::IsValid ( ) const
inline

return true if valid

◆ operator!=()

bool Util::FourCC::operator!= ( const FourCC & rhs) const
inline

inequality operator

◆ operator<()

bool Util::FourCC::operator< ( const FourCC & rhs) const
inline

less-then operator

◆ operator<=()

bool Util::FourCC::operator<= ( const FourCC & rhs) const
inline

less-or-equal operator

◆ operator==()

bool Util::FourCC::operator== ( const FourCC & rhs) const
inline

equality operator

◆ operator>()

bool Util::FourCC::operator> ( const FourCC & rhs) const
inline

greater-then operator

◆ operator>=()

bool Util::FourCC::operator>= ( const FourCC & rhs) const
inline

greater-or-equal operator

◆ SetFromString()

void Util::FourCC::SetFromString ( const String & s)
inline

set as string

◆ SetFromUInt()

void Util::FourCC::SetFromUInt ( uint f)
inline

set from 32-bit-value

◆ ToString()

String Util::FourCC::ToString ( const FourCC & f)
inlinestatic

convert fourcc to string

Member Data Documentation

◆ fourCC

uint Util::FourCC::fourCC
private

The documentation for this class was generated from the following file: