BUG: Check that region for thread is not empty

Fix the following failure on ITKExamples:

  http://open.cdash.org/testDetails.php?test=199789893&build=2975061

Change-Id: I8b67c0d4e38a688154d0c9a316b491a7a2949f79
BUG: Fix failure in InteractivePause test

Change-Id: I7654a4ddc7ddf4e1e98d292c15fb041ca764beb9
BUG: ConstPointer assigned to non-const raw pointer

itkImageToVectorImageFilter.hxx had a bug that the ConstPointer to the
input image was being assigned to a non-const raw pointer.  This
caused a compilation error.  This is fixed in this patch.

Change-Id: Ibeed0a37752caa60961be7071d99677cc4f87de9
BUG: GDCMImageIO ignore image orienations from MetaDataDictionary

GCMImageIO can transfer DICOM tags from the MetaDataDictionary
to the DICOM files. However, itkImage attributes of Origin, Spacing,
and Directions are handled specially. Unfortunately, they are also handled
inconsistently.

For Origin, preference is given to DICOM tags in the MetaDataDictionary
over the ITK_Origin entry in the MetaDataDictionary.

For Directions, preference was given to the ITK_ZDirection entry in
the MetaDataDictionary over the DICOM tags in the MetaDataDictionary.

This patch unifies the behavior so the DICOM tags in the MetaDataDictionary
take precedence over ITK_Origin and ITK_ZDirection.

(Note that for Spacing, preference is still given to ITK_Spacing.)

This patch addresses the bug in the 3D Slicer #3254. See
http://na-mic.org/Mantis/view.php?id=3254

This patch set includes a test.

Change-Id: Ibe8cb7dcd7387ba696ba509bd328bca2d77d1831
BUG: Two tests were writing to same filename.

These two tests create a tempory file and then read it back in.
The two tests use the same filename for the temporary file. This may
be the cause of some of the test failures on the Dashboard when tests
are run in parallel.

Change-Id: Ib8db714750e92fb3c552988422329cebdc1d07d0
BUG: {Opening,Closing}ByReconstructionImageFilter information propagation

The use of PreserveIntensities option in {Opening,Closing}ByReconstructionImageFilter
leads in tempImage creation, inputImage informations should have to be exported
to avoid exception in filtering process in case of non standard input image information.
informations are exported using CopyInformation method

Tests of OpeningByReconstructionImageFilter using
PreserveIntensities option and non zero origin and spacing image
(generated inside the test) have been added.

Change-Id: I7b47b305940a6d85e978b62012e8ca2dcc0d4323
BUG: Guard against Divide by Zero

As identified in https://issues.itk.org/jira/browse/ITK-3179

Potential divide by zero related to use of the
ImageScanLineIterator.

Change-Id: I7d85e9b79188eaf3dcc32ce033d07ca1d5336f9d
BUG: Row/Column assignment into ImageDimensions was wrong

For some reason, I assigned the DICOM Row attribute to
dim[0] and Column attribute to dim[1], which is backwards.
This wasn't caught for a long time because apparently the
overwhelming majority of DICOM slices in the wild are square,
i.e. dim[0] = dim[1].

GDCM always got this right. Now DCMTK is consistent with
GDCM.

Conflicts:
	Modules/IO/DCMTK/src/itkDCMTKImageIO.cxx
	Modules/IO/DCMTK/test/CMakeLists.txt

Change-Id: I59ba4059b1b0e5dcc55f41308957effb614c44de
COMP: Do not try to include float.h for MinGW.

float.h is needed for FloatingPointExceptions.  ITK can fail
to compile with MinGW, because there are two float.h files on Windows
in this case.  If it happens that the MinGW one is found first,
a failure will occur because a

  #include_next <float.h>

is not in the GCC version.  While this problem has been reported by others to
upstream GCC many times in the past, it has not been addressed.  To get around
this, we avoid trying to include float.h with MinGW.

Change-Id: I2e8022a5b4c67a6fbef930b5ceda403bcb31c97f
BUG: itkSingleLevelSetsv4WhitakerImage2DTest output clobber.

Prevent the two tests from writing to the same output file and possibly
clobbering each other.

Change-Id: I721f730ed6663bdf334e4ec674606509379b929a
ENH: Exclude ITKGDCM module when system GDCM is ON.

When ITK_USE_SYSTEM_GDCM is set to be ON,ITKGDCM module
should be excluded from building.
BUG: A fix for using sys installed GDCM.

When ITK_USE_SYS_GDCM is on, "include ${GDCM_USE_FILE}"
was missing from the itk-module-init.cmake, which could
cause "not found" linking error in external applications.

Change-Id: If01993ebd1d1ee3d6a20c849ea56944c766ea260
COMP: New baseline image for MultiResImageRegistrationTest.

Adding a new baseline image to fix the regression test error
for MultiResIamgeRegistration1Test:
http://open.cdash.org/viewTest.php?onlyfailed&buildid=3004022

Change-Id: Id5cf32ad3246d1a175cdab96c9c0f5e351aa30b7
COMP: Avoid MetaIO config conflict with USE_SYSTEM_GDCM.

When a system GDCM with configured with VTK support, its UseGDCM.cmake file
can call include(${VTK_USE_FILE}).  This can cause VTK's include directories
to fall before ITK's, the system can find VTK's metaIOConfig.h first, and
MetaIO build failures will occurue.

Change-Id: Ided8ec692a10fdde423f9f4fec521727d7b4b83e
Merge branch '4.4.2-master-to-release' into release