MistServer  2.5.3-Pro-19-gf5e75b1 ( Generic_64)
Data Structures | Functions | Variables
FLV Namespace Reference

This namespace holds all FLV-parsing related functionality. More...

Data Structures

class  Tag
 This class is used to hold, work with and get information about a single FLV tag. More...
 

Functions

bool check_header (char *header)
 Checks a FLV Header for validness. More...
 
bool is_header (char *header)
 Checks the first 3 bytes for the string "FLV". More...
 

Variables

std::string Error_Str = ""
 This variable is set if a problem is encountered while parsing the FLV. More...
 
char Header [13] = {'F', 'L', 'V', 0x01, 0x05, 0, 0, 0, 0x09, 0, 0, 0, 0}
 Holds the last FLV header parsed. More...
 
bool Parse_Error = false
 This variable is set to true if a problem is encountered while parsing the FLV. More...
 

Detailed Description

This namespace holds all FLV-parsing related functionality.

Function Documentation

bool FLV::check_header ( char *  header)

Checks a FLV Header for validness.

Returns true if the header is valid, false if the header is not. Not valid can mean:

  • Not starting with the string "FLV".
  • The DataOffset is not 9 bytes.
  • The PreviousTagSize is not 0 bytes.

Note that we see PreviousTagSize as part of the FLV header, not part of the tag header!

bool FLV::is_header ( char *  header)

Checks the first 3 bytes for the string "FLV".

Implementing a basic FLV header check, returning true if it is, false if not.

Variable Documentation

std::string FLV::Error_Str = ""

This variable is set if a problem is encountered while parsing the FLV.

char FLV::Header = {'F', 'L', 'V', 0x01, 0x05, 0, 0, 0, 0x09, 0, 0, 0, 0}

Holds the last FLV header parsed.

Defaults to a audio+video header on FLV version 0x01 if no header received yet.

bool FLV::Parse_Error = false

This variable is set to true if a problem is encountered while parsing the FLV.