Results 1 to 8 of 8

Thread: Qt5 eglfs QWT6.1 Empty Plot region

  1. #1
    Join Date
    Oct 2013
    Posts
    4
    Qt products
    Qt5 Qt/Embedded
    Platforms
    Unix/X11 Android

    Default Qt5 eglfs QWT6.1 Empty Plot region

    Hallo,

    I have Qt5.1.0 working with my custom board with AM3359 processor. linaro toolchain was used for cross compiling (came by default with AM335x SDK6 from TI). the tool chain is with hardfp. I cross compiled QWT6.1.0 successfully yesterday and have been trying to get the examples running.

    Unfortunately plots are not displayed in eglfs platform. The plot region is empty. With "-platform linuxfb" the plots are working fine.

    This is the output when running the program in eglfs mode

    root@am335x-evm:~# ./oscilloscope -platform eglfs
    QIconvCodec::convertFromUnicode: using Latin-1 for conversion, iconv_open failed
    QIconvCodec::convertToUnicode: using Latin-1 for conversion, iconv_open failed
    evdevtouch: Using device /dev/input/event0
    min X: 0 max X: 800
    min Y: 0 max Y: 480
    min pressure: 0 max pressure: 0
    device name: ft5x0x_ts
    Protocol type A
    EGLFS: Unable to query physical screen size, defaulting to 100 dpi.
    EGLFS: To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters).
    This plugin does not support propagateSizeHints()
    void QWidgetPrivate::setMask_sys(const QRegion&): Not supported on eglfs.

    The dials and text are getting rendered properly. Only the plots are empty. The result is same for any example / custom application that uses plot. Even just a simple plot with no real time data update is empty.

    If I use linuxfb, the plots are working fine. This is the output when i run with linuxfb platform :

    root@am335x-evm:~# ./oscilloscope -platform linuxfb
    QIconvCodec::convertFromUnicode: using Latin-1 for conversion, iconv_open failed
    QIconvCodec::convertToUnicode: using Latin-1 for conversion, iconv_open failed
    This plugin does not support propagateSizeHints()
    void QWidgetPrivate::setMask_sys(const QRegion&): Not supported on linuxfb.
    void QWidgetPrivate::setMask_sys(const QRegion&): Not supported on linuxfb.

    Has anyone experience something similar ? or point me in the right direction to solve this ?

    Thanks a lot.

    Ram

  2. #2
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,312
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qt5 eglfs QWT6.1 Empty Plot region

    Quote Originally Posted by shriramrs31 View Post
    Only the plots are empty. The result is same for any example / custom application that uses plot.
    Please try the simple_plot example as it is it does absolutely nothing special - no overlays etc.

    What happens, when you disable the internal backing store of the canvas:

    Qt Code:
    1. QwtPlotCanvas *canvas = new QwPlotCanvas();
    2. canvas->setPaintAttribute( QwtPlotCanvas::BackingStore, false );
    3. plot->setCanvas( canvas );
    To copy to clipboard, switch view to plain text mode 
    Uwe

  3. #3
    Join Date
    Oct 2013
    Posts
    4
    Qt products
    Qt5 Qt/Embedded
    Platforms
    Unix/X11 Android

    Default Re: Qt5 eglfs QWT6.1 Empty Plot region

    Hi Uwe,

    Thanks a lot for your quick response.

    Yes I tried simple plot also and with the same result. Scale and Axis are being displayed. I can see a half of the orange dot at 0,0 but the reminder of plot is not there. with -platform linuxfb i see the full plot.

    I also tried the simple plot with your backing store option suggestion like below :

    Qt Code:
    1. #include <qapplication.h>
    2. #include <qwt_plot.h>
    3. #include <qwt_plot_canvas.h>
    4. #include <qwt_plot_curve.h>
    5. #include <qwt_plot_grid.h>
    6. #include <qwt_symbol.h>
    7. #include <qwt_legend.h>
    8.  
    9. int main( int argc, char **argv )
    10. {
    11. QApplication a( argc, argv );
    12.  
    13. QwtPlot plot;
    14.  
    15. QwtPlotCanvas *canvas = new QwtPlotCanvas();
    16. canvas->setPaintAttribute(QwtPlotCanvas::BackingStore, false);
    17. plot.setCanvas( canvas );
    18.  
    19. plot.setTitle( "Plot Demo" );
    20. plot.setCanvasBackground( Qt::white );
    21. plot.setAxisScale( QwtPlot::yLeft, 0.0, 10.0 );
    22. plot.insertLegend( new QwtLegend() );
    23.  
    24. QwtPlotGrid *grid = new QwtPlotGrid();
    25. grid->attach( &plot );
    26.  
    27. QwtPlotCurve *curve = new QwtPlotCurve();
    28. curve->setTitle( "Some Points" );
    29. curve->setPen( Qt::blue, 4 ),
    30. curve->setRenderHint( QwtPlotItem::RenderAntialiased, true );
    31.  
    32. QwtSymbol *symbol = new QwtSymbol( QwtSymbol::Ellipse,
    33. QBrush( Qt::yellow ), QPen( Qt::red, 2 ), QSize( 8, 8 ) );
    34. curve->setSymbol( symbol );
    35.  
    36. QPolygonF points;
    37. points << QPointF( 0.0, 4.4 ) << QPointF( 1.0, 3.0 )
    38. << QPointF( 2.0, 4.5 ) << QPointF( 3.0, 6.8 )
    39. << QPointF( 4.0, 7.9 ) << QPointF( 5.0, 7.1 );
    40. curve->setSamples( points );
    41.  
    42. curve->attach( &plot );
    43.  
    44. plot.resize( 600, 400 );
    45. plot.show();
    46. plot.replot();
    47.  
    48. return a.exec();
    49. }
    To copy to clipboard, switch view to plain text mode 

    Still no plot.

    I know that eglfs can render only one single surface and only in fullscreen mode. Can this be anything to do with this ?

    Ram

  4. #4
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,312
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qt5 eglfs QWT6.1 Empty Plot region

    What exactly do you see:

    1. Scales: yes,
    2. legend: no
    3. title: ?
    4. canvas background: ?
    5. canvas frame ?
    6. curve: ?
    7. grid: ?



    Uwe

  5. #5
    Join Date
    Oct 2013
    Posts
    4
    Qt products
    Qt5 Qt/Embedded
    Platforms
    Unix/X11 Android

    Default Re: Qt5 eglfs QWT6.1 Empty Plot region

    Hallo Uwe,

    Hope these pictures help

    eglfs.jpglinuxfb.jpg

    Thanks.

    Ram

  6. #6
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,312
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qt5 eglfs QWT6.1 Empty Plot region

    The left picture is not the simple_plot example - there are no scales from 0-100. Don't know what this application is, but it probably has no items attached. Should be a problem on your side - eglfs is not to blame.

    The second one shows the simple_plot example - everything seems to be o.k. there, beside that it is not in fullscreen mode and you see some "noise" from the previous application left in your graphics memory in the area, that is not covered by the application.

    Uwe

  7. #7
    Join Date
    Oct 2013
    Posts
    4
    Qt products
    Qt5 Qt/Embedded
    Platforms
    Unix/X11 Android

    Default Re: Qt5 eglfs QWT6.1 Empty Plot region

    Hi Uwe,

    Both the pictures are from executing the same code binary : "simpleplot example". Just executed with different platforms in argument.

    The left pic was executed with "./simpleplot -platform eglfs". The right picture was result of execution "./simpleplot -platform linuxfb".

    linuxfb does not cover the full screen and also does not react to touch. Some settings might be missing here. But, I dont want to use linuxfb for my end application. It was just a test to see what happens with other platforms in argument.

    I have eglfs qt5.0 and qwt 6.1rc3 working for another board. I want to port this application here.

    Thanks a lot and best regards.

    Ram

  8. #8
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,312
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qt5 eglfs QWT6.1 Empty Plot region

    The left image has scales from 0-100 - this is neither a default nor somehow related to application code. I don't see how this somehow depends on your platform plugin.

    I recommend to start your debugger to check where the 100 is from.

    Uwe

Similar Threads

  1. Qt5 on Raspberry Pi EGLFS wrong screen resolution
    By 1994rstefan in forum Qt Programming
    Replies: 3
    Last Post: 21st June 2017, 15:06
  2. eglfs vs wayland for graphicsview
    By denizlitr in forum Qt for Embedded and Mobile
    Replies: 0
    Last Post: 13th June 2013, 09:31
  3. Replies: 2
    Last Post: 19th November 2012, 15:29
  4. qwt6.0.1 legend problem
    By alainstgt in forum Qwt
    Replies: 3
    Last Post: 29th March 2012, 18:52
  5. Problem with qwt6 and saving plot as image
    By discovery in forum Qwt
    Replies: 2
    Last Post: 12th November 2011, 19:18

Tags for this Thread

Bookmarks

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.