blob: 89957327b759836128beaec4a7aac0504a8509a5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
/*
* audio.h: A program for the Video Disk Recorder
*
* See the README file for copyright information and how to reach the author.
*
*/
#ifndef __audio_h_
#define __audio_h_
#include <netinet/in.h> // for htonl
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "global.h"
extern "C"
{
#include "debug.h"
}
#if 0
#include "audio_gain_analysis.h"
#endif
class cMarkAdAudio
{
private:
int lastiframe;
MarkAdContext *macontext;
MarkAdMark mark;
void ResetMark();
bool AddMark(int Type, int Position, const char *Comment);
#define CUT_VAL 10
#define MIN_LOWVALS 3
bool SilenceDetection();
int lastiframe_silence;
#if 0
#define ANALYZEFRAMES 1
int lastiframe_gain;
double lastgain;
cMarkAdAudioGainAnalysis audiogain;
bool AnalyzeGain();
#endif
int channels;
bool ChannelChange(int a, int b);
public:
cMarkAdAudio(MarkAdContext *maContext);
~cMarkAdAudio();
MarkAdMark *Process(int LastIFrame);
};
#endif
|