summaryrefslogtreecommitdiffstats
path: root/src/ReedSolomon.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/ReedSolomon.h')
-rw-r--r--src/ReedSolomon.h30
1 files changed, 17 insertions, 13 deletions
diff --git a/src/ReedSolomon.h b/src/ReedSolomon.h
index d96a522..abcef62 100644
--- a/src/ReedSolomon.h
+++ b/src/ReedSolomon.h
@@ -1,6 +1,11 @@
/*
Copyright (C) 2005, 2006, 2007, 2008, 2009 Her Majesty the Queen in Right
of Canada (Communications Research Center Canada)
+
+ Copyright (C) 2016
+ Matthias P. Braendli, matthias.braendli@mpb.li
+
+ http://www.opendigitalradio.org
*/
/*
This file is part of ODR-DabMux.
@@ -19,34 +24,33 @@
along with ODR-DabMux. If not, see <http://www.gnu.org/licenses/>.
*/
-#ifndef _REEDSOLOMON
-#define _REEDSOLOMON
+#pragma once
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
+#include <stdlib.h>
class ReedSolomon
{
public:
- ReedSolomon(int N, int K, bool reverse = false,
+ ReedSolomon(int N, int K,
+ bool reverse = false,
int gfpoly = 0x11d, int firstRoot = 0, int primElem = 1);
- ReedSolomon(const ReedSolomon& clone);
- virtual ~ReedSolomon();
+ ReedSolomon(const ReedSolomon& other) = delete;
+ ReedSolomon operator=(const ReedSolomon& other) = delete;
+ ~ReedSolomon();
void setReverse(bool state);
- int encode(void* data, void* fec, unsigned long size);
- int encode(void* data, unsigned long size);
-
-protected:
- int myN;
- int myK;
+ int encode(void* data, void* fec, size_t size);
+ int encode(void* data, size_t size);
private:
+ int m_N;
+ int m_K;
+
void* rsData;
bool reverse;
};
-
-#endif // _REEDSOLOMON