Logo
ApraPipes 1.0
Loading...
Searching...
No Matches
H264EncoderV4L2.h
1#pragma once
2
3#include "Module.h"
4
6
8{
9public:
10 H264EncoderV4L2Props(bool _enableMotionVectors = false, int _motionVectorThreshold = 5): targetKbps(1024)
11 {
12 enableMotionVectors = _enableMotionVectors;
13 motionVectorThreshold = _motionVectorThreshold;
14 }
15
16 uint32_t targetKbps;
17 bool enableMotionVectors = false;
19};
20
21class H264EncoderV4L2 : public Module
22{
23
24public:
26 virtual ~H264EncoderV4L2();
27 bool init();
28 bool term();
29
30protected:
31 bool process(frame_container& frames);
32 bool processSOS(frame_sp& frame);
33 bool validateInputPins();
34 bool validateOutputPins();
35 bool shouldTriggerSOS();
36 bool processEOS(string& pinId);
37
38private:
39 std::shared_ptr<H264EncoderV4L2Helper> mHelper;
40
44};
Definition H264EncoderV4L2Helper.h:10
Definition H264EncoderV4L2.h:8
H264EncoderV4L2Props(bool _enableMotionVectors=false, int _motionVectorThreshold=5)
Definition H264EncoderV4L2.h:10
int motionVectorThreshold
Definition H264EncoderV4L2.h:18
bool enableMotionVectors
Definition H264EncoderV4L2.h:17
uint32_t targetKbps
Definition H264EncoderV4L2.h:16
Definition H264EncoderV4L2.h:22
std::shared_ptr< H264EncoderV4L2Helper > mHelper
Definition H264EncoderV4L2.h:39
bool term()
Definition H264EncoderV4L2.cpp:83
H264EncoderV4L2(H264EncoderV4L2Props props)
Definition H264EncoderV4L2.cpp:11
H264EncoderV4L2Props mProps
Definition H264EncoderV4L2.h:41
bool processSOS(frame_sp &frame)
Definition H264EncoderV4L2.cpp:96
std::string motionVectorFramePinId
Definition H264EncoderV4L2.h:42
bool validateOutputPins()
Definition H264EncoderV4L2.cpp:59
std::string h264FrameOutputPinId
Definition H264EncoderV4L2.h:43
virtual ~H264EncoderV4L2()
Definition H264EncoderV4L2.cpp:19
bool validateInputPins()
Definition H264EncoderV4L2.cpp:28
bool init()
Definition H264EncoderV4L2.cpp:73
bool processEOS(string &pinId)
Definition H264EncoderV4L2.cpp:163
bool shouldTriggerSOS()
Definition H264EncoderV4L2.cpp:158
bool process(frame_container &frames)
Definition H264EncoderV4L2.cpp:88
Definition Module.h:33
Definition Module.h:151