mirror of
https://github.com/brunoherbelin/vimix.git
synced 2025-12-12 10:49:59 +01:00
pedantic clang compiler
This commit is contained in:
10
Recorder.cpp
10
Recorder.cpp
@@ -20,7 +20,7 @@
|
|||||||
|
|
||||||
#include "Recorder.h"
|
#include "Recorder.h"
|
||||||
|
|
||||||
// use glReadPixel or glGetTextImage ?
|
// use glReadPixel or glGetTextImage
|
||||||
// read pixels & pbo should be the fastest
|
// read pixels & pbo should be the fastest
|
||||||
// https://stackoverflow.com/questions/38140527/glreadpixels-vs-glgetteximage
|
// https://stackoverflow.com/questions/38140527/glreadpixels-vs-glgetteximage
|
||||||
#define USE_GLREADPIXEL
|
#define USE_GLREADPIXEL
|
||||||
@@ -139,7 +139,7 @@ const std::vector<std::string> VideoRecorder::profile_description {
|
|||||||
"x264enc pass=5 quantizer=18 speed-preset=4 ! video/x-h264, profile=high ! h264parse ! ",
|
"x264enc pass=5 quantizer=18 speed-preset=4 ! video/x-h264, profile=high ! h264parse ! ",
|
||||||
// Apple ProRes encoding parameters
|
// Apple ProRes encoding parameters
|
||||||
// pass=2
|
// pass=2
|
||||||
// cbr (0) – Constant Bitrate Encoding
|
// cbr (0) – Constant Bitrate Encoding
|
||||||
// quant (2) – Constant Quantizer
|
// quant (2) – Constant Quantizer
|
||||||
// pass1 (512) – VBR Encoding - Pass 1
|
// pass1 (512) – VBR Encoding - Pass 1
|
||||||
"avenc_prores bitrate=60000 pass=2 ! ",
|
"avenc_prores bitrate=60000 pass=2 ! ",
|
||||||
@@ -158,7 +158,7 @@ const std::vector<std::string> VideoRecorder::profile_description {
|
|||||||
|
|
||||||
|
|
||||||
VideoRecorder::VideoRecorder() : Recorder(), frame_buffer_(nullptr), width_(0), height_(0),
|
VideoRecorder::VideoRecorder() : Recorder(), frame_buffer_(nullptr), width_(0), height_(0),
|
||||||
recording_(false), pipeline_(nullptr), src_(nullptr), timestamp_(0), timeframe_(0), accept_buffer_(false)
|
recording_(false), accept_buffer_(false), pipeline_(nullptr), src_(nullptr), timeframe_(0), timestamp_(0)
|
||||||
{
|
{
|
||||||
// auto filename
|
// auto filename
|
||||||
std::string path = SystemToolkit::path_directory(Settings::application.record.path);
|
std::string path = SystemToolkit::path_directory(Settings::application.record.path);
|
||||||
@@ -410,7 +410,7 @@ std::string VideoRecorder::info()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// appsrc needs data and we should start sending
|
// appsrc needs data and we should start sending
|
||||||
void VideoRecorder::callback_need_data (GstAppSrc *src, guint length, gpointer p)
|
void VideoRecorder::callback_need_data (GstAppSrc *, guint , gpointer p)
|
||||||
{
|
{
|
||||||
// Log::Info("H264Recording callback_need_data");
|
// Log::Info("H264Recording callback_need_data");
|
||||||
VideoRecorder *rec = (VideoRecorder *)p;
|
VideoRecorder *rec = (VideoRecorder *)p;
|
||||||
@@ -420,7 +420,7 @@ void VideoRecorder::callback_need_data (GstAppSrc *src, guint length, gpointer p
|
|||||||
}
|
}
|
||||||
|
|
||||||
// appsrc has enough data and we can stop sending
|
// appsrc has enough data and we can stop sending
|
||||||
void VideoRecorder::callback_enough_data (GstAppSrc *src, gpointer p)
|
void VideoRecorder::callback_enough_data (GstAppSrc *, gpointer p)
|
||||||
{
|
{
|
||||||
// Log::Info("H264Recording callback_enough_data");
|
// Log::Info("H264Recording callback_enough_data");
|
||||||
VideoRecorder *rec = (VideoRecorder *)p;
|
VideoRecorder *rec = (VideoRecorder *)p;
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ class PNGRecorder : public Recorder
|
|||||||
public:
|
public:
|
||||||
|
|
||||||
PNGRecorder();
|
PNGRecorder();
|
||||||
void addFrame(FrameBuffer *frame_buffer, float);
|
void addFrame(FrameBuffer *frame_buffer, float) override;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -70,8 +70,8 @@ class VideoRecorder : public Recorder
|
|||||||
GstClockTime timestamp_;
|
GstClockTime timestamp_;
|
||||||
GstClockTime frame_duration_;
|
GstClockTime frame_duration_;
|
||||||
|
|
||||||
static void callback_need_data (GstAppSrc *src, guint length, gpointer user_data);
|
static void callback_need_data (GstAppSrc *, guint, gpointer user_data);
|
||||||
static void callback_enough_data (GstAppSrc *src, gpointer user_data);
|
static void callback_enough_data (GstAppSrc *, gpointer user_data);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
@@ -81,7 +81,7 @@ public:
|
|||||||
VideoRecorder();
|
VideoRecorder();
|
||||||
~VideoRecorder();
|
~VideoRecorder();
|
||||||
|
|
||||||
void addFrame(FrameBuffer *frame_buffer, float dt);
|
void addFrame(FrameBuffer *frame_buffer, float dt) override;
|
||||||
void stop() override;
|
void stop() override;
|
||||||
std::string info() override;
|
std::string info() override;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user