Skip to content
Commits on Source (73)
To fix issue #790288, we have chosen to restrict the package to amd64.
This could be changed in a close future.
fw4spl (14.0.0-1) unstable; urgency=medium
[ Flavien Bridault ]
* New upstream version
* d/p/: remove obsolete patches
Add patch to enable experimental GLM extension. Closes: #888932
* d/rules: update build options
[ Andreas Tille ]
* Standards-Version: 4.1.3
* debhelper 11
-- Flavien Bridault <fbridault@ircad.fr> Wed, 28 Feb 2018 13:24:10 +0000
fw4spl (11.0.4-2) unstable; urgency=medium
* Team upload.
* d/control: Move to standards version 4.0.1
* d/p/: Add patch fix_functional_include, Closes: #871111
-- Gert Wollny <gewo@debian.org> Mon, 21 Aug 2017 12:26:44 +0000
fw4spl (11.0.4-1) unstable; urgency=medium
[ Andreas Tille ]
* Team upload
* Fix Homepage
Closes: #812904
[ Flavien Bridault ]
* New upstream version
Support libpng16. Closes: #809935.
Support vtk6. Closes: #820632.
Support insighttoolkit4. Closes: #821957.
Support gcc5 build. Closes: #793240.
* Removed Corentin Desfarges as Uploader
* Added myself as Uploader
* d/watch: Moved to official fw4spl fork
* debhelper 10 (which enables parallel build as default). Closes: #797475.
* d/control: Updated dependencies
* cme fix dpkg-control
-- Flavien Bridault <fbridault@ircad.fr> Wed, 23 Nov 2016 09:58:17 +0100
fw4spl (0.9.2-4) unstable; urgency=medium
* Fix arm support.
* Remove restriction to amd64.
* Update dependencies in d/control.
* Support new boost version. Closes: #797481.
* Forbid parallel build. Closes: #797475.
-- Corentin Desfarges <corentin.desfarges.dev@gmail.com> Thu, 21 Dec 2015 14:11:13 +0200
fw4spl (0.9.2-3) unstable; urgency=medium
* Restrict package to amd64. Closes: #790288.
-- Corentin Desfarges <corentin.desfarges.dev@gmail.com> Thu, 16 Jul 2015 11:16:32 +0200
fw4spl (0.9.2-2) unstable; urgency=medium
* Replace files from libqt4-qt3support by symlinks. Closes: #781298.
* Fix FindHdf5.cmake to find hdf5 on i386 arch. Closes: #781294.
-- Corentin Desfarges <corentin.desfarges.dev@gmail.com> Fri, 27 Mar 2015 17:03:34 +0100
fw4spl (0.9.2-1) unstable; urgency=low
* Initial release (Closes: #779632)
-- Corentin Desfarges <corentin.desfarges.dev@gmail.com> Mon, 23 Mar 2015 11:19:00 +0100
Source: fw4spl
Maintainer: Debian Med Packaging Team <debian-med-packaging@lists.alioth.debian.org>
Uploaders: Flavien Bridault <fbridault@ircad.fr>
Section: science
Priority: optional
Build-Depends: debhelper (>= 11~),
cmake (>= 2.8.11),
libboost-all-dev,
zlib1g-dev,
libexpat1-dev,
libpng-dev,
libtiff5-dev,
libcppunit-dev,
libhdf5-dev,
libqt5opengl5-dev,
libqt5x11extras5-dev,
qttools5-dev,
libvtk6-dev,
libgdcm2-dev,
libinsighttoolkit4-dev,
libann-dev,
libvtkgdcm2-dev,
libvtk6.3-qt,
libvtk6-qt-dev,
libcamp0.7-dev,
libglm-dev,
xvfb,
xauth,
dbus-x11,
rdfind,
symlinks
Standards-Version: 4.1.3
Vcs-Browser: https://anonscm.debian.org/cgit/debian-med/fw4spl.git
Vcs-Git: https://anonscm.debian.org/git/debian-med/fw4spl.git
Homepage: https://fw4spl-org.github.io/
Package: fw4spl
Architecture: any
Depends: ${shlibs:Depends},
${misc:Depends}
Description: FrameWork for Software Production Line
FW4SPL consists of a set of cross-platform C++ libraries.
For now, FW4SPL focuses on the problem of medical images
processing and visualization, and propose an open-source
application called VRRender, which is able to load a
series of images stored in DICOM format (uncompressed
and JPEG) and 3D-modeled patients for medical review.
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Files-Excluded: Apps/VRRender/doc/*
Upstream-Name: fw4spl
Source: https://github.com/fw4spl-org/fw4spl
Files: *
Copyright: 2009-2017 IRCAD
License: LGPL-2+
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
.
This library 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
Library General Public License for more details.
.
You should have received a copy of the GNU Library General Public
License along with this library; if not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA.
.
On Debian systems, the complete text of the GNU Library General
Public License can be found in `/usr/share/common-licenses/LGPL-2'.
Files: debian/*
Copyright: 2015 Corentin Desfarges <corentin.desfarges.dev@gmail.com>
2016-2017 Flavien Bridault <fbridault@ircad.fr>
License: GPL-3+
The Debian packaging information is under the GPL, version 3 or later.
.
On Debian GNU/Linux systems, the complete text of the GNU General
Public License can be found in `/usr/share/common-licenses/GPL' and the
complete text of the GNU Lesser General Public License can be found in
`/usr/share/common-licenses/LGPL'.
Files: CMake/cppunit/cppunit_main.cpp
Copyright: 2004-2010 IRCAD
License: BSD-3-clause
Copyright (c) The Regents of the University of California.
All rights reserved.
.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. Neither the name of the University nor the names of its contributors
may be used to endorse or promote products derived from this software
without specific prior written permission.
.
THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
SUCH DAMAGE.
Files: SrcLib/core/fwZip/*/minizip/*
Copyright: 1998-2010 Gilles Vollant
2009-2010 Mathias Svensson
2007-2008 Even Rouault
License: Zlib
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.
.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely, subject to the following restrictions:
.
1. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software
in a product, an acknowledgment in the product documentation would be
appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
fw4spl: postinst-has-useless-call-to-ldconfig
fw4spl: postrm-has-useless-call-to-ldconfig
debian/fwlauncher.1
debian/fwlauncher-0.1.1
.TH fwlauncher 1 "Novembre 28, 2016" "version 0.11.0.2" "USER COMMANDS"
.SH NAME
fwlauncher \- launch a fw4spl application
.SH SYNOPSIS
fwlauncher [FILE]
.SH DESCRIPTION
This program allows you to run applications and tutorials built
with the open source framework called fw4spl.
.SH EXAMPLES
.IP "fwlauncher /usr/lib/x86_64-linux-gnu/fw4spl/VRRender_0-9/profile.xml"
Start the Application \"VRRender\"
.SH COPYRIGHT
FW4SPL - Copyright (C) IRCAD, 2009-2016.
Distributed under the terms of the GNU Lesser General Public License (LGPL)
as published by the Free Software Foundation.
.TH fwlauncher 1 "Novembre 28, 2016" "version 0.11.0.2" "USER COMMANDS"
.SH NAME
fwlauncher \- launch a fw4spl application
.SH SYNOPSIS
fwlauncher [FILE]
.SH DESCRIPTION
This program allows you to run applications and tutorials built
with the open source framework called fw4spl.
.SH EXAMPLES
.IP "fwlauncher /usr/lib/x86_64-linux-gnu/fw4spl/VRRender_0-9/profile.xml"
Start the Application \"VRRender\"
.SH COPYRIGHT
FW4SPL - Copyright (C) IRCAD, 2009-2016.
Distributed under the terms of the GNU Lesser General Public License (LGPL)
as published by the Free Software Foundation.
#!/bin/bash
cd ..
if [ -d "data" ]
then
nbfic=$(ls -R data | wc -l)
if [ $nbfic -ne 710 ]
then
rm -rf ./data
debian/get_data.sh
else
echo Data are now at : $PWD/data
fi
else
mkdir data
cd data
wget -O data_tmp.tar.gz "https://owncloud.u-strasbg.fr/public.php?service=files&t=cf16caedb901e9f2be2a0e21ea6c18bf&download"
tar -xvf data_tmp.tar.gz
rm -rf data_tmp.tar.gz
echo Data are now at : $PWD/data
fi
Author: Flavien Bridault <fbridault@ircad.fr>
Description: Enable experimental extensions of GLM
Debian-Bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=888932
--- fw4spl.orig/SrcLib/core/fwMath/src/fwMath/MatrixFunctions.cpp
+++ fw4spl/SrcLib/core/fwMath/src/fwMath/MatrixFunctions.cpp
@@ -9,6 +9,7 @@
#include <glm/glm.hpp>
#include <glm/mat4x4.hpp>
+#define GLM_ENABLE_EXPERIMENTAL
#include <glm/gtx/euler_angles.hpp>
#include <glm/gtc/matrix_transform.hpp>
--- fw4spl.orig/SrcLib/visu/fwRenderVTK/src/fwRenderVTK/vtk/fwVtkWheelWidget.cpp
+++ fw4spl/SrcLib/visu/fwRenderVTK/src/fwRenderVTK/vtk/fwVtkWheelWidget.cpp
@@ -8,6 +8,7 @@
#include <fwServices/macros.hpp>
+#define GLM_ENABLE_EXPERIMENTAL
#include <glm/gtx/vector_angle.hpp>
#include <glm/vec2.hpp>
--- fw4spl.orig/Bundles/visu/visuVTKAdaptor/src/visuVTKAdaptor/STransformFromWheel.cpp
+++ fw4spl/Bundles/visu/visuVTKAdaptor/src/visuVTKAdaptor/STransformFromWheel.cpp
@@ -16,6 +16,7 @@
#include <fwServices/macros.hpp>
#include <glm/gtc/matrix_transform.hpp>
+#define GLM_ENABLE_EXPERIMENTAL
#include <glm/gtx/transform.hpp>
#include <glm/vec3.hpp>
Description: Fix some bugs in unit tests
Author: Corentin Desfarges <corentin.desfarges.dev@gmail.com>
Forwarded: no
Last-Update: 2015-01-05
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- fw4spl.orig/SrcLib/core/fwActivities/test/tu/src/builder/ActivitySeriesBuilderTest.cpp
+++ fw4spl/SrcLib/core/fwActivities/test/tu/src/builder/ActivitySeriesBuilderTest.cpp
@@ -1,5 +1,5 @@
/* ***** BEGIN LICENSE BLOCK *****
- * FW4SPL - Copyright (C) IRCAD, 2009-2017.
+ * FW4SPL - Copyright (C) IRCAD, 2009-2018.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
@@ -19,6 +19,7 @@
#include <fwRuntime/Bundle.hpp>
#include <fwRuntime/Extension.hpp>
#include <fwRuntime/io/BundleDescriptorReader.hpp>
+#include <fwRuntime/Runtime.hpp>
// Registers the fixture into the 'registry'
CPPUNIT_TEST_SUITE_REGISTRATION( ::fwActivities::ut::ActivitySeriesBuilderTest );
@@ -33,7 +34,8 @@
void ActivitySeriesBuilderTest::setUp()
{
// Set up context before running a test.
- ::boost::filesystem::path plugin = "share/tu_exec_fwActivities-0.0/tu_builder";
+ const auto runtime = ::fwRuntime::Runtime::getDefault();
+ ::boost::filesystem::path plugin = runtime->getWorkingPath() / "share/tu_exec_fwActivities-0.0/tu_builder";
m_bundle = ::fwRuntime::io::BundleDescriptorReader::createBundle(plugin);
m_activities = ::fwActivities::registry::Activities::New();
@@ -102,3 +104,4 @@
} //namespace ut
} //namespace fwActivities
+
--- fw4spl.orig/SrcLib/core/fwActivities/test/tu/src/registry/ActivityRegistryTest.cpp
+++ fw4spl/SrcLib/core/fwActivities/test/tu/src/registry/ActivityRegistryTest.cpp
@@ -1,5 +1,5 @@
/* ***** BEGIN LICENSE BLOCK *****
- * FW4SPL - Copyright (C) IRCAD, 2009-2017.
+ * FW4SPL - Copyright (C) IRCAD, 2009-2018.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
@@ -42,7 +42,8 @@
{
m_pimpl = std::make_shared< ActivityRegistryTestPimpl >();
- ::boost::filesystem::path plugin = "share/tu_exec_fwActivities-0.0/tu_registry";
+ const auto runtime = ::fwRuntime::Runtime::getDefault();
+ ::boost::filesystem::path plugin = runtime->getWorkingPath() / "share/tu_exec_fwActivities-0.0/tu_registry";
m_pimpl->bundle = ::fwRuntime::io::BundleDescriptorReader::createBundle(plugin);
m_pimpl->activities = fwActivities::registry::Activities::New();
@@ -211,3 +212,4 @@
} //namespace ut
} //namespace fwActivities
+
--- fw4spl.orig/SrcLib/core/fwActivities/test/tu/src/validator/DefaultActivityTest.cpp
+++ fw4spl/SrcLib/core/fwActivities/test/tu/src/validator/DefaultActivityTest.cpp
@@ -1,5 +1,5 @@
/* ***** BEGIN LICENSE BLOCK *****
- * FW4SPL - Copyright (C) IRCAD, 2016-2017.
+ * FW4SPL - Copyright (C) IRCAD, 2016-2018.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
@@ -56,7 +56,8 @@
FwCoreNotUsedMacro(fwMedDataCampVersion);
// Set up context before running a test.
- ::boost::filesystem::path plugin = "share/tu_exec_fwActivities-0.0/tu_validator";
+ const auto runtime = ::fwRuntime::Runtime::getDefault();
+ ::boost::filesystem::path plugin = runtime->getWorkingPath() / "share/tu_exec_fwActivities-0.0/tu_validator";
m_bundle = ::fwRuntime::io::BundleDescriptorReader::createBundle(plugin);
::fwRuntime::Bundle::ExtensionContainer extensionsSet( m_bundle->extensionsBegin(), m_bundle->extensionsEnd());
@@ -507,3 +508,4 @@
} //namespace ut
} //namespace fwActivities
+
Author: Flavien Bridault <fbridault@ircad.fr>
Description: Backport of the code using VTK to be compatible with 6.3
--- fw4spl.orig/SrcLib/visu/fwRenderVTK/include/fwRenderVTK/vtk/fwVtkWheelRepresentation.hpp
+++ fw4spl/SrcLib/visu/fwRenderVTK/include/fwRenderVTK/vtk/fwVtkWheelRepresentation.hpp
@@ -32,27 +32,27 @@
vtkTypeMacro(fwVtkWheelRepresentation, vtkWidgetRepresentation);
/// Prints class information. Not implemented.
- void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
+ void PrintSelf(ostream& os, vtkIndent indent);
/// Generates the representation using the center, radius and orientation.
- FWRENDERVTK_API void BuildRepresentation() VTK_OVERRIDE;
+ FWRENDERVTK_API void BuildRepresentation();
/// Updates wheel geometry using the center, radius and orientation.
FWRENDERVTK_API void UpdateRepresentation();
/// Adds the wheel actor to the prop collection.
- FWRENDERVTK_API void GetActors2D(vtkPropCollection* pc) VTK_OVERRIDE;
+ FWRENDERVTK_API void GetActors2D(vtkPropCollection* pc);
/// Releases graphic resources used by this class' actor.
- FWRENDERVTK_API void ReleaseGraphicsResources(vtkWindow*) VTK_OVERRIDE;
+ FWRENDERVTK_API void ReleaseGraphicsResources(vtkWindow*);
/// Standard VTK render methods.
- FWRENDERVTK_API int RenderOverlay(vtkViewport*) VTK_OVERRIDE;
- FWRENDERVTK_API int RenderOpaqueGeometry(vtkViewport*) VTK_OVERRIDE;
- FWRENDERVTK_API int RenderTranslucentPolygonalGeometry(vtkViewport*) VTK_OVERRIDE;
+ FWRENDERVTK_API int RenderOverlay(vtkViewport*);
+ FWRENDERVTK_API int RenderOpaqueGeometry(vtkViewport*);
+ FWRENDERVTK_API int RenderTranslucentPolygonalGeometry(vtkViewport*);
/// Check if this class holds any translucent geometry. (Not implemented)
- FWRENDERVTK_API int HasTranslucentPolygonalGeometry() VTK_OVERRIDE;
+ FWRENDERVTK_API int HasTranslucentPolygonalGeometry();
/// Set the wheel orientation, expressed in radians.
FWRENDERVTK_API void SetOrientation(double orientation);
@@ -91,7 +91,7 @@
fwVtkWheelRepresentation();
/// Deletes wheel geometry and actor.
- ~fwVtkWheelRepresentation() VTK_OVERRIDE;
+ ~fwVtkWheelRepresentation();
/// List of points defining the wheel.
vtkPoints* m_wheelPoints;
@@ -102,8 +102,8 @@
/// Colors of the wheel
vtkUnsignedCharArray* m_colors;
- fwVtkWheelRepresentation(const fwVtkWheelRepresentation&) VTK_DELETE_FUNCTION;
- void operator=(const fwVtkWheelRepresentation&) VTK_DELETE_FUNCTION;
+ fwVtkWheelRepresentation(const fwVtkWheelRepresentation&);
+ void operator=(const fwVtkWheelRepresentation&);
/// Wheel central part dimensions. The center is used to move the wheel.
double m_centerInnerRadius;
--- fw4spl.orig/SrcLib/visu/fwRenderVTK/include/fwRenderVTK/vtk/fwVtkWheelWidget.hpp
+++ fw4spl/SrcLib/visu/fwRenderVTK/include/fwRenderVTK/vtk/fwVtkWheelWidget.hpp
@@ -30,7 +30,7 @@
vtkTypeMacro(fwVtkWheelWidget, vtkAbstractWidget);
/// Not implemented.
- FWRENDERVTK_API void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
+ FWRENDERVTK_API void PrintSelf(ostream& os, vtkIndent indent);
/// Set associated representation.
FWRENDERVTK_API void SetRepresentation(fwVtkWheelRepresentation* rep);
@@ -39,7 +39,7 @@
FWRENDERVTK_API fwVtkWheelRepresentation* GetRepresentation() const;
/// Creates a wheel representation as default.
- FWRENDERVTK_API void CreateDefaultRepresentation() VTK_OVERRIDE;
+ FWRENDERVTK_API void CreateDefaultRepresentation();
FWRENDERVTK_API void SetWheelUpdateCallback(std::function<void (double, double, double)> f);
@@ -49,7 +49,7 @@
fwVtkWheelWidget();
/// Destructor.
- ~fwVtkWheelWidget() VTK_OVERRIDE
+ ~fwVtkWheelWidget()
{
}
@@ -72,8 +72,8 @@
Outside
} WidgetState;
- fwVtkWheelWidget(const fwVtkWheelWidget&) VTK_DELETE_FUNCTION;
- void operator=(const fwVtkWheelWidget&) VTK_DELETE_FUNCTION;
+ fwVtkWheelWidget(const fwVtkWheelWidget&);
+ void operator=(const fwVtkWheelWidget&);
/// Records the mouse position when selecting.
int m_initMouseX;
--- fw4spl.orig/SrcLib/visu/fwRenderVTK/src/fwRenderVTK/vtk/fwVtkWheelRepresentation.cpp
+++ fw4spl/SrcLib/visu/fwRenderVTK/src/fwRenderVTK/vtk/fwVtkWheelRepresentation.cpp
@@ -10,15 +10,18 @@
#include <glm/common.hpp>
#include <glm/gtc/constants.hpp>
+#include <glm/gtc/vec1.hpp>
#include <vtkCellArray.h>
#include <vtkCellData.h>
#include <vtkDoubleArray.h>
+#include <vtkObjectFactory.h>
#include <vtkPolyData.h>
#include <vtkPolyDataMapper2D.h>
#include <vtkQuad.h>
#include <vtkRenderer.h>
#include <vtkRenderWindow.h>
+#include <vtkSmartPointer.h>
#include <cmath>
--- fw4spl.orig/Bundles/visu/visuVTKVRAdaptor/src/visuVTKVRAdaptor/SVolume.cpp
+++ fw4spl/Bundles/visu/visuVTKVRAdaptor/src/visuVTKVRAdaptor/SVolume.cpp
@@ -448,12 +448,13 @@
m_colorTransferFunction->SetClamping(!pTF->getIsClamped());
m_opacityTransferFunction->SetClamping(!pTF->getIsClamped());
- if(m_blendMode == "average")
+ // Unsupported with VTK 6.3
+ /*if(m_blendMode == "average")
{
//use the TF windowing min and max values to set up the average blend range
std::pair< double, double > averageRange = this->getTransferFunction()->getWLMinMax();
m_volumeMapper->SetAverageIPScalarRange(averageRange.first, averageRange.second);
- }
+ }*/
this->setVtkPipelineModified();
@@ -492,8 +493,9 @@
}
else if(m_blendMode == "average")
{
- m_volumeMapper->SetRequestedRenderMode(vtkSmartVolumeMapper::GPURenderMode);
- m_volumeMapper->SetBlendModeToAverageIntensity();
+ // Unsupported with VTK 6.3
+ /*m_volumeMapper->SetRequestedRenderMode(vtkSmartVolumeMapper::GPURenderMode);
+ m_volumeMapper->SetBlendModeToAverageIntensity();*/
}
else if(m_blendMode == "additive")
{
Author: Flavien Bridault <fbridault@ircad.fr>
Description: Remove useless and broken dependency against vxl
--- fw4spl.orig/SrcLib/io/fwItkIO/CMakeLists.txt
+++ fw4spl/SrcLib/io/fwItkIO/CMakeLists.txt
@@ -6,18 +6,9 @@
find_library(JPEG_LIBRARY libjpeg)
-find_library(VCL_LIBRARY vcl )
-find_library(VNL_LIBRARY vnl )
-find_library(VNL_ALGO_LIBRARY vnl_algo )
-find_library(V3P_NETLIB_LIBRARY v3p_netlib )
-
fwInclude(${ZLIB_INCLUDE_DIRS})
fwForwardInclude(
- ${VNL_INCLUDE_PATH}
- ${VNL_INCLUDE_PATH}/vxl
- ${VNL_INCLUDE_PATH}/vxl/core
- ${VNL_INCLUDE_PATH}/vxl/vcl
${ITK_INCLUDE_DIRS}
)
@@ -32,10 +23,6 @@
ITKIOImageBase
ITKIOJPEG
ITKMetaIO
- ${VCL_LIBRARY}
- ${VNL_LIBRARY}
- ${VNL_ALGO_LIBRARY}
- ${V3P_NETLIB_LIBRARY}
itksys
itkopenjpeg
)
Author: Flavien Bridault <fbridault@ircad.fr>
Description: Revert QVTKOpenGLWidget usage that do no exist in VTK 6.3
diff --git i/Bundles/visu/visuVTKQt/include/visuVTKQt/Plugin.hpp w/Bundles/visu/visuVTKQt/include/visuVTKQt/Plugin.hpp
index b8916f5..71e3ed3 100644
--- i/Bundles/visu/visuVTKQt/include/visuVTKQt/Plugin.hpp
+++ w/Bundles/visu/visuVTKQt/include/visuVTKQt/Plugin.hpp
@@ -1,5 +1,5 @@
/* ***** BEGIN LICENSE BLOCK *****
- * FW4SPL - Copyright (C) IRCAD, 2009-2017.
+ * FW4SPL - Copyright (C) IRCAD, 2009-2015.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
@@ -7,19 +7,20 @@
#ifndef __VISUVTKQT_PLUGIN_HPP__
#define __VISUVTKQT_PLUGIN_HPP__
-#include "visuVTKQt/config.hpp"
-
#include <fwRuntime/Plugin.hpp>
+#include "visuVTKQt/config.hpp"
+
namespace visuVTKQt
{
/**
* @brief This class is started when the bundles is loaded.
+ * @class Plugin
+ *
+ * @date 2009.
*/
struct VISUVTKQT_CLASS_API Plugin : public ::fwRuntime::Plugin
{
- Plugin() noexcept;
-
/**
* @brief destructor
*/
diff --git i/Bundles/visu/visuVTKQt/include/visuVTKQt/VtkRenderWindowInteractorManager.hpp w/Bundles/visu/visuVTKQt/include/visuVTKQt/VtkRenderWindowInteractorManager.hpp
index 9819331..de67e37 100644
--- i/Bundles/visu/visuVTKQt/include/visuVTKQt/VtkRenderWindowInteractorManager.hpp
+++ w/Bundles/visu/visuVTKQt/include/visuVTKQt/VtkRenderWindowInteractorManager.hpp
@@ -1,5 +1,5 @@
/* ***** BEGIN LICENSE BLOCK *****
- * FW4SPL - Copyright (C) IRCAD, 2009-2017.
+ * FW4SPL - Copyright (C) IRCAD, 2009-2015.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
@@ -9,14 +9,19 @@
#include "visuVTKQt/config.hpp"
+#include <fwCore/base.hpp>
+
+#include <fwGui/container/fwContainer.hpp>
+
#include <fwRenderVTK/IVtkRenderWindowInteractorManager.hpp>
-#include <QPointer>
+#include <string>
+
class vtkRenderWindowInteractor;
QT_BEGIN_NAMESPACE
-class QVTKOpenGLWidget;
+class QVTKWidget;
QT_END_NAMESPACE
namespace fwGuiQt
@@ -56,7 +61,7 @@ public:
private:
- QPointer<QVTKOpenGLWidget> m_QVTKOpenGLWidget;
+ QPointer<QVTKWidget> m_qVTKWidget;
vtkRenderWindowInteractor* m_interactor;
@@ -68,3 +73,4 @@ private:
#endif // __VISUVTKQT_VTKRENDERWINDOWINTERACTORMANAGER_HPP__
+
diff --git i/Bundles/visu/visuVTKQt/src/visuVTKQt/Plugin.cpp w/Bundles/visu/visuVTKQt/src/visuVTKQt/Plugin.cpp
index 85540a9..9944885 100644
--- i/Bundles/visu/visuVTKQt/src/visuVTKQt/Plugin.cpp
+++ w/Bundles/visu/visuVTKQt/src/visuVTKQt/Plugin.cpp
@@ -10,11 +10,6 @@
#include <fwRuntime/utils/GenericExecutableFactoryRegistrar.hpp>
-#include <QApplication>
-#include <QSurfaceFormat>
-#include <QVTKOpenGLWidget.h>
-#include <vtkGenericOpenGLRenderWindow.h>
-
namespace visuVTKQt
{
@@ -24,22 +19,6 @@ static ::fwRuntime::utils::GenericExecutableFactoryRegistrar<Plugin> registrar("
//-----------------------------------------------------------------------------
-Plugin::Plugin() noexcept
-{
- // Since we share the opengl context with Qt, we must set the default QSurfaceFormat before QApplication
- // to allow QVTKOpenGLWidget to work properly
- SLM_ASSERT( "QApplication is already created! The default surface format cannot be changed afterward.\n"
- "This problem can happen when the profile.xml is handwritten and contains 'visuVTKQt' and 'guiQt'.\n"
- "If that is the case, please ensure that 'visuVTKQt' is started before 'guiQt'.\n"
- "It could also happen for generated 'profile.xml' files, check it to be sure.",
- qApp == nullptr );
-
- vtkOpenGLRenderWindow::SetGlobalMaximumNumberOfMultiSamples(0);
- QSurfaceFormat::setDefaultFormat(QVTKOpenGLWidget::defaultFormat());
-}
-
-//-----------------------------------------------------------------------------
-
Plugin::~Plugin() noexcept
{
}
diff --git i/Bundles/visu/visuVTKQt/src/visuVTKQt/VtkRenderWindowInteractorManager.cpp w/Bundles/visu/visuVTKQt/src/visuVTKQt/VtkRenderWindowInteractorManager.cpp
index 5b2b0b8..4ed71a4 100644
--- i/Bundles/visu/visuVTKQt/src/visuVTKQt/VtkRenderWindowInteractorManager.cpp
+++ w/Bundles/visu/visuVTKQt/src/visuVTKQt/VtkRenderWindowInteractorManager.cpp
@@ -4,30 +4,279 @@
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
-#include "visuVTKQt/VtkRenderWindowInteractorManager.hpp"
+#include <QVBoxLayout>
+#include <QEvent>
+#include <QDropEvent>
-#include <fwCom/Signal.hpp>
-#include <fwCom/Signal.hxx>
+#include <QVTKWidget.h>
+
+#include <QMimeData>
+
+#include <vtkRenderer.h>
+#include <vtkRenderWindow.h>
+#include <vtkRenderWindowInteractor.h>
#include <fwData/String.hpp>
-#include <fwGuiQt/container/QtContainer.hpp>
+#include <fwTools/UUID.hpp>
+
+#include <fwCom/Signal.hpp>
+#include <fwCom/Signal.hxx>
-#include <fwRenderVTK/registry/macros.hpp>
#include <fwRenderVTK/SRender.hpp>
+#include <fwRenderVTK/registry/macros.hpp>
+#include <fwGuiQt/container/QtContainer.hpp>
-#include <fwTools/UUID.hpp>
+#include "visuVTKQt/VtkRenderWindowInteractorManager.hpp"
-#include <QDropEvent>
-#include <QEvent>
-#include <QMimeData>
-#include <QSurfaceFormat>
-#include <QVBoxLayout>
-#include <QVTKOpenGLWidget.h>
-#include <vtkGenericOpenGLRenderWindow.h>
-#include <vtkRenderer.h>
-#include <vtkRenderWindow.h>
-#include <vtkRenderWindowInteractor.h>
+#ifdef __APPLE__
+// XXX Retinhack
+// hack to fix vtk render windows on mac retina screen, until fixed
+// by vtk
+#include <QWindow>
+#include <QScreen>
+#include <QVTKInteractor.h>
+#include <vtkCocoaRenderWindow.h>
+#include <vtkObjectFactory.h>
+#include <vtkSmartPointer.h>
+#include <vtkInteractorStyleTrackballCamera.h>
+#include <QMetaEnum>
+
+class RetinHackRWI : public QVTKInteractor
+{
+protected:
+ RetinHackRWI() :
+ QVTKInteractor()
+ {
+ }
+
+public:
+
+ static RetinHackRWI* New();
+
+ //------------------------------------------------------------------------------
+
+ virtual int* GetLastEventPosition ()
+ {
+ auto LastPos = this->QVTKInteractor::GetLastEventPosition();
+ const auto r = this->Ratio;
+
+ LastRetinaPos[0] = LastPos[0]*r;
+ LastRetinaPos[1] = LastPos[1]*r;
+
+ return LastRetinaPos;
+ }
+
+ //------------------------------------------------------------------------------
+
+ virtual void GetLastEventPosition (int& x, int& y)
+ {
+ auto LastPos = this->QVTKInteractor::GetLastEventPosition();
+ const auto r = this->Ratio;
+
+ x = LastPos[0]*r;
+ y = LastPos[1]*r;
+ }
+
+ //------------------------------------------------------------------------------
+
+ virtual void GetLastEventPosition (int xy[2])
+ {
+ auto LastPos = this->QVTKInteractor::GetLastEventPosition();
+ const auto r = this->Ratio;
+
+ xy[0] = LastPos[0]*r;
+ xy[1] = LastPos[1]*r;
+ }
+
+ //------------------------------------------------------------------------------
+
+ virtual int* GetEventPosition ()
+ {
+ auto Pos = this->QVTKInteractor::GetEventPosition();
+ const auto r = this->Ratio;
+
+ RetinaPos[0] = Pos[0]*r;
+ RetinaPos[1] = Pos[1]*r;
+
+ return RetinaPos;
+ }
+
+ //------------------------------------------------------------------------------
+
+ virtual void GetEventPosition (int& x, int& y)
+ {
+ auto Pos = this->QVTKInteractor::GetEventPosition();
+ const auto r = this->Ratio;
+
+ x = Pos[0]*r;
+ y = Pos[1]*r;
+ }
+
+ //------------------------------------------------------------------------------
+
+ virtual void GetEventPosition (int xy[2])
+ {
+ auto Pos = this->QVTKInteractor::GetEventPosition();
+ const auto r = this->Ratio;
+
+ xy[0] = Pos[0]*r;
+ xy[1] = Pos[1]*r;
+ }
+
+ //------------------------------------------------------------------------------
+
+ void SetDevicePixelRatio(int r)
+ {
+ this->Ratio = r;
+ }
+
+private:
+ int RetinaPos[2];
+ int LastRetinaPos[2];
+
+ int Ratio = 2;
+
+};
+
+vtkStandardNewMacro(RetinHackRWI);
+
+class RetinhackRenderWindow : public vtkCocoaRenderWindow
+{
+protected:
+ RetinhackRenderWindow() :
+ vtkCocoaRenderWindow()
+ {
+ }
+
+public:
+
+ static RetinhackRenderWindow* New();
+
+ //------------------------------------------------------------------------------
+
+ int* GetSize()
+ {
+ this->vtkCocoaRenderWindow::GetSize();
+
+ this->RetinaSize[0] = this->Size[0] * this->Ratio;
+ this->RetinaSize[1] = this->Size[1] * this->Ratio;
+
+ return this->RetinaSize;
+ }
+
+ //------------------------------------------------------------------------------
+
+ int* GetScreenSize()
+ {
+ this->vtkCocoaRenderWindow::GetScreenSize();
+
+ this->RetinaSize[0] = this->Size[0] * this->Ratio;
+ this->RetinaSize[1] = this->Size[1] * this->Ratio;
+
+ return this->RetinaSize;
+ }
+
+ //------------------------------------------------------------------------------
+
+ vtkRenderWindowInteractor* MakeRenderWindowInteractor()
+ {
+ this->Interactor = RetinHackRWI::New();
+ this->Interactor->SetRenderWindow(this);
+ return this->Interactor;
+ }
+
+ //------------------------------------------------------------------------------
+
+ void SetDevicePixelRatio(int r)
+ {
+ this->Ratio = r;
+ static_cast< RetinHackRWI* >( this->Interactor )->SetDevicePixelRatio(r);
+ }
+
+private:
+ int RetinaSize[2] = {600, 600};
+ int Ratio = 2;
+};
+
+vtkStandardNewMacro(RetinhackRenderWindow);
+
+class RetinhackVtkWidget : public QVTKWidget
+{
+public:
+ RetinhackVtkWidget(QWidget* container = nullptr) :
+ QVTKWidget(container)
+ {
+ vtkSmartPointer< vtkInteractorStyleTrackballCamera > interactorStyle
+ = vtkInteractorStyleTrackballCamera::New();
+ vtkSmartPointer< RetinhackRenderWindow > renderWindow = RetinhackRenderWindow::New();
+ vtkSmartPointer< RetinHackRWI > rwi = RetinHackRWI::New();
+
+ rwi->Initialize();
+ rwi->SetInteractorStyle(interactorStyle);
+ rwi->SetRenderWindow(renderWindow);
+ renderWindow->SetInteractor(rwi);
+
+ this->SetRenderWindow(renderWindow);
+
+ }
+
+ //------------------------------------------------------------------------------
+
+ bool event(QEvent* e)
+ {
+ auto ratio = this->devicePixelRatio();
+ if (m_ratio != ratio )
+ {
+ SLM_ASSERT( "Render window shall be a RetinhackRenderWindow",
+ dynamic_cast< RetinhackRenderWindow* >( this->mRenWin ));
+ static_cast< RetinhackRenderWindow* >( this->mRenWin )->SetDevicePixelRatio(ratio);
+ m_ratio = ratio;
+ }
+
+ if(e->type() == QEvent::ShowToParent)
+ {
+ QObject::disconnect(m_renderConnection);
+ QPointer<RetinhackVtkWidget> widget(this);
+ m_renderConnection = QObject::connect(this->window()->windowHandle(), &QWindow::screenChanged, [ = ] ()
+ {
+ if(!widget)
+ {
+ return;
+ }
+ auto ratio = widget->devicePixelRatio();
+ SLM_ASSERT( "Render window shall be a RetinhackRenderWindow",
+ dynamic_cast< RetinhackRenderWindow* >( widget->mRenWin ));
+ static_cast< RetinhackRenderWindow* >( widget->mRenWin )->SetDevicePixelRatio(ratio);
+ widget->mRenWin->Render();
+ });
+ }
+
+ return QVTKWidget::event(e);
+ }
+
+ //------------------------------------------------------------------------------
+
+ virtual void SetRenderWindow(vtkRenderWindow* rw)
+ {
+ QVTKWidget::SetRenderWindow(rw);
+
+ auto ratio = this->devicePixelRatio();
+
+ SLM_ASSERT( "Render window shall be a RetinhackRenderWindow",
+ dynamic_cast< RetinhackRenderWindow* >( this->mRenWin ));
+ static_cast< RetinhackRenderWindow* >( this->mRenWin )->SetDevicePixelRatio(ratio);
+ }
+
+protected:
+ int m_ratio = -1;
+
+ QMetaObject::Connection m_renderConnection;
+};
+
+#define QVTKWidget RetinhackVtkWidget
+
+#endif //__APPLE__
class DropFilter : public QObject
{
@@ -103,25 +352,22 @@ void VtkRenderWindowInteractorManager::installInteractor( ::fwGui::container::fw
SLM_ASSERT("Invalid parent.", _parent );
m_parentContainer = ::fwGuiQt::container::QtContainer::dynamicCast( _parent );
+ m_qVTKWidget = new QVTKWidget();
+
QVBoxLayout* layout = new QVBoxLayout();
layout->setContentsMargins(0, 0, 0, 0);
- m_parentContainer->setLayout(layout);
-
- // Create the render window and the associated QVTKOpenGLWidget
- vtkNew<vtkGenericOpenGLRenderWindow> window;
- m_QVTKOpenGLWidget = new QVTKOpenGLWidget(m_parentContainer->getQtContainer());
- m_QVTKOpenGLWidget->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
- layout->addWidget(m_QVTKOpenGLWidget);
- m_QVTKOpenGLWidget->SetRenderWindow(window.Get());
// Install Drop filter
- if(auto locked = m_renderService.lock())
+ if(m_renderService.lock())
{
- m_QVTKOpenGLWidget->setAcceptDrops(true);
- m_QVTKOpenGLWidget->installEventFilter(new DropFilter(locked));
+ m_qVTKWidget->setAcceptDrops(true);
+ m_qVTKWidget->installEventFilter(new DropFilter(m_renderService.lock()));
}
- m_interactor = window->GetInteractor();
+ layout->addWidget(m_qVTKWidget);
+ m_parentContainer->setLayout(layout);
+
+ m_interactor = m_qVTKWidget->GetRenderWindow()->GetInteractor();
}
//-----------------------------------------------------------------------------
@@ -130,8 +376,8 @@ void VtkRenderWindowInteractorManager::uninstallInteractor()
{
m_interactor = nullptr;
- delete m_QVTKOpenGLWidget;
- m_QVTKOpenGLWidget.clear();
+ delete m_qVTKWidget;
+ m_qVTKWidget = nullptr;
m_parentContainer->clean();
}
fix_unit_tests.patch
remove_vxl_from_fwItkIO.patch
fix_glm_experimental.patch
fix_vtk6_build.patch
revert_qVTK_widget.patch
#!/usr/bin/make -f
#fix the lintian "hardening" message
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/buildflags.mk
CPPFLAGS:=$(shell dpkg-buildflags --get CPPFLAGS)
CFLAGS:=$(shell dpkg-buildflags --get CFLAGS)
CXXFLAGS:=$(shell dpkg-buildflags --get CXXFLAGS)
LDFLAGS:=$(shell dpkg-buildflags --get LDFLAGS) -Wl,--as-needed
%:
dh $@
override_dh_auto_configure:
dh_auto_configure -- -DCMAKE_BUILD_WITH_INSTALL_RPATH=FALSE -DUSE_SYSTEM_LIB=ON -DPROJECTS_TO_BUILD="VRRender" -DPROJECTS_TO_INSTALL="VRRender" -DCMAKE_INSTALL_RPATH="/usr/lib/$(DEB_HOST_MULTIARCH)/fw4spl" -Wno-dev -DENABLE_PCH=OFF -DBUILD_TESTS=OFF -DCMAKE_BUILD_TYPE=Release
override_dh_auto_install:
dh_auto_install --destdir=debian/fw4spl
rdfind -outputname /dev/null -makesymlinks true debian/fw4spl/
symlinks -r -s -c debian/fw4spl
override_dh_auto_test:
echo "test disabled"
override_dh_shlibdeps:
dh_shlibdeps -v -l/usr/lib/$(DEB_HOST_MULTIARCH):/usr/lib/$(DEB_HOST_MULTIARCH)/fw4spl:/usr/lib/$(DEB_HOST_MULTIARCH)/fw4spl/Bundles:/usr/lib/$(DEB_HOST_MULTIARCH)/fw4spl/gui_0-1/:/usr/lib/$(DEB_HOST_MULTIARCH)/fw4spl/io_0-1/:/usr/lib/$(DEB_HOST_MULTIARCH)/fw4spl:/usr/lib/$(DEB_HOST_MULTIARCH)/fw4spl/ctrlSelection_0-1/:/usr/lib/$(DEB_HOST_MULTIARCH)/fw4spl/ioITK_0-1/
version=3
https://github.com/fw4spl-org/fw4spl/releases .*/archive/(\d[\d.-]+)\.(?:tar(?:\.gz|\.bz2)?|tgz)