[Insight-users] DICOM viewer using itk and vtk

Brenno Ribeiro brennobr at gmail.com
Tue Feb 28 14:36:19 EST 2012


Hi, i'm trying to create a dicom viewer using itk and vtk. So i'm begining
to deal with the examples, DicomSeriesReadImageWrite2.cxx in this case. I
create a project and build it with cmake-gui although i could create the
binary of the project the program get into a exception like that:

"itk::ExceptionObject (0x15afd50)
Location: "virtual void itk::JPEGImageIO::Write(const void*)"
File:
/home/brennobr/Util/Itk/InsightToolkit-4.0.0/Modules/IO/JPEG/src/itkJPEGImageIO.cxx
Line: 437
Description: itk::ERROR: JPEGImageIO(0x1587840): JPEG supports unsigned
char/int only"


How i feel that the CMakelists.txt is ok and i didn't changes in the
default example of DicomSeriesReadImageWrite2.cxx i think can be the line
of command used to run the program. I tried the following way:

"./DicomSeriesReadImageWrite2 /home/brennobr/Source/dcm-files teste.jpeg
image-01.dcm"


*The bin DicomSeriesReadImageWrite2 is in a different folder of the dicom
files


Here is my CMakeLists.txt

#beginning CMakeLists.txt
cmake_minimum_required(VERSION 2.6)

FIND_PACKAGE(ITK REQUIRED)
INCLUDE(${ITK_USE_FILE})

project(DicomSeriesReadImageWrite2)

add_executable(DicomSeriesReadImageWrite2 DicomSeriesReadImageWrite2.cxx )
target_link_libraries(DicomSeriesReadImageWrite2  ${ITK_LIBRARIES})

if(BUILD_TESTING)
  add_subdirectory(test)
endif(BUILD_TESTING)
#end CMakeLists.txt


-- 
Brenno Bernardes Ribeiro

Engenharia da Computação
Universidade Federal do Pará
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20120228/9883636f/attachment.htm>


More information about the Insight-users mailing list