OpenShot Library | libopenshot 0.3.3
Loading...
Searching...
No Matches
openshot::WriterInfo Struct Reference

This struct contains info about encoding a media file, such as height, width, frames per second, etc... More...

#include <WriterBase.h>

Public Attributes

std::string acodec
 The name of the audio codec used to encode / decode the video stream.
 
int audio_bit_rate
 The bit rate of the audio stream (in bytes)
 
int audio_stream_index
 The index of the audio stream.
 
openshot::Fraction audio_timebase
 The audio timebase determines how long each audio packet should be played.
 
openshot::ChannelLayout channel_layout
 The channel layout (mono, stereo, 5 point surround, etc...)
 
int channels
 The number of audio channels used in the audio stream.
 
openshot::Fraction display_ratio
 The ratio of width to height of the video stream (i.e. 640x480 has a ratio of 4/3)
 
float duration
 Length of time (in seconds)
 
int64_t file_size
 Size of file (in bytes)
 
openshot::Fraction fps
 Frames per second, as a fraction (i.e. 24/1 = 24 fps)
 
bool has_audio
 Determines if this file has an audio stream.
 
bool has_single_image
 Determines if this file only contains a single image.
 
bool has_video
 Determines if this file has a video stream.
 
int height
 The height of the video (in pixels)
 
bool interlaced_frame
 Are the contents of this frame interlaced.
 
std::map< std::string, std::string > metadata
 An optional map/dictionary of video & audio metadata.
 
int pixel_format
 The pixel format (i.e. YUV420P, RGB24, etc...)
 
openshot::Fraction pixel_ratio
 The pixel ratio of the video stream as a fraction (i.e. some pixels are not square)
 
int sample_rate
 The number of audio samples per second (44100 is a common sample rate)
 
bool top_field_first
 Which interlaced field should be displayed first.
 
std::string vcodec
 The name of the video codec used to encode / decode the video stream.
 
int video_bit_rate
 The bit rate of the video stream (in bytes)
 
int64_t video_length
 The number of frames in the video stream.
 
int video_stream_index
 The index of the video stream.
 
openshot::Fraction video_timebase
 The video timebase determines how long each frame stays on the screen.
 
int width
 The width of the video (in pixels)
 

Detailed Description

This struct contains info about encoding a media file, such as height, width, frames per second, etc...

Each derived class of WriterBase is responsible for updating this struct to reflect accurate information about the streams.

Definition at line 32 of file WriterBase.h.

Member Data Documentation

◆ acodec

◆ audio_bit_rate

◆ audio_stream_index

int openshot::WriterInfo::audio_stream_index

◆ audio_timebase

openshot::Fraction openshot::WriterInfo::audio_timebase

The audio timebase determines how long each audio packet should be played.

Definition at line 58 of file WriterBase.h.

Referenced by openshot::WriterBase::CopyReaderInfo(), openshot::WriterBase::DisplayInfo(), openshot::WriterBase::JsonValue(), openshot::WriterBase::SetJsonValue(), and openshot::WriterBase::WriterBase().

◆ channel_layout

◆ channels

◆ display_ratio

◆ duration

◆ file_size

◆ fps

◆ has_audio

◆ has_single_image

bool openshot::WriterInfo::has_single_image

◆ has_video

◆ height

◆ interlaced_frame

◆ metadata

std::map<std::string, std::string> openshot::WriterInfo::metadata

An optional map/dictionary of video & audio metadata.

Definition at line 59 of file WriterBase.h.

Referenced by openshot::FFmpegWriter::WriteHeader().

◆ pixel_format

int openshot::WriterInfo::pixel_format

◆ pixel_ratio

◆ sample_rate

◆ top_field_first

◆ vcodec

◆ video_bit_rate

◆ video_length

int64_t openshot::WriterInfo::video_length

◆ video_stream_index

int openshot::WriterInfo::video_stream_index

◆ video_timebase

◆ width


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