OpenHantek
Toggle main menu visibility
Loading...
Searching...
No Matches
postprocessing.h
Go to the documentation of this file.
1
// SPDX-License-Identifier: GPL-2.0-or-later
2
3
#pragma once
4
5
#include "
dsosamples.h
"
6
#include "
processor.h
"
7
8
#include <memory>
9
#include <vector>
10
11
#include <QDebug>
12
#include <QObject>
13
#include <QThread>
14
20
class
PostProcessing
:
public
QObject {
21
Q_OBJECT
22
23
public
:
24
explicit
PostProcessing
(
ChannelID
channelCount
,
int
verboseLevel
= 0 );
31
void
registerProcessor
(
Processor
*processor );
32
void
stop
() {
processing
=
false
; }
33
34
35
private
:
37
const
unsigned
channelCount
;
39
std::vector< Processor * >
processors
;
41
std::unique_ptr< PPresult >
currentData
;
42
static
void
convertData
(
const
DSOsamples
*source,
PPresult
*destination );
43
bool
processing
=
true
;
44
int
verboseLevel
= 0;
45
46
public
slots:
52
void
input
(
const
DSOsamples
*data );
53
54
signals:
55
void
processingFinished
( std::shared_ptr< PPresult > result );
56
};
57
58
Q_DECLARE_METATYPE( std::shared_ptr< PPresult > )
PPresult
Post processing results.
Definition
ppresult.h:43
PostProcessing::verboseLevel
int verboseLevel
Definition
postprocessing.h:44
PostProcessing::channelCount
const unsigned channelCount
A new PPresult is created for each new input. We need to know the channel size.
Definition
postprocessing.h:37
PostProcessing::registerProcessor
void registerProcessor(Processor *processor)
Definition
postprocessing.cpp:11
PostProcessing::input
void input(const DSOsamples *data)
Definition
postprocessing.cpp:47
PostProcessing::processors
std::vector< Processor * > processors
The list of processors. Processors are not memory managed by this class.
Definition
postprocessing.h:39
PostProcessing::processingFinished
void processingFinished(std::shared_ptr< PPresult > result)
PostProcessing::convertData
static void convertData(const DSOsamples *source, PPresult *destination)
Definition
postprocessing.cpp:15
PostProcessing::currentData
std::unique_ptr< PPresult > currentData
Definition
postprocessing.h:41
PostProcessing::stop
void stop()
Definition
postprocessing.h:32
PostProcessing::processing
bool processing
Definition
postprocessing.h:43
PostProcessing::PostProcessing
PostProcessing(ChannelID channelCount, int verboseLevel=0)
Definition
postprocessing.cpp:5
Processor
Definition
processor.h:7
dsosamples.h
processor.h
DSOsamples
Definition
dsosamples.h:11
ChannelID
unsigned ChannelID
Definition
types.h:6
post
postprocessing.h
Generated by
1.17.0