[vtkusers] Segmentation fault with QT + vtkDEMReader
Pa Set
pasyte at hotmail.it
Sat Jul 28 08:52:01 EDT 2012
Testing a QT program with vtkDEMReader, compiled with no error but
exits at runtime with "segfault at 0 ip b65f7d31 sp bf842720 error 6 in
libvtkIO.so.5.8.0[b6529000+4ce000]".
I'm definitely making some mistakes. Can anyone point out the right way,
please?
Thanks in advance for all feedback.
Paolo
_Some infos for answers follow:_
The starting point is this example program
http://www.vtk.org/Wiki/VTK/Examples/Cxx/Qt/RenderWindowUIMultipleInheritance,
modified in this way *only*:
........
#include "vtkSmartPointer.h"
#include <vtkDEMReader.h>
#include <vtkImageData.h>
// Constructor
SimpleView::SimpleView()
{
this->setupUi(this);
// Read the file
vtkSmartPointer<vtkDEMReader> reader =
vtkSmartPointer<vtkDEMReader>::New();
reader->SetFileName("/usr/share/VTKData/Data/SainteHelens.dem");
reader->Update();
......
_OS and debug:_
Ubuntu 12.04 with QT + VTK from repos.
Last Debug gdb:
Thread [1] 7178 [core: 2] (Suspended : Signal : SIGSEGV:Segmentation fault)
vtkDEMReader::ReadProfiles() at 0xb6e3fd31
vtkDEMReader::RequestData() at 0xb6e40bbc
vtkImageAlgorithm::ProcessRequest() at 0xb7aa6af3
vtkExecutive::CallAlgorithm() at 0xb7a64d93
vtkDemandDrivenPipeline::ExecuteData() at 0xb7a580e6
vtkDemandDrivenPipeline::ProcessRequest() at 0xb7a5b74f
vtkStreamingDemandDrivenPipeline::ProcessRequest() at
0xb7bac111
vtkDemandDrivenPipeline::UpdateData() at 0xb7a59fca
vtkStreamingDemandDrivenPipeline::Update() at 0xb7badbf3
vtkExecutive::Update() at 0xb7a654d6
vtkDemandDrivenPipeline::Update() at 0xb7a58f6b
vtkStreamingDemandDrivenPipeline::Update() at 0xb7ba8ffb
vtkAlgorithm::Update() at 0xb79fcb43
SimpleView::SimpleView() at 0x804bb59
main() at 0x804b95c
_Both default versions work:_
http://www.vtk.org/Wiki/VTK/Examples/Cxx/Qt/RenderWindowUIMultipleInheritance
http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/DEMReader ( some tweaking
from vtkImageMapper3D to vtkImageMapper )
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120728/89c868fd/attachment.htm>
More information about the vtkusers
mailing list