Results 1 to 2 of 2

Thread: ui->graphicsView Error: "Internal data stream error."

  1. #1
    Join Date
    Jan 2019
    Posts
    5
    Thanks
    1
    Qt products
    Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default ui->graphicsView Error: "Internal data stream error."

    i use graphicsView to get video stream that codes work fine but when i use tab widget or stacked widget when i click another tab i take Error: "Internal data stream error."...

    if i used qvideowidget i never take an error everything works fine!!! but i dont want to use videowidget!!

    i hope u will understand my english

    whats the problem for graphicView??



    Qt Code:
    1. QMediaPlayer *player1 = new QMediaPlayer;
    2. QGraphicsVideoItem *item = new QGraphicsVideoItem;
    3. QGraphicsScene *scene = new QGraphicsScene(this);
    4.  
    5. QSizeF size(280,160);
    6. item->setSize(size);
    7.  
    8. ui->graphicsView->setScene(scene);
    9.  
    10. scene->addItem(item);
    11.  
    12. const QUrl url1 =QUrl("http://xxx.xx.x.xx:80/mjpg/video.mjpg");
    13. const QNetworkRequest requsetRstp1(url1);
    14.  
    15. player1->setMedia(requsetRstp1);
    16. player1->setVideoOutput(item);
    17. player1->play();
    To copy to clipboard, switch view to plain text mode 

    AND THIS IS THE WORKING CODE BUT I DONT WANT TO USE

    Qt Code:
    1. QVideoWidget *vw1 = new QVideoWidget;
    2. QMediaPlayer *player1 = new QMediaPlayer;
    3.  
    4.  
    5. ui->gridLayout->addWidget(vw1,0,0);
    6. player1->setVideoOutput(vw1);
    7.  
    8. const QUrl url1 =QUrl("http://XX.XXX.XX.XX:8084/mjpg/video.mjpg");
    9. const QNetworkRequest requsetRstp1(url1);
    10. player1->setMedia(requsetRstp1);
    11. player1->play();
    To copy to clipboard, switch view to plain text mode 
    Last edited by hnd; 14th November 2019 at 20:37.

  2. #2
    Join Date
    Jan 2019
    Posts
    5
    Thanks
    1
    Qt products
    Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: ui->graphicsView Error: "Internal data stream error."

    ok. i done my work another way...but the problem is still there

Similar Threads

  1. Replies: 5
    Last Post: 15th August 2014, 04:04
  2. Replies: 3
    Last Post: 28th January 2013, 00:53
  3. Replies: 32
    Last Post: 26th August 2012, 00:10
  4. "Treat wchar_t as Built-in Type" to "yes" link error
    By sungaoyong in forum Qt Programming
    Replies: 1
    Last Post: 5th June 2008, 12:45
  5. QFile Problem~ "Unknow error" in "open(QIODevice::ReadWrite)"
    By fengtian.we in forum Qt Programming
    Replies: 3
    Last Post: 23rd May 2007, 16:58

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.