整理代码
This commit is contained in:
commit
c7b4e178ec
364 changed files with 59691 additions and 0 deletions
37
video/core/BitrateControl.cpp
Normal file
37
video/core/BitrateControl.cpp
Normal file
|
|
@ -0,0 +1,37 @@
|
|||
/*
|
||||
*******************************************************************************
|
||||
* INCLUDE
|
||||
*******************************************************************************
|
||||
*/
|
||||
#include "BitrateControl.h"
|
||||
#include <Poco/Format.h>
|
||||
|
||||
namespace Video
|
||||
{
|
||||
namespace Core
|
||||
{
|
||||
/*
|
||||
*******************************************************************************
|
||||
* LOCAL VARIABLES
|
||||
*******************************************************************************
|
||||
*/
|
||||
static const std::string _bcStrings[] = {
|
||||
"CBR", "VBR", "AVBR", "QVBR", "CVBR", "FIXQP", "QPMAP",
|
||||
};
|
||||
|
||||
/*
|
||||
*******************************************************************************
|
||||
* FUNCTIONS
|
||||
*******************************************************************************
|
||||
*/
|
||||
const std::string bitrateControlToString(BitrateControl bc)
|
||||
{
|
||||
unsigned index = (unsigned)bc;
|
||||
|
||||
if (index >= (unsigned)BitrateControl::NB)
|
||||
return Poco::format("UNKNOWN(%u)", index);
|
||||
|
||||
return _bcStrings[index];
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue