OpenShot Library | libopenshot  0.3.3
Static Public Member Functions | Public Attributes | List of all members
openshot::Settings Class Reference

This class is contains settings used by libopenshot (and can be safely toggled at any point) More...

#include <Settings.h>

Static Public Member Functions

static SettingsInstance ()
 Create or get an instance of this logger singleton (invoke the class with this method) More...
 

Public Attributes

int DE_LIMIT_HEIGHT_MAX = 1100
 Maximum rows that hardware decode can handle. More...
 
int DE_LIMIT_WIDTH_MAX = 1950
 Maximum columns that hardware decode can handle. More...
 
bool DEBUG_TO_STDERR = false
 Whether to dump ZeroMQ debug messages to stderr. More...
 
bool ENABLE_PLAYBACK_CACHING = true
 Enable/Disable the cache thread to pre-fetch and cache video frames before we need them. More...
 
int FF_THREADS = 8
 Number of threads that ffmpeg uses. More...
 
int HARDWARE_DECODER = 0
 Use video codec for faster video decoding (if supported) More...
 
bool HIGH_QUALITY_SCALING = false
 Scale mode used in FFmpeg decoding and encoding (used as an optimization for faster previews) More...
 
int HW_DE_DEVICE_SET = 0
 Which GPU to use to decode (0 is the first) More...
 
int HW_EN_DEVICE_SET = 0
 Which GPU to use to encode (0 is the first) More...
 
int OMP_THREADS = 12
 Number of threads of OpenMP. More...
 
std::string PATH_OPENSHOT_INSTALL = ""
 
std::string PLAYBACK_AUDIO_DEVICE_NAME = ""
 The audio device name to use during playback. More...
 
std::string PLAYBACK_AUDIO_DEVICE_TYPE = ""
 The device type for the playback audio devices. More...
 
int VIDEO_CACHE_MAX_FRAMES = 30 * 10
 Max number of frames (when paused) to cache for playback. More...
 
int VIDEO_CACHE_MAX_PREROLL_FRAMES = 48
 Max number of frames (ahead of playhead) to cache during playback. More...
 
int VIDEO_CACHE_MIN_PREROLL_FRAMES = 24
 Minimum number of frames to cache before playback begins. More...
 
float VIDEO_CACHE_PERCENT_AHEAD = 0.7
 Percentage of cache in front of the playhead (0.0 to 1.0) More...
 

Detailed Description

This class is contains settings used by libopenshot (and can be safely toggled at any point)

Settings class is used primarily to toggle scale settings between preview and rendering, and adjust other runtime related settings.

Definition at line 26 of file Settings.h.

Member Function Documentation

◆ Instance()

Settings * Settings::Instance ( )
static

Create or get an instance of this logger singleton (invoke the class with this method)

Definition at line 23 of file Settings.cpp.

Referenced by openshot::ZmqLogger::AppendDebugMethod(), openshot::FFmpegReader::Open(), openshot::VideoCacheThread::run(), and openshot::Timeline::Timeline().

Member Data Documentation

◆ DE_LIMIT_HEIGHT_MAX

int openshot::Settings::DE_LIMIT_HEIGHT_MAX = 1100

Maximum rows that hardware decode can handle.

Definition at line 74 of file Settings.h.

Referenced by Instance().

◆ DE_LIMIT_WIDTH_MAX

int openshot::Settings::DE_LIMIT_WIDTH_MAX = 1950

Maximum columns that hardware decode can handle.

Definition at line 77 of file Settings.h.

Referenced by Instance().

◆ DEBUG_TO_STDERR

bool openshot::Settings::DEBUG_TO_STDERR = false

Whether to dump ZeroMQ debug messages to stderr.

Definition at line 111 of file Settings.h.

Referenced by Instance().

◆ ENABLE_PLAYBACK_CACHING

bool openshot::Settings::ENABLE_PLAYBACK_CACHING = true

Enable/Disable the cache thread to pre-fetch and cache video frames before we need them.

Definition at line 98 of file Settings.h.

Referenced by Instance(), and openshot::VideoCacheThread::run().

◆ FF_THREADS

int openshot::Settings::FF_THREADS = 8

Number of threads that ffmpeg uses.

Definition at line 71 of file Settings.h.

Referenced by Instance().

◆ HARDWARE_DECODER

int openshot::Settings::HARDWARE_DECODER = 0

Use video codec for faster video decoding (if supported)

0 - No acceleration, 1 - Linux VA-API, 2 - nVidia NVDEC, 3 - Windows D3D9, 4 - Windows D3D11, 5 - MacOS / VideoToolBox, 6 - Linux VDPAU, 7 - Intel QSV

Definition at line 62 of file Settings.h.

Referenced by Instance(), and openshot::FFmpegReader::Open().

◆ HIGH_QUALITY_SCALING

bool openshot::Settings::HIGH_QUALITY_SCALING = false

Scale mode used in FFmpeg decoding and encoding (used as an optimization for faster previews)

Definition at line 65 of file Settings.h.

Referenced by Instance().

◆ HW_DE_DEVICE_SET

int openshot::Settings::HW_DE_DEVICE_SET = 0

Which GPU to use to decode (0 is the first)

Definition at line 80 of file Settings.h.

Referenced by Instance(), and openshot::FFmpegReader::Open().

◆ HW_EN_DEVICE_SET

int openshot::Settings::HW_EN_DEVICE_SET = 0

Which GPU to use to encode (0 is the first)

Definition at line 83 of file Settings.h.

Referenced by Instance().

◆ OMP_THREADS

int openshot::Settings::OMP_THREADS = 12

Number of threads of OpenMP.

Definition at line 68 of file Settings.h.

Referenced by Instance().

◆ PATH_OPENSHOT_INSTALL

std::string openshot::Settings::PATH_OPENSHOT_INSTALL = ""

The current install path of OpenShot (needs to be set when using Timeline(path), since certain paths depend on the location of OpenShot transitions and files)

Definition at line 108 of file Settings.h.

Referenced by openshot::Timeline::Timeline().

◆ PLAYBACK_AUDIO_DEVICE_NAME

std::string openshot::Settings::PLAYBACK_AUDIO_DEVICE_NAME = ""

The audio device name to use during playback.

Definition at line 101 of file Settings.h.

Referenced by Instance().

◆ PLAYBACK_AUDIO_DEVICE_TYPE

std::string openshot::Settings::PLAYBACK_AUDIO_DEVICE_TYPE = ""

The device type for the playback audio devices.

Definition at line 104 of file Settings.h.

Referenced by Instance().

◆ VIDEO_CACHE_MAX_FRAMES

int openshot::Settings::VIDEO_CACHE_MAX_FRAMES = 30 * 10

Max number of frames (when paused) to cache for playback.

Definition at line 95 of file Settings.h.

Referenced by Instance(), and openshot::VideoCacheThread::run().

◆ VIDEO_CACHE_MAX_PREROLL_FRAMES

int openshot::Settings::VIDEO_CACHE_MAX_PREROLL_FRAMES = 48

Max number of frames (ahead of playhead) to cache during playback.

Definition at line 92 of file Settings.h.

Referenced by Instance(), and openshot::VideoCacheThread::run().

◆ VIDEO_CACHE_MIN_PREROLL_FRAMES

int openshot::Settings::VIDEO_CACHE_MIN_PREROLL_FRAMES = 24

Minimum number of frames to cache before playback begins.

Definition at line 89 of file Settings.h.

Referenced by Instance(), and openshot::VideoCacheThread::run().

◆ VIDEO_CACHE_PERCENT_AHEAD

float openshot::Settings::VIDEO_CACHE_PERCENT_AHEAD = 0.7

Percentage of cache in front of the playhead (0.0 to 1.0)

Definition at line 86 of file Settings.h.

Referenced by Instance(), and openshot::VideoCacheThread::run().


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