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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
|
--- a/src/core/processing.h
+++ b/src/core/processing.h
@@ -136,6 +136,10 @@ struct generic_seq_args {
#endif
};
+#ifdef __cplusplus
+extern "C" {
+#endif
+
gpointer generic_sequence_worker(gpointer p);
gboolean end_generic_sequence(gpointer p);
@@ -184,4 +188,8 @@ gpointer generic_sequence_metadata_worker(gpointer args);
void kill_child_process(gboolean on_exit);
+#ifdef __cplusplus
+}
+#endif
+
#endif
--- a/src/filters/da3d/DA3D.cpp
+++ b/src/filters/da3d/DA3D.cpp
@@ -15,10 +15,8 @@
#include "WeightMap.hpp"
#include "Utils.hpp"
#include "DftPatch.hpp"
-extern "C" {
#include "core/processing.h"
#include "gui/progress_and_log.h"
-}
#ifdef _OPENMP
#include <omp.h>
--- a/src/filters/nlbayes/NlBayes.cpp
+++ b/src/filters/nlbayes/NlBayes.cpp
@@ -27,11 +27,9 @@
#include "LibMatrix.h"
#include "LibImages.h"
#include "Utilities.h"
-extern "C" {
#include "algos/anscombe.h"
#include "core/processing.h"
#include "gui/progress_and_log.h"
-}
#ifdef _OPENMP
#include <omp.h>
--- a/src/gui/progress_and_log.h
+++ b/src/gui/progress_and_log.h
@@ -10,6 +10,10 @@
#define PROGRESS_DONE 1.0 // fill the progress bar
#define PROGRESS_TEXT_RESET "" // reset the progress bar's text
+#ifdef __cplusplus
+extern "C" {
+#endif
+
void initialize_log_tags();
void gui_log_message(const char* msg, const char* color);
@@ -17,4 +21,8 @@ void set_progress_bar_data(const char *text, double percent);
void set_cursor_waiting(gboolean waiting);
void set_cursor(const gchar* cursor_name);
+#ifdef __cplusplus
+}
+#endif
+
#endif
--- a/src/opencv/opencv.h
+++ b/src/opencv/opencv.h
@@ -5,14 +5,15 @@
# include <config.h>
#endif
-#ifdef __cplusplus
-extern "C" {
-#endif
-
#include <stdint.h>
#include "registration/registration.h"
#include "registration/matching/misc.h"
#include "registration/matching/atpmatch.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#include "gui/progress_and_log.h"
WORD *fits_to_bgrbgr_ushort(fits *image);
|