Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
OpenWalnut
OpenWalnut Modules
Commits
39b39372
Commit
39b39372
authored
Jul 20, 2017
by
Alexander Wiebel
Browse files
[FIX] In C++11, shared_ptr can't be implicitly converted to a bool
parent
7187115b
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
+8
-8
FiberClusteringToolbox/src/gaussProcesses/detTract2GPConvert/WMDetTract2GPConvert.cpp
...aussProcesses/detTract2GPConvert/WMDetTract2GPConvert.cpp
+1
-1
TransferCalcToolbox/src/transferCalc/WMTransferCalc.cpp
TransferCalcToolbox/src/transferCalc/WMTransferCalc.cpp
+6
-6
Unmaintained/src/sliceContext/WMSliceContext.cpp
Unmaintained/src/sliceContext/WMSliceContext.cpp
+1
-1
No files found.
FiberClusteringToolbox/src/gaussProcesses/detTract2GPConvert/WMDetTract2GPConvert.cpp
View file @
39b39372
...
@@ -90,7 +90,7 @@ void WMDetTract2GPConvert::moduleMain()
...
@@ -90,7 +90,7 @@ void WMDetTract2GPConvert::moduleMain()
boost
::
shared_ptr
<
WDataSetDTI
>
tensors
=
m_tensorIC
->
getData
();
boost
::
shared_ptr
<
WDataSetDTI
>
tensors
=
m_tensorIC
->
getData
();
// Demain Wasserman said, using tensors is not realy worth its effort
// Demain Wasserman said, using tensors is not realy worth its effort
// bool dataValid = tracts && tensors;
// bool dataValid = tracts && tensors;
bool
dataValid
=
tracts
;
bool
dataValid
=
static_cast
<
bool
>
(
tracts
)
;
if
(
!
dataValid
)
if
(
!
dataValid
)
{
{
continue
;
continue
;
...
...
TransferCalcToolbox/src/transferCalc/WMTransferCalc.cpp
View file @
39b39372
...
@@ -378,14 +378,14 @@ void WMTransferCalc::moduleMain()
...
@@ -378,14 +378,14 @@ void WMTransferCalc::moduleMain()
bool
dataChanged
=
(
m_inputData
->
getData
()
!=
m_dataSet
);
bool
dataChanged
=
(
m_inputData
->
getData
()
!=
m_dataSet
);
bool
additionalData
=
(
m_inputFA
->
getData
()
!=
m_FAdataSet
);
bool
additionalData
=
(
m_inputFA
->
getData
()
!=
m_FAdataSet
);
bool
newDerivative
=
(
m_inputDerivation
->
getData
()
!=
m_deriDataSet
);
bool
newDerivative
=
(
m_inputDerivation
->
getData
()
!=
m_deriDataSet
);
bool
dataValid
=
(
m_dataSet
);
bool
dataValid
=
static_cast
<
bool
>
(
m_dataSet
);
m_DeriIsValid
=
(
m_deriDataSet
);
m_DeriIsValid
=
static_cast
<
bool
>
(
m_deriDataSet
);
m_FAisValid
=
(
m_FAdataSet
);
m_FAisValid
=
static_cast
<
bool
>
(
m_FAdataSet
);
if
(
dataChanged
)
// main data, compulsory
if
(
dataChanged
)
// main data, compulsory
{
{
m_dataSet
=
m_inputData
->
getData
();
m_dataSet
=
m_inputData
->
getData
();
dataValid
=
(
m_dataSet
);
dataValid
=
static_cast
<
bool
>
(
m_dataSet
);
debugLog
()
<<
"New Data!"
;
debugLog
()
<<
"New Data!"
;
if
(
!
dataValid
)
if
(
!
dataValid
)
...
@@ -409,7 +409,7 @@ void WMTransferCalc::moduleMain()
...
@@ -409,7 +409,7 @@ void WMTransferCalc::moduleMain()
if
(
newDerivative
)
// optional: dataset with derivated data
if
(
newDerivative
)
// optional: dataset with derivated data
{
{
m_deriDataSet
=
m_inputDerivation
->
getData
();
m_deriDataSet
=
m_inputDerivation
->
getData
();
m_DeriIsValid
=
(
m_deriDataSet
);
m_DeriIsValid
=
static_cast
<
bool
>
(
m_deriDataSet
);
debugLog
()
<<
"New Derivated Data!"
;
debugLog
()
<<
"New Derivated Data!"
;
if
(
!
m_DeriIsValid
)
if
(
!
m_DeriIsValid
)
...
@@ -444,7 +444,7 @@ void WMTransferCalc::moduleMain()
...
@@ -444,7 +444,7 @@ void WMTransferCalc::moduleMain()
if
(
additionalData
)
// optional: fractional anisotropy data
if
(
additionalData
)
// optional: fractional anisotropy data
{
{
m_FAdataSet
=
m_inputFA
->
getData
();
m_FAdataSet
=
m_inputFA
->
getData
();
m_FAisValid
=
(
m_FAdataSet
);
m_FAisValid
=
static_cast
<
bool
>
(
m_FAdataSet
);
debugLog
()
<<
"New FA Data!"
;
debugLog
()
<<
"New FA Data!"
;
if
(
!
m_FAisValid
)
if
(
!
m_FAisValid
)
...
...
Unmaintained/src/sliceContext/WMSliceContext.cpp
View file @
39b39372
...
@@ -126,7 +126,7 @@ void WMSliceContext::moduleMain()
...
@@ -126,7 +126,7 @@ void WMSliceContext::moduleMain()
// To query whether an input was updated, simply ask the input:
// To query whether an input was updated, simply ask the input:
bool
dataUpdated
=
m_fiberInput
->
updated
();
bool
dataUpdated
=
m_fiberInput
->
updated
();
boost
::
shared_ptr
<
const
WDataSetFibers
>
fibers
(
m_fiberInput
->
getData
()
);
boost
::
shared_ptr
<
const
WDataSetFibers
>
fibers
(
m_fiberInput
->
getData
()
);
bool
dataValid
=
fibers
;
bool
dataValid
=
static_cast
<
bool
>
(
fibers
)
;
if
(
!
(
dataValid
&&
dataUpdated
)
)
if
(
!
(
dataValid
&&
dataUpdated
)
)
{
{
...
...
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