Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Sbalzarini Lab
S
Software
P
Parallel Computing
OpenFPM
openfpm_io
Commits
ccf810ce
Commit
ccf810ce
authored
Jun 29, 2015
by
incardon
Browse files
Disabling randomized when on unit tests
parent
d267a896
Changes
5
Hide whitespace changes
Inline
Side-by-side
configure.ac
View file @
ccf810ce
...
...
@@ -73,6 +73,8 @@ if test x"$mem_check" = x"yes"; then
AC_DEFINE([MEMLEAK_CHECK],[],[Memory check])
fi
AC_DEFINE([ON_IO_UNIT_TESTS],[],[IO unit tests])
##### CHECK FOR BOOST ##############
AX_BOOST([1.52],[],[])
...
...
src/util.hpp
View file @
ccf810ce
...
...
@@ -5,6 +5,8 @@
* Author: Pietro Incardona
*/
#include "config.h"
#ifndef UTIL_HPP_
#define UTIL_HPP_
...
...
@@ -67,86 +69,80 @@ struct RGB getColor(int group, std::uniform_real_distribution<float> & d, std::d
{
struct
RGB
col
;
float
s
=
d
(
g
);
#ifdef ON_IO_UNIT_TESTS
s
=
0.5
;
#endif
if
(
group
==
0
)
{
float
s
=
d
(
g
);
col
.
R
=
s
/
2
+
0.5
;
col
.
G
=
0.0
;
col
.
B
=
0.0
;
}
else
if
(
group
==
1
)
{
float
s
=
d
(
g
);
col
.
R
=
0.0
;
col
.
G
=
s
/
2
+
0.5
;
col
.
B
=
0.0
;
}
else
if
(
group
==
2
)
{
float
s
=
d
(
g
);
col
.
R
=
0.0
;
col
.
G
=
0.0
;
col
.
B
=
s
;
}
else
if
(
group
==
3
)
{
float
s
=
d
(
g
);
col
.
R
=
s
/
2
+
0.5
;
col
.
G
=
s
/
2
+
0.5
;
col
.
B
=
0.0
;
}
else
if
(
group
==
4
)
{
float
s
=
d
(
g
);
col
.
R
=
s
/
2
+
0.5
;
col
.
G
=
0.0
;
col
.
B
=
s
/
2
+
0.5
;
}
else
if
(
group
==
5
)
{
float
s
=
d
(
g
);
col
.
R
=
0.0
;
col
.
G
=
s
/
2
+
0.5
;
col
.
B
=
s
/
2
+
0.5
;
}
else
if
(
group
==
6
)
{
float
s
=
d
(
g
);
col
.
R
=
s
/
2
+
0.5
;
col
.
G
=
s
/
4
+
0.5
;
col
.
B
=
0.0
;
}
else
if
(
group
==
7
)
{
float
s
=
d
(
g
);
col
.
R
=
s
/
4
+
0.5
;
col
.
G
=
s
/
2
+
0.5
;
col
.
B
=
0.0
;
}
else
if
(
group
==
8
)
{
float
s
=
d
(
g
);
col
.
R
=
0.0
;
col
.
G
=
s
/
2
+
0.5
;
col
.
B
=
s
/
4
+
0.5
;
}
else
if
(
group
==
9
)
{
float
s
=
d
(
g
);
col
.
R
=
0.0
;
col
.
G
=
s
/
4
+
0.5
;
col
.
B
=
s
/
2
+
0.5
;
}
else
if
(
group
==
10
)
{
float
s
=
d
(
g
);
col
.
R
=
s
/
4
+
0.5
;
col
.
G
=
0.0
;
col
.
B
=
s
/
2
+
0.5
;
}
else
if
(
group
==
11
)
{
float
s
=
d
(
g
);
col
.
R
=
s
/
2
+
0.5
;
col
.
G
=
0.0
;
col
.
B
=
s
/
4
+
0.5
;
...
...
vtk_box_3D_2_test.vtk
View file @
ccf810ce
...
...
@@ -129,17 +129,17 @@ CELL_TYPES 12
11
CELL_DATA 12
COLOR_SCALARS data 4
0.50000
4
0.000000 0.000000 1.0
0.
565769
0.000000 0.000000 1.0
0.
877803
0.000000 0.000000 1.0
0.7
29325
0.000000 0.000000 1.0
0.7
66384
0.000000 0.000000 1.0
0.
60948
0 0.000000 0.000000 1.0
0.
7
50000 0.000000 0.000000 1.0
0.
750000
0.000000 0.000000 1.0
0.
750000
0.000000 0.000000 1.0
0.7
50000
0.000000 0.000000 1.0
0.7
50000
0.000000 0.000000 1.0
0.
75000
0 0.000000 0.000000 1.0
0.000000 0.
523522
0.000000 1.0
0.000000 0.
839432
0.000000 1.0
0.000000 0.
839648
0.000000 1.0
0.000000 0.
967346
0.000000 1.0
0.000000 0.
691751
0.000000 1.0
0.000000 0.75
9708
0.000000 1.0
0.000000 0.
750000
0.000000 1.0
0.000000 0.
750000
0.000000 1.0
0.000000 0.
750000
0.000000 1.0
0.000000 0.
750000
0.000000 1.0
0.000000 0.
750000
0.000000 1.0
0.000000 0.75
0000
0.000000 1.0
vtk_box_3D_test.vtk
View file @
ccf810ce
...
...
@@ -68,10 +68,10 @@ CELL_TYPES 6
11
CELL_DATA 6
COLOR_SCALARS data 4
0.50000
4
0.000000 0.000000 1.0
0.
565769
0.000000 0.000000 1.0
0.
877803
0.000000 0.000000 1.0
0.7
29325
0.000000 0.000000 1.0
0.7
66384
0.000000 0.000000 1.0
0.
60948
0 0.000000 0.000000 1.0
0.
7
50000 0.000000 0.000000 1.0
0.
750000
0.000000 0.000000 1.0
0.
750000
0.000000 0.000000 1.0
0.7
50000
0.000000 0.000000 1.0
0.7
50000
0.000000 0.000000 1.0
0.
75000
0 0.000000 0.000000 1.0
vtk_box_test.vtk
View file @
ccf810ce
...
...
@@ -44,10 +44,10 @@ CELL_TYPES 6
8
CELL_DATA 6
COLOR_SCALARS data 4
0.50000
4
0.000000 0.000000 1.0
0.
565769
0.000000 0.000000 1.0
0.
877803
0.000000 0.000000 1.0
0.7
29325
0.000000 0.000000 1.0
0.7
66384
0.000000 0.000000 1.0
0.
60948
0 0.000000 0.000000 1.0
0.
7
50000 0.000000 0.000000 1.0
0.
750000
0.000000 0.000000 1.0
0.
750000
0.000000 0.000000 1.0
0.7
50000
0.000000 0.000000 1.0
0.7
50000
0.000000 0.000000 1.0
0.
75000
0 0.000000 0.000000 1.0
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment