forked from RTKConsortium/RTK
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Always wrap dimensions 2;3;4;5 when wrapping vector types
- Loading branch information
1 parent
13b0c85
commit 529aea1
Showing
20 changed files
with
494 additions
and
99 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,31 @@ | ||
if(RTK_USE_CUDA) | ||
|
||
itk_wrap_class("itk::CudaImage" POINTER_WITH_CONST_POINTER) | ||
foreach(t ${WRAP_ITK_REAL}) | ||
foreach(d ${ITK_WRAP_IMAGE_DIMS}) | ||
itk_wrap_template("${ITKM_${t}}${d}" "${ITKT_${t}}, ${d}") | ||
endforeach() | ||
|
||
foreach(d ${ITK_WRAP_IMAGE_DIMS}) | ||
itk_wrap_template("F${d}" "float, ${d}") | ||
endforeach() | ||
|
||
list(FIND ITK_WRAP_IMAGE_DIMS "4" _index) | ||
if (${_index} EQUAL -1) | ||
itk_wrap_template("F4" "${ITKT_F}, 4") | ||
itk_wrap_template("CI${ITKM_VF3}4" "itk::Vector<${ITKT_F},3>, 4") | ||
endif() | ||
|
||
foreach(nbin ${ITK_WRAP_VECTOR_COMPONENTS}) | ||
itk_wrap_template("${ITKM_VF${nbin}}3" "itk::Vector<${ITKT_F},${nbin}>, 3") | ||
# Force VECTOR_COMPONENTS to "2;3;4;5" | ||
set(vectorComponents 2 3 4 5) | ||
foreach(component ${vectorComponents}) | ||
# Force ITK_WRAP_IMAGE_DIMS to "2;3;4" | ||
set(imageDimensions 2 3 4) | ||
foreach(d ${imageDimensions}) | ||
foreach(vt ${WRAP_ITK_VECTOR_REAL}) | ||
itk_wrap_template("${ITKM_${vt}${component}}${d}" "${ITKT_${vt}${component}}, ${d}") | ||
endforeach() | ||
foreach(cvt ${WRAP_ITK_COV_VECTOR_REAL}) | ||
itk_wrap_template("${ITKM_${cvt}${component}}${d}" "${ITKT_${cvt}${component}}, ${d}") | ||
endforeach() | ||
endforeach() | ||
endforeach() | ||
itk_wrap_template("${ITKM_CVF3}4" "itk::CovariantVector<${ITKT_F},3>, 4") | ||
|
||
itk_end_wrap_class() | ||
|
||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,25 @@ | ||
if(RTK_USE_CUDA) | ||
|
||
|
||
itk_wrap_class("itk::CudaImageToImageFilter" POINTER) | ||
|
||
foreach(d ${ITK_WRAP_IMAGE_DIMS}) | ||
itk_wrap_template("CI${ITKM_F}${d}CI${ITKM_F}${d}" | ||
"itk::CudaImage<${ITKT_F}, ${d}>, itk::CudaImage<${ITKT_F}, ${d}>") | ||
endforeach() | ||
foreach(nmat 2 3) | ||
itk_wrap_template("CI${ITKM_VF${nmat}}3CI${ITKM_VF${nmat}}3" "itk::CudaImage<itk::Vector<${ITKT_F},${nmat}>, 3>, itk::CudaImage<itk::Vector<${ITKT_F},${nmat}>, 3>") | ||
|
||
# Force VECTOR_COMPONENTS to "2;3;4;5" | ||
set(vectorComponents 2 3 4 5) | ||
foreach(component ${vectorComponents}) | ||
foreach(vt ${WRAP_ITK_VECTOR_REAL}) | ||
# Force ITK_WRAP_IMAGE_DIMS to "2;3;4" | ||
set(imageDimensions 2 3 4) | ||
foreach(d ${imageDimensions}) | ||
itk_wrap_template("CI${ITKM_${vt}${component}}${d}CI${ITKM_${vt}${component}}${d}" | ||
"itk::CudaImage<${ITKT_${vt}${component}}, ${d}>, itk::CudaImage<${ITKT_${vt}${component}}, ${d}>") | ||
endforeach() | ||
endforeach() | ||
endforeach() | ||
|
||
itk_end_wrap_class() | ||
|
||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,42 @@ | ||
if(RTK_USE_CUDA) | ||
|
||
itk_wrap_class("itk::CudaInPlaceImageFilter" POINTER) | ||
|
||
#itk_wrap_image_filter_combinations("${WRAP_ITK_REAL}" "${WRAP_ITK_REAL}") | ||
foreach(d ${ITK_WRAP_IMAGE_DIMS}) | ||
itk_wrap_template("CI${ITKM_F}${d}CI${ITKM_F}${d}" | ||
"itk::CudaImage<${ITKT_F}, ${d}>, itk::CudaImage<${ITKT_F}, ${d}>") | ||
endforeach() | ||
foreach(nmat 2 3) | ||
itk_wrap_template("CI${ITKM_VF${nmat}}3CI${ITKM_VF${nmat}}3" "itk::CudaImage<itk::Vector<${ITKT_F},${nmat}>, 3>, itk::CudaImage<itk::Vector<${ITKT_F},${nmat}>, 3>") | ||
|
||
# Force VECTOR_COMPONENTS to "2;3;4;5" | ||
set(vectorComponents 2 3 4 5) | ||
foreach(component ${vectorComponents}) | ||
foreach(d ${ITK_WRAP_IMAGE_DIMS}) | ||
itk_wrap_template("CI${ITKM_V${ITKM_F}${component}}${d}CI${ITKM_V${ITKM_F}${component}}${d}" | ||
"itk::CudaImage<itk::Vector<${ITKT_F},${component}>, ${d}>, itk::CudaImage<itk::Vector<${ITKT_F},${component}>, ${d}>") | ||
endforeach() | ||
endforeach() | ||
|
||
itk_end_wrap_class() | ||
|
||
itk_wrap_class("itk::CudaImageToImageFilter" POINTER) | ||
foreach(d ${ITK_WRAP_IMAGE_DIMS}) | ||
itk_wrap_template("CI${ITKM_F}${d}CI${ITKM_F}${d}IPIFCI${ITKM_F}${d}" "itk::CudaImage<${ITKT_F}, ${d}>, itk::CudaImage<${ITKT_F}, ${d}>, itk::InPlaceImageFilter< itk::CudaImage<${ITKT_F}, ${d}> >") | ||
endforeach() | ||
foreach(nmat 2 3) | ||
itk_wrap_template("CI${ITKM_VF${nmat}}3CI${ITKM_VF${nmat}}3IPIFCI${ITKM_VF${nmat}}3" "itk::CudaImage<itk::Vector<${ITKT_F},${nmat}>, 3>, itk::CudaImage<itk::Vector<${ITKT_F},${nmat}>, 3>, itk::InPlaceImageFilter< itk::CudaImage<itk::Vector<${ITKT_F},${nmat}>, 3> >") | ||
|
||
# Force VECTOR_COMPONENTS to "2;3;4;5" | ||
set(vectorComponents 2 3 4 5) | ||
foreach(component ${vectorComponents}) | ||
foreach(vt ${WRAP_ITK_VECTOR_REAL}) | ||
# Force ITK_WRAP_IMAGE_DIMS to "2;3;4" | ||
set(imageDimensions 2 3 4) | ||
foreach(d ${imageDimensions}) | ||
itk_wrap_template("CI${ITKM_${vt}${component}}${d}CI${ITKM_${vt}${component}}${d}IPIFCI${ITKM_${vt}${component}}${d}" | ||
"itk::CudaImage<${ITKT_${vt}${component}}, ${d}>, itk::CudaImage<${ITKT_${vt}${component}}, ${d}>, itk::InPlaceImageFilter< itk::CudaImage<${ITKT_${vt}${component}}, ${d}> >") | ||
endforeach() | ||
endforeach() | ||
endforeach() | ||
|
||
itk_end_wrap_class() | ||
|
||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
itk_wrap_class("itk::ImageFileReader" POINTER) | ||
|
||
# Force ITK_WRAP_VECTOR_COMPONENTS to "2;3;4;5" | ||
set(vectorComponents 2 3 4 5) | ||
foreach(component ${vectorComponents}) | ||
list(FIND ITK_WRAP_VECTOR_COMPONENTS "${component}" _index) | ||
if (${_index} EQUAL -1) | ||
foreach(vt ${WRAP_ITK_VECTOR_REAL}) | ||
foreach(d ${ITK_WRAP_IMAGE_DIMS}) | ||
itk_wrap_template("I${ITKM_${vt}${component}}${d}" "itk::Image<${ITKT_${vt}${component}}, ${d}>") | ||
endforeach() | ||
endforeach() | ||
endif() | ||
endforeach() | ||
|
||
itk_end_wrap_class() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
itk_wrap_class("itk::ImageFileWriter" POINTER) | ||
|
||
# Force ITK_WRAP_VECTOR_COMPONENTS to "2;3;4;5" | ||
set(vectorComponents 2 3 4 5) | ||
foreach(component ${vectorComponents}) | ||
list(FIND ITK_WRAP_VECTOR_COMPONENTS "${component}" _index) | ||
if (${_index} EQUAL -1) | ||
foreach(vt ${WRAP_ITK_VECTOR_REAL}) | ||
foreach(d ${ITK_WRAP_IMAGE_DIMS}) | ||
itk_wrap_template("I${ITKM_${vt}${component}}${d}" "itk::Image<${ITKT_${vt}${component}}, ${d}>") | ||
endforeach() | ||
endforeach() | ||
endif() | ||
endforeach() | ||
|
||
itk_end_wrap_class() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.