Results 1 to 2 of 2

Thread: problem by executing a simple example of Qwt3dplot, surface plot from mesh file

  1. #1
    Join Date
    Feb 2011
    Qt products

    Default problem by executing a simple example of Qwt3dplot, surface plot from mesh file

    Hello everybody,

    I'm a scientific programmer, who starts now with the Qt environment and the openCV vision library. I successfully compiled and runned an openCV stereovision application, obtaining the depth map ( a 3d point cloud ). My goal now is to plot in 3d this point cloud coming from the cameras and openCV,possibly in real-time. Since I work with Qt I turned towards Qwt3dplot, which seems to be quite powerful....and then started the pain! I compiled easily the "simple plot" example , a surface plot of the Rosembrock function. But when I try to run the example about "Grid data files"...I got segmentation fault.

    I create an istance of NativeReader named "pippo", then I pass to pippo the name of the file where the mesh is....a simple text file:

    4 4
    0 1
    0 1
    0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

    I'm confident that this file is of correct format, in fact no error message comes from the program.
    The Qt Debugger indicates that segmentation occurs AFTER the reading of the file,
    and precisely in the method SurfacePlot::loadFromData which is called immediately after the reading and closing of the mesh file. If someone can this point I'm really out of ideas. :-(

    the code :
    int main(int argc, char **argv)
    QApplication *my=new QApplication(argc,argv);
    QMainWindow a;
    QString ss="blabla";
    QLabel *ee=new QLabel(ss,0);

    Plot3D* plot=0;
    NativeReader pippo;
    pippo(plot, "file.txt");
    return my->exec();


  2. #2
    Join Date
    Feb 2006
    Munich, Germany
    Thanked 872 Times in 820 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    MacOS X Unix/X11 Windows

    Default Re: problem by executing a simple example of Qwt3dplot, surface plot from mesh file

    Better ask on the QwtPlot3D Forum.


Similar Threads

  1. Replies: 13
    Last Post: 21st September 2010, 15:12
  2. Simple Plot after Inputing some Data
    By thebrute in forum Qwt
    Replies: 0
    Last Post: 18th August 2010, 14:29
  3. Replies: 0
    Last Post: 18th March 2010, 14:35
  4. opengl rendering mesh elements contour problem
    By sujan.dasmahapatra in forum Qt Programming
    Replies: 1
    Last Post: 2nd February 2010, 07:07
  5. Replies: 2
    Last Post: 5th September 2009, 11:23

Tags for this Thread


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.