Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
OpenWalnut Core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
44
Issues
44
List
Boards
Labels
Service Desk
Milestones
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
OpenWalnut
OpenWalnut Core
Commits
c2e8b349
Commit
c2e8b349
authored
May 06, 2011
by
Sebastian Eichelbaum
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[CHANGE] - removed old colormapping. Removed NavSlices and ported Marching Cubes.
parent
f5c767e8
Changes
52
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
52 changed files
with
69 additions
and
5015 deletions
+69
-5015
src/dataHandler/WDataHandler.cpp
src/dataHandler/WDataHandler.cpp
+0
-10
src/dataHandler/WDataHandler.h
src/dataHandler/WDataHandler.h
+0
-18
src/dataHandler/WDataSet.cpp
src/dataHandler/WDataSet.cpp
+0
-18
src/dataHandler/WDataSet.h
src/dataHandler/WDataSet.h
+0
-18
src/dataHandler/WDataSetSingle.cpp
src/dataHandler/WDataSetSingle.cpp
+0
-8
src/dataHandler/WDataSetSingle.h
src/dataHandler/WDataSetSingle.h
+0
-13
src/dataHandler/WDataTexture3D.cpp
src/dataHandler/WDataTexture3D.cpp
+0
-571
src/dataHandler/WDataTexture3D.h
src/dataHandler/WDataTexture3D.h
+0
-379
src/dataHandler/WSubject.cpp
src/dataHandler/WSubject.cpp
+0
-46
src/dataHandler/WSubject.h
src/dataHandler/WSubject.h
+0
-10
src/gui/qt4/CMakeLists.txt
src/gui/qt4/CMakeLists.txt
+0
-1
src/gui/qt4/WMainWindow.cpp
src/gui/qt4/WMainWindow.cpp
+19
-24
src/gui/qt4/WMainWindow.h
src/gui/qt4/WMainWindow.h
+2
-0
src/gui/qt4/controlPanel/WQtControlPanel.cpp
src/gui/qt4/controlPanel/WQtControlPanel.cpp
+0
-25
src/gui/qt4/controlPanel/WQtControlPanel.h
src/gui/qt4/controlPanel/WQtControlPanel.h
+0
-10
src/gui/qt4/controlPanel/WQtTextureSorter.cpp
src/gui/qt4/controlPanel/WQtTextureSorter.cpp
+0
-283
src/gui/qt4/controlPanel/WQtTextureSorter.h
src/gui/qt4/controlPanel/WQtTextureSorter.h
+0
-121
src/kernel/CMakeLists.txt
src/kernel/CMakeLists.txt
+0
-1
src/kernel/WModuleFactory.cpp
src/kernel/WModuleFactory.cpp
+0
-2
src/kernel/WSelectionManager.cpp
src/kernel/WSelectionManager.cpp
+0
-5
src/kernel/WSelectionManager.h
src/kernel/WSelectionManager.h
+0
-6
src/kernel/modules/data/WMData.cpp
src/kernel/modules/data/WMData.cpp
+6
-130
src/kernel/modules/data/WMData.h
src/kernel/modules/data/WMData.h
+0
-55
src/kernel/modules/navSlices/WMNavSlices.cpp
src/kernel/modules/navSlices/WMNavSlices.cpp
+0
-1329
src/kernel/modules/navSlices/WMNavSlices.h
src/kernel/modules/navSlices/WMNavSlices.h
+0
-436
src/kernel/modules/navSlices/navslices.png
src/kernel/modules/navSlices/navslices.png
+0
-0
src/kernel/modules/navSlices/navslices.xpm
src/kernel/modules/navSlices/navslices.xpm
+0
-78
src/kernel/modules/navSlices/shaders/WMNavSlices-fragment.glsl
...ernel/modules/navSlices/shaders/WMNavSlices-fragment.glsl
+0
-153
src/kernel/modules/navSlices/shaders/WMNavSlices-vertex.glsl
src/kernel/modules/navSlices/shaders/WMNavSlices-vertex.glsl
+0
-47
src/modules/clusterDisplayVoxels/WMClusterDisplayVoxels.h
src/modules/clusterDisplayVoxels/WMClusterDisplayVoxels.h
+0
-1
src/modules/directVolumeRendering/WMDirectVolumeRendering.cpp
...modules/directVolumeRendering/WMDirectVolumeRendering.cpp
+0
-1
src/modules/effectiveConnectivityCluster/WMEffectiveConnectivityCluster.cpp
...iveConnectivityCluster/WMEffectiveConnectivityCluster.cpp
+0
-1
src/modules/fiberDisplay/WMFiberDisplay.cpp
src/modules/fiberDisplay/WMFiberDisplay.cpp
+1
-61
src/modules/fiberDisplay/WMFiberDisplay.h
src/modules/fiberDisplay/WMFiberDisplay.h
+0
-15
src/modules/fiberDisplaySimple/WMFiberDisplaySimple.cpp
src/modules/fiberDisplaySimple/WMFiberDisplaySimple.cpp
+0
-1
src/modules/fiberParameterColoring/WMFiberParameterColoring.cpp
...dules/fiberParameterColoring/WMFiberParameterColoring.cpp
+0
-1
src/modules/imageExtractor/WMImageExtractor.cpp
src/modules/imageExtractor/WMImageExtractor.cpp
+0
-58
src/modules/marchingCubes/WMMarchingCubes.cpp
src/modules/marchingCubes/WMMarchingCubes.cpp
+12
-216
src/modules/marchingCubes/WMMarchingCubes.h
src/modules/marchingCubes/WMMarchingCubes.h
+0
-23
src/modules/marchingCubes/shaders/WMMarchingCubes-fragment.glsl
...dules/marchingCubes/shaders/WMMarchingCubes-fragment.glsl
+14
-107
src/modules/marchingCubes/shaders/WMMarchingCubes-vertex.glsl
...modules/marchingCubes/shaders/WMMarchingCubes-vertex.glsl
+9
-19
src/modules/modules-base.toolbox
src/modules/modules-base.toolbox
+2
-2
src/modules/modules-others.toolbox
src/modules/modules-others.toolbox
+3
-4
src/modules/navigationSlices/WMNavigationSlices.cpp
src/modules/navigationSlices/WMNavigationSlices.cpp
+1
-1
src/modules/probTractDisplaySP/WMProbTractDisplaySP.cpp
src/modules/probTractDisplaySP/WMProbTractDisplaySP.cpp
+0
-1
src/modules/scalarOperator/WMScalarOperator.cpp
src/modules/scalarOperator/WMScalarOperator.cpp
+0
-1
src/modules/spatialDerivation/WMSpatialDerivation.cpp
src/modules/spatialDerivation/WMSpatialDerivation.cpp
+0
-1
src/modules/textureMapper/CMakeLists.txt
src/modules/textureMapper/CMakeLists.txt
+0
-46
src/modules/textureMapper/WMTextureMapper.cpp
src/modules/textureMapper/WMTextureMapper.cpp
+0
-214
src/modules/textureMapper/WMTextureMapper.h
src/modules/textureMapper/WMTextureMapper.h
+0
-153
src/modules/textureMapper/WMTextureMapper.xpm
src/modules/textureMapper/WMTextureMapper.xpm
+0
-290
src/modules/vectorOperator/WMVectorOperator.cpp
src/modules/vectorOperator/WMVectorOperator.cpp
+0
-1
No files found.
src/dataHandler/WDataHandler.cpp
View file @
c2e8b349
...
...
@@ -145,13 +145,3 @@ boost::shared_ptr< WSubject > WDataHandler::getDefaultSubject()
return
getDataHandler
()
->
getSubjectByID
(
WSubject
::
SUBJECT_UNKNOWN
);
}
void
WDataHandler
::
registerDataSet
(
boost
::
shared_ptr
<
WDataSet
>
dataset
)
{
getDefaultSubject
()
->
addDataSet
(
dataset
);
}
void
WDataHandler
::
deregisterDataSet
(
boost
::
shared_ptr
<
WDataSet
>
dataset
)
{
getDefaultSubject
()
->
removeDataSet
(
dataset
);
}
src/dataHandler/WDataHandler.h
View file @
c2e8b349
...
...
@@ -93,24 +93,6 @@ public:
*/
static
boost
::
shared_ptr
<
WDataHandler
>
getDataHandler
();
// TODO(all): the following two methods are only useful with our current single-subject stuff. You should consider redesigning
// it in conjunction with the multi subject stuff.
/**
* Register a dataset to the "UNKNOWN" subject. This is a convenience class which is useful as long as we do not have proper
* multi subject facilities.
*
* \param dataset the dataset to register.
*/
static
void
registerDataSet
(
boost
::
shared_ptr
<
WDataSet
>
dataset
);
/**
* Deregister a dataset to the "UNKNOWN" subject. This is a convenience class which is useful as long as we do not have proper
* multi subject facilities.
*
* \param dataset the dataset to deregister.
*/
static
void
deregisterDataSet
(
boost
::
shared_ptr
<
WDataSet
>
dataset
);
/**
* Insert a new subject referenced by a pointer.
*
...
...
src/dataHandler/WDataSet.cpp
View file @
c2e8b349
...
...
@@ -30,7 +30,6 @@
#include "exceptions/WDHException.h"
#include "WDataSet.h"
#include "WDataSetVector.h"
#include "WDataTexture3D.h"
#include "WDataTexture3D_2.h"
// prototype instance as singleton
...
...
@@ -61,11 +60,6 @@ bool WDataSet::isTexture() const
return
false
;
}
boost
::
shared_ptr
<
WDataTexture3D
>
WDataSet
::
getTexture
()
{
throw
WDHException
(
std
::
string
(
"This dataset does not provide a texture."
)
);
}
osg
::
ref_ptr
<
WDataTexture3D_2
>
WDataSet
::
getTexture2
()
const
{
throw
WDHException
(
std
::
string
(
"This dataset does not provide a texture."
)
);
...
...
@@ -91,18 +85,6 @@ boost::shared_ptr< WPrototyped > WDataSet::getPrototype()
return
m_prototype
;
}
boost
::
shared_ptr
<
WCondition
>
WDataSet
::
getChangeCondition
()
{
// this just forwards to the texture condition. In the future maybe datasets may also change so we need an separate condition in every
// dataset.
if
(
isTexture
()
)
{
return
getTexture
()
->
getChangeCondition
();
}
return
boost
::
shared_ptr
<
WCondition
>
();
}
boost
::
shared_ptr
<
WDataSetVector
>
WDataSet
::
isVectorDataSet
()
{
return
boost
::
shared_ptr
<
WDataSetVector
>
();
...
...
src/dataHandler/WDataSet.h
View file @
c2e8b349
...
...
@@ -38,7 +38,6 @@
#include "WDataTexture3D_2.h"
#include "WExportDataHandler.h"
class
WDataTexture3D
;
class
WCondition
;
class
WDataSetVector
;
...
...
@@ -92,15 +91,6 @@ public:
*/
virtual
boost
::
shared_ptr
<
WDataSetVector
>
isVectorDataSet
();
/**
* Returns the texture- representation of the dataset. May throw an exception if no texture is available.
*
* \return The texture.
* \deprecated
*/
OW_API_DEPRECATED
virtual
boost
::
shared_ptr
<
WDataTexture3D
>
getTexture
();
/**
* Returns the texture- representation of the dataset. May throw an exception if no texture is available.
*
...
...
@@ -130,14 +120,6 @@ public:
*/
static
boost
::
shared_ptr
<
WPrototyped
>
getPrototype
();
/**
* Gets the condition which is fired whenever the dataset gets some kind of dirty (threshold, opacity, ...)
*
* \return the condition, or NULL if the dataset has no texture.
* \deprecated this is deprecated. Use dataset properties instead.
*/
boost
::
shared_ptr
<
WCondition
>
getChangeCondition
();
/**
* Return a pointer to the properties object of the dataset. Add all the modifiable settings here. This allows the user to modify several
* properties of a dataset.
...
...
src/dataHandler/WDataSetSingle.cpp
View file @
c2e8b349
...
...
@@ -28,7 +28,6 @@
#include "../common/WAssert.h"
#include "../common/WException.h"
#include "../common/WPrototyped.h"
#include "WDataTexture3D.h"
#include "WDataTexture3D_2.h"
#include "WGrid.h"
#include "WGridRegular3D.h"
...
...
@@ -51,7 +50,6 @@ WDataSetSingle::WDataSetSingle( boost::shared_ptr< WValueSetBase > newValueSet,
m_valueSet
=
newValueSet
;
m_grid
=
newGrid
;
m_texture3D
=
boost
::
shared_ptr
<
WDataTexture3D
>
(
new
WDataTexture3D
(
m_valueSet
,
m_grid
)
);
m_infoProperties
->
addProperty
(
m_grid
->
getInformationProperties
()
);
...
...
@@ -67,7 +65,6 @@ WDataSetSingle::WDataSetSingle()
:
WDataSet
(),
m_grid
(),
m_valueSet
(),
m_texture3D
(),
m_texture
()
{
// default constructor used by the prototype mechanism
...
...
@@ -108,11 +105,6 @@ bool WDataSetSingle::isTexture() const
return
m_texture
;
}
boost
::
shared_ptr
<
WDataTexture3D
>
WDataSetSingle
::
getTexture
()
{
return
m_texture3D
;
}
osg
::
ref_ptr
<
WDataTexture3D_2
>
WDataSetSingle
::
getTexture2
()
const
{
return
m_texture
;
...
...
src/dataHandler/WDataSetSingle.h
View file @
c2e8b349
...
...
@@ -38,7 +38,6 @@
#include "WExportDataHandler.h"
class
WDataTexture3D
;
class
WDataTexture3D_2
;
/**
...
...
@@ -141,14 +140,6 @@ public:
*/
virtual
bool
isTexture
()
const
;
/**
* Returns the texture- representation of the dataset. May throw an exception if no texture is available.
*
* \return The texture.
* \deprecated
*/
virtual
boost
::
shared_ptr
<
WDataTexture3D
>
getTexture
();
/**
* Returns the texture representation of the dataset. May throw an exception if no texture is available.
*
...
...
@@ -195,10 +186,6 @@ protected:
boost
::
shared_ptr
<
WValueSetBase
>
m_valueSet
;
private:
/**
* The 3D texture representing this dataset.
*/
boost
::
shared_ptr
<
WDataTexture3D
>
m_texture3D
;
/**
* The 3D texture representing this dataset.
...
...
src/dataHandler/WDataTexture3D.cpp
deleted
100644 → 0
View file @
f5c767e8
This diff is collapsed.
Click to expand it.
src/dataHandler/WDataTexture3D.h
deleted
100644 → 0
View file @
f5c767e8
This diff is collapsed.
Click to expand it.
src/dataHandler/WSubject.cpp
View file @
c2e8b349
...
...
@@ -30,7 +30,6 @@
#include "../common/WLogger.h"
#include "WDataSet.h"
#include "WDataTexture3D.h"
#include "exceptions/WDHNoSuchDataSet.h"
#include "WSubject.h"
...
...
@@ -70,13 +69,6 @@ void WSubject::addDataSet( boost::shared_ptr< WDataSet > dataset )
{
// simply add the new dataset
m_datasets
.
push_back
(
dataset
);
// also register condition
boost
::
shared_ptr
<
WCondition
>
c
=
dataset
->
getChangeCondition
();
if
(
c
.
get
()
)
{
m_changeCondition
->
add
(
c
);
}
m_changeCondition
->
notify
();
m_listChangeCondition
->
notify
();
}
...
...
@@ -89,13 +81,6 @@ void WSubject::removeDataSet( boost::shared_ptr< WDataSet > dataset )
DatasetIterator
fIt
=
std
::
find
(
l
->
get
().
begin
(),
l
->
get
().
end
(),
dataset
);
l
->
get
().
erase
(
fIt
);
// also de-register condition
boost
::
shared_ptr
<
WCondition
>
c
=
dataset
->
getChangeCondition
();
if
(
c
.
get
()
)
{
m_changeCondition
->
remove
(
c
);
}
// unlock if some callback notified below wants to access the list
l
.
reset
();
...
...
@@ -106,17 +91,6 @@ void WSubject::removeDataSet( boost::shared_ptr< WDataSet > dataset )
void
WSubject
::
clear
()
{
DatasetSharedContainerType
::
WriteTicket
l
=
m_datasets
.
getWriteTicket
();
// iterate and find, remove
for
(
DatasetIterator
iter
=
l
->
get
().
begin
();
iter
!=
l
->
get
().
end
();
++
iter
)
{
// also de-register condition
boost
::
shared_ptr
<
WCondition
>
c
=
(
*
iter
)
->
getChangeCondition
();
if
(
c
.
get
()
)
{
m_changeCondition
->
remove
(
c
);
}
}
l
->
get
().
clear
();
// unlock if some callback notified below wants to access the list
...
...
@@ -135,26 +109,6 @@ WSubject::DatasetSharedContainerType::WriteTicket WSubject::getDatasetsForWritin
return
m_datasets
.
getWriteTicket
();
}
std
::
vector
<
boost
::
shared_ptr
<
WDataTexture3D
>
>
WSubject
::
getDataTextures
(
bool
onlyActive
)
{
std
::
vector
<
boost
::
shared_ptr
<
WDataTexture3D
>
>
tex
;
// Read lock the list, the lock is freed upon destruction of the ticket (if it goes out of scope for example).
DatasetSharedContainerType
::
ReadTicket
l
=
m_datasets
.
getReadTicket
();
// iterate the list and find all textures
for
(
DatasetConstIterator
iter
=
l
->
get
().
begin
();
iter
!=
l
->
get
().
end
();
++
iter
)
{
// is it a texture?
if
(
(
*
iter
)
->
isTexture
()
&&
(
!
onlyActive
||
(
*
iter
)
->
getTexture
()
->
isGloballyActive
()
)
)
{
tex
.
push_back
(
(
*
iter
)
->
getTexture
()
);
}
}
return
tex
;
}
boost
::
shared_ptr
<
WCondition
>
WSubject
::
getChangeCondition
()
const
{
return
m_changeCondition
;
...
...
src/dataHandler/WSubject.h
View file @
c2e8b349
...
...
@@ -38,7 +38,6 @@
#include "WExportDataHandler.h"
class
WDataSet
;
class
WDataTexture3D
;
/**
* Container for all WDataSets belonging to one subject or patient.
...
...
@@ -144,15 +143,6 @@ public:
*/
DatasetSharedContainerType
::
WriteTicket
getDatasetsForWriting
()
const
;
/**
* This gives a list of data textures from all supporting datasets in this subject.
*
* \param onlyActive true whenever only textures should be returned where isGloballyActive() == true.
* \return the list of textures.
* \deprecated
*/
std
::
vector
<
boost
::
shared_ptr
<
WDataTexture3D
>
>
getDataTextures
(
bool
onlyActive
=
false
);
/**
* This condition fires whenever the list of datasets changes, or one dataset got marked as "dirty" (threshold, opacity, ...).
*
...
...
src/gui/qt4/CMakeLists.txt
View file @
c2e8b349
...
...
@@ -35,7 +35,6 @@ SET(GUI_QT4_MOC_HDRS
controlPanel/WQtPropertyGroupWidget.h
controlPanel/WQtTreeWidget.h
controlPanel/WQtTreeItem.h
controlPanel/WQtTextureSorter.h
controlPanel/WQtColormapper.h
networkEditor/WQtNetworkEditor.h
networkEditor/WQtNetworkScene.h
...
...
src/gui/qt4/WMainWindow.cpp
View file @
c2e8b349
...
...
@@ -56,7 +56,6 @@
#include "../../graphicsEngine/WGEZoomTrackballManipulator.h"
#include "../../graphicsEngine/WROIBox.h"
#include "../../kernel/modules/data/WMData.h"
#include "../../kernel/modules/navSlices/WMNavSlices.h"
#include "../../kernel/WKernel.h"
#include "../../kernel/WModule.h"
#include "../../kernel/WModuleCombiner.h"
...
...
@@ -83,7 +82,8 @@
WMainWindow
::
WMainWindow
()
:
QMainWindow
(),
m_currentCompatiblesToolbar
(
NULL
),
m_iconManager
()
m_iconManager
(),
m_navSlicesAlreadyLoaded
(
false
)
{
}
...
...
@@ -131,12 +131,8 @@ void WMainWindow::setupGUI()
addDockWidget
(
Qt
::
RightDockWidgetArea
,
m_networkEditor
);
tabifyDockWidget
(
m_networkEditor
,
m_controlPanel
->
getModuleDock
()
);
// { TODO(all): deprecated. Replaced by WQtColormapper
addDockWidget
(
Qt
::
RightDockWidgetArea
,
m_controlPanel
->
getTextureSorterDock
()
);
// }
addDockWidget
(
Qt
::
RightDockWidgetArea
,
m_controlPanel
->
getColormapperDock
()
);
addDockWidget
(
Qt
::
RightDockWidgetArea
,
m_controlPanel
->
getRoiDock
()
);
tabifyDockWidget
(
m_controlPanel
->
getTextureSorterDock
(),
m_controlPanel
->
getColormapperDock
()
);
tabifyDockWidget
(
m_controlPanel
->
getColormapperDock
(),
m_controlPanel
->
getRoiDock
()
);
addDockWidget
(
Qt
::
RightDockWidgetArea
,
m_controlPanel
);
...
...
@@ -429,11 +425,10 @@ void WMainWindow::moduleSpecificSetup( boost::shared_ptr< WModule > module )
{
// it is a dataset single
// load a nav slice module if a WDataSetSingle is available!?
// if it not already is running: add it
if
(
!
WMNavSlices
::
isRunning
()
)
if
(
!
m_navSlicesAlreadyLoaded
)
{
autoAdd
(
module
,
"Navigation Slices"
);
m_navSlicesAlreadyLoaded
=
true
;
}
}
else
if
(
dataModule
->
getDataSet
()
->
isA
<
WDataSetFibers
>
()
)
...
...
@@ -451,11 +446,11 @@ void WMainWindow::moduleSpecificSetup( boost::shared_ptr< WModule > module )
// nav slices use separate buttons for slice on/off switching
if
(
module
->
getName
()
==
"Navigation Slices"
)
{
boost
::
shared_ptr
<
WPropertyBase
>
prop
=
module
->
getProperties
()
->
findProperty
(
"
show
Axial"
);
boost
::
shared_ptr
<
WPropertyBase
>
prop
=
module
->
getProperties
()
->
findProperty
(
"
Show
Axial"
);
if
(
!
prop
)
{
WLogger
::
getLogger
()
->
addLogMessage
(
"Navigation Slices module does not provide the property
\"
show
Axial
\"
, which is required by the GUI."
,
"GUI"
,
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Show
Axial
\"
, which is required by the GUI."
,
"GUI"
,
LL_ERROR
);
}
else
...
...
@@ -468,11 +463,11 @@ void WMainWindow::moduleSpecificSetup( boost::shared_ptr< WModule > module )
propertyActionMap
[
prop
]
=
a
;
}
prop
=
module
->
getProperties
()
->
findProperty
(
"
show
Coronal"
);
prop
=
module
->
getProperties
()
->
findProperty
(
"
Show
Coronal"
);
if
(
!
prop
)
{
WLogger
::
getLogger
()
->
addLogMessage
(
"Navigation Slices module does not provide the property
\"
show
Coronal
\"
, which is required by the GUI."
,
"GUI"
,
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Show
Coronal
\"
, which is required by the GUI."
,
"GUI"
,
LL_ERROR
);
}
else
...
...
@@ -485,11 +480,11 @@ void WMainWindow::moduleSpecificSetup( boost::shared_ptr< WModule > module )
propertyActionMap
[
prop
]
=
a
;
}
prop
=
module
->
getProperties
()
->
findProperty
(
"
show
Sagittal"
);
prop
=
module
->
getProperties
()
->
findProperty
(
"
Show
Sagittal"
);
if
(
!
prop
)
{
WLogger
::
getLogger
()
->
addLogMessage
(
"Navigation Slices module does not provide the property
\"
show
Sagittal
\"
, which is required by the GUI."
,
"GUI"
,
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Show
Sagittal
\"
, which is required by the GUI."
,
"GUI"
,
LL_ERROR
);
}
else
...
...
@@ -503,48 +498,48 @@ void WMainWindow::moduleSpecificSetup( boost::shared_ptr< WModule > module )
}
// now setup the nav widget sliders
prop
=
module
->
getProperties
()
->
findProperty
(
"Axial
Slice
"
);
prop
=
module
->
getProperties
()
->
findProperty
(
"Axial
Position
"
);
if
(
!
prop
)
{
WLogger
::
getLogger
()
->
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Axial
Slice
\"
, which is required by the GUI."
,
"GUI"
,
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Axial
Position
\"
, which is required by the GUI."
,
"GUI"
,
LL_ERROR
);
}
else
{
if
(
m_navAxial
)
{
m_navAxial
->
setSliderProperty
(
prop
);
//
m_navAxial->setSliderProperty( prop );
}
}
prop
=
module
->
getProperties
()
->
findProperty
(
"Coronal
Slice
"
);
prop
=
module
->
getProperties
()
->
findProperty
(
"Coronal
Position
"
);
if
(
!
prop
)
{
WLogger
::
getLogger
()
->
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Coronal
Slice
\"
, which is required by the GUI."
,
"GUI"
,
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Coronal
Position
\"
, which is required by the GUI."
,
"GUI"
,
LL_ERROR
);
}
else
{
if
(
m_navCoronal
)
{
m_navCoronal
->
setSliderProperty
(
prop
);
//
m_navCoronal->setSliderProperty( prop );
}
}
prop
=
module
->
getProperties
()
->
findProperty
(
"Sagittal
Slice
"
);
prop
=
module
->
getProperties
()
->
findProperty
(
"Sagittal
Position
"
);
if
(
!
prop
)
{
WLogger
::
getLogger
()
->
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Sagittal
Slice
\"
, which is required by the GUI."
,
"GUI"
,
addLogMessage
(
"Navigation Slices module does not provide the property
\"
Sagittal
Position
\"
, which is required by the GUI."
,
"GUI"
,
LL_ERROR
);
}
else
{
if
(
m_navSagittal
)
{
m_navSagittal
->
setSliderProperty
(
prop
);
//
m_navSagittal->setSliderProperty( prop );
}
}
}
...
...
src/gui/qt4/WMainWindow.h
View file @
c2e8b349
...
...
@@ -324,6 +324,8 @@ private:
*/
void
autoAdd
(
boost
::
shared_ptr
<
WModule
>
module
,
std
::
string
proto
);
bool
m_navSlicesAlreadyLoaded
;
//!< if true, the navslices have been loaded already
/**
* Map holding the actions for module properties added automatically. So they can be removed again automatically
* if the module is removed.
...
...
src/gui/qt4/controlPanel/WQtControlPanel.cpp
View file @
c2e8b349
...
...
@@ -58,7 +58,6 @@
#include "../WQtCombinerActionList.h"
#include "WQtBranchTreeItem.h"
#include "WQtControlPanel.h"
#include "WQtTextureSorter.h"
#include "WQtColormapper.h"
WQtControlPanel
::
WQtControlPanel
(
WMainWindow
*
parent
)
...
...
@@ -119,10 +118,6 @@ WQtControlPanel::WQtControlPanel( WMainWindow* parent )
m_mainWindow
->
getNetworkEditor
()
->
addAction
(
m_disconnectAction
);
m_mainWindow
->
getNetworkEditor
()
->
addAction
(
m_deleteModuleAction
);
// { TODO(all): deprecated. Replaced by WQtColormapper
m_textureSorter
=
new
WQtTextureSorter
(
m_mainWindow
);
m_textureSorter
->
setToolTip
(
"Reorder the textures."
);
// }
m_colormapper
=
new
WQtColormapper
(
m_mainWindow
);
m_colormapper
->
setToolTip
(
"Reorder the textures."
);
...
...
@@ -187,10 +182,6 @@ void WQtControlPanel::connectSlots()
connect
(
m_moduleTreeWidget
,
SIGNAL
(
itemClicked
(
QTreeWidgetItem
*
,
int
)
),
m_roiTreeWidget
,
SLOT
(
clearSelection
()
)
);
connect
(
m_roiTreeWidget
,
SIGNAL
(
itemClicked
(
QTreeWidgetItem
*
,
int
)
),
this
,
SLOT
(
selectRoiTreeItem
()
)
);
connect
(
m_roiTreeWidget
,
SIGNAL
(
itemClicked
(
QTreeWidgetItem
*
,
int
)
),
m_moduleTreeWidget
,
SLOT
(
clearSelection
()
)
);
// { TODO(all): deprecated. Replaced by WQtColormapper
connect
(
m_textureSorter
,
SIGNAL
(
textureSelectionChanged
(
boost
::
shared_ptr
<
WDataSet
>
)
),
this
,
SLOT
(
selectDataModule
(
boost
::
shared_ptr
<
WDataSet
>
)
)
);
// }
connect
(
m_colormapper
,
SIGNAL
(
textureSelectionChanged
(
osg
::
ref_ptr
<
WGETexture3D
>
)
),
this
,
SLOT
(
selectDataModule
(
osg
::
ref_ptr
<
WGETexture3D
>
)
)
);
connect
(
m_roiTreeWidget
,
SIGNAL
(
dragDrop
()
),
this
,
SLOT
(
handleDragDrop
()
)
);
...
...
@@ -213,14 +204,6 @@ WQtSubjectTreeItem* WQtControlPanel::addSubject( std::string name )
bool
WQtControlPanel
::
event
(
QEvent
*
event
)
{
// { TODO(all): deprecated. Replaced by WQtColormapper
// a subject signals a newly registered data set
if
(
event
->
type
()
==
WQT_UPDATE_TEXTURE_SORTER_EVENT
)
{
m_textureSorter
->
update
();
}
// }
if
(
event
->
type
()
==
WQT_ROI_ASSOC_EVENT
)
{
WRoiAssocEvent
*
e2
=
dynamic_cast
<
WRoiAssocEvent
*
>
(
event
);
// NOLINT
...
...
@@ -674,9 +657,6 @@ void WQtControlPanel::selectTreeItem()
{
if
(
dataModule
->
getDataSet
()
)
{
// { TODO(all): deprecated. Replaced by WQtColormapper
m_textureSorter
->
selectTexture
(
dataModule
->
getDataSet
()
);
// }
m_colormapper
->
selectTexture
(
dataModule
->
getDataSet
()
);
}
}
...
...
@@ -1142,11 +1122,6 @@ QDockWidget* WQtControlPanel::getModuleDock() const
return
m_moduleDock
;
}
QDockWidget
*
WQtControlPanel
::
getTextureSorterDock
()
const
{
return
m_textureSorter
;
}
QDockWidget
*
WQtControlPanel
::
getColormapperDock
()
const
{
return
m_colormapper
;
...
...
src/gui/qt4/controlPanel/WQtControlPanel.h
View file @
c2e8b349
...
...
@@ -46,7 +46,6 @@
#include "WQtRoiHeaderTreeItem.h"
#include "WQtSubjectTreeItem.h"
#include "WQtTreeWidget.h"
#include "WQtTextureSorter.h"
class
WMainWindow
;
class
WQtColormapper
;
...
...
@@ -190,13 +189,6 @@ public:
*/
QDockWidget
*
getModuleDock
()
const
;
/**
* Gets the texture sorter dock
*
* \return the dock
*/
QDockWidget
*
getTextureSorterDock
()
const
;
/**
* Gets the colormapper dock
*
...
...
@@ -259,8 +251,6 @@ private:
WQtTreeWidget
*
m_roiTreeWidget
;
//!< pointer to the tree widget
WQtTextureSorter
*
m_textureSorter
;
//!< pointer to the tree widget
WQtColormapper
*
m_colormapper
;
//!< the colormapper control widget
QTabWidget
*
m_tabWidget
;
//!< pointer to the tab widget
...
...
src/gui/qt4/controlPanel/WQtTextureSorter.cpp
deleted
100644 → 0
View file @
f5c767e8
//---------------------------------------------------------------------------
//
// Project: OpenWalnut ( http://www.openwalnut.org )
//
// Copyright 2009 OpenWalnut Community, BSV@Uni-Leipzig and CNCF@MPI-CBS
// For more information see http://www.openwalnut.org/copying
//
// This file is part of OpenWalnut.
//
// OpenWalnut is free software: you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// OpenWalnut is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with OpenWalnut. If not, see <http://www.gnu.org/licenses/>.
//
//---------------------------------------------------------------------------
#include <iostream>
#include <map>
#include <set>
#include <string>
#include <vector>
#include <algorithm>
#include <boost/bind.hpp>
#include <QtCore/QList>
#include <QtGui/QScrollArea>
#include <QtGui/QVBoxLayout>
#include <QtGui/QListWidgetItem>
#include "../../../common/WLimits.h"
#include "../../../dataHandler/WDataSet.h"
#include "../../../dataHandler/WSubject.h"
#include "../../../dataHandler/WDataHandler.h"
#include "../../../dataHandler/exceptions/WDHNoSuchSubject.h"
#include "../../../kernel/WModuleFactory.h"
#include "WQtTextureSorter.h"
WQtTextureSorter
::
WQtTextureSorter
(
QWidget
*
parent
)
:
QDockWidget
(
"Texture Sorter"
,
parent
)
{
setObjectName
(
"Texture Sorter Dock"
);
m_textureListWidget
=
new
QListWidget
(
this
);
m_textureListWidget
->
setToolTip
(
"List of available textures. Only the upper <b>"
+
QString
().
setNum
(
wlimits
::
MAX_NUMBER_OF_TEXTURES
)
+
"</b> textures will be applied."
);
this
->
setAllowedAreas
(
Qt
::
AllDockWidgetAreas
);
this
->
setFeatures
(
QDockWidget
::
DockWidgetClosable
|
QDockWidget
::
DockWidgetMovable
|
QDockWidget
::
DockWidgetFloatable
);
QWidget
*
panel
=
new
QWidget
(
this
);
m_layout
=
new
QVBoxLayout
();
QHBoxLayout
*
buttonLayout
=
new
QHBoxLayout
();
m_downButton
=
new
QPushButton
();
m_downButton
->
setText
(
QString
(
"down"
)
);
m_upButton
=
new
QPushButton
();
m_upButton
->
setText
(
QString
(
"up"
)
);
buttonLayout
->
addWidget
(
m_downButton
);
buttonLayout
->
addWidget
(
m_upButton
);
connect
(
m_upButton
,
SIGNAL
(
pressed
()
),
this
,
SLOT
(
moveItemUp
()
)
);
connect
(
m_downButton
,
SIGNAL
(
pressed
()
),
this
,
SLOT
(
moveItemDown
()
)
);
m_layout
->
addWidget
(
m_textureListWidget
);
m_layout
->
addLayout
(
buttonLayout
);
connect
(
m_textureListWidget
,
SIGNAL
(
itemClicked
(
QListWidgetItem
*
)
),
this
,
SLOT
(
handleTextureClicked
()
)
);
panel
->
setLayout
(
m_layout
);
setWidget
(
panel
);
}
WQtTextureSorter
::~
WQtTextureSorter
()