An FFmpeg based Record.
More...
#include <ffmpegRecord.h>
|
| FFmpegRecord (std::filesystem::path file, glm::ivec2 resolution, uint8_t fps, std::string preset="slow", std::string profile="high", uint8_t crf=0, uint8_t cq=0, uint8_t qp=0, std::string codecName="libx264", uint32_t max_b_frames=0, uint32_t gop_size=1, uint32_t bitrate=2000000) |
| Construct a new FFmpeg based Record from a file path, resolution and fps.
|
|
| ~FFmpegRecord () |
|
void | open () |
| Open the video file.
|
|
void | close () |
| Close the video file.
|
|
| Record (std::filesystem::path file, glm::ivec2 resolution, uint8_t fps) |
| Construct a new Record from a file path, resolution and fps.
|
|
virtual | ~Record () |
|
void | queueFrame (std::vector< uint8_t > pixels) |
| Enqueue a frame to be written.
|
|
uint8_t | queueSize () |
| Number of frames yet to be sent for writing.
|
|
uint64_t | framesLeft () |
| Number of frame left to be written in total.
|
|
void | writeFrames () |
| Send the frames in the buffer for writing.
|
|
bool | isWriting () const |
| If the video is being written to in the background.
|
|
bool | isOpen () const |
| If the file is open.
|
|
bool | finalise () |
| Check if finalised.
|
|
◆ FFmpegRecord()
FFmpegRecord::FFmpegRecord |
( |
std::filesystem::path |
file, |
|
|
glm::ivec2 |
resolution, |
|
|
uint8_t |
fps, |
|
|
std::string |
preset = "slow" , |
|
|
std::string |
profile = "high" , |
|
|
uint8_t |
crf = 0 , |
|
|
uint8_t |
cq = 0 , |
|
|
uint8_t |
qp = 0 , |
|
|
std::string |
codecName = "libx264" , |
|
|
uint32_t |
max_b_frames = 0 , |
|
|
uint32_t |
gop_size = 1 , |
|
|
uint32_t |
bitrate = 2000000 |
|
) |
| |
|
inline |
Construct a new FFmpeg based Record from a file path, resolution and fps.
- Parameters
-
file | the video file path. |
resolution | the resolution. |
fps | the frames per second. |
◆ ~FFmpegRecord()
FFmpegRecord::~FFmpegRecord |
( |
| ) |
|
|
inline |
◆ close()
void FFmpegRecord::close |
( |
| ) |
|
|
inlinevirtual |
Close the video file.
Implements Record.
◆ open()
void FFmpegRecord::open |
( |
| ) |
|
|
inlinevirtual |
Open the video file.
Implements Record.
The documentation for this class was generated from the following file: