Results 1 to 6 of 6

Thread: GStreamer, Qt4, QDevelop and C++

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Mar 2009
    Posts
    4
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: GStreamer, Qt4, QDevelop and C++

    Thanks a lot for your advice!

    I finally used QTable-because i need to show there elements that come from a database with multiple fiellds- and it seems to work well.

    About Phonon, I have read about, but I'd rather use just plain gstreamer-that's the specs.

    I will try to use your advice about singleton class.

  2. #2
    Join Date
    Mar 2009
    Posts
    4
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: GStreamer, Qt4, QDevelop and C++

    Going on with the applications, I have the following problem:

    I am trying to make pipelines, so as to record and playback video with sound.
    How exactly can I find the "properties needed to pass to the pipeline to make it work(eg the sound source etc)

    I was given a sample code to do this, I have tried to make changes and adapt it to my machine, but nothing...Any ideas? Is there any way to find all these options somewhere?

    This is the code for creating three pipelines:


    Qt Code:
    1. const char* PLAYBACK =
    2. "filesrc location=foo.avi !"
    3. "avidemux name=demx ! ffdec_mpeg2video ! queue !"
    4. "xvimagesink name=x11w demx. ! queue ! ffdec_mp3 ! alsasink";
    5.  
    6. const char* RECORD = "alsasrc device=plughw:1,0 ! tee name=sndsrc !"
    7. "queue name=sndqueue max-size-buffers=100 ! audiorate !"
    8. " audio/x-raw-int,width=8,rate=16000 ! audioconvert ! ffenc_mp2 ! "
    9. "mx. v4lsrc typefind=true ! tee name=vidsrc ! queue name=vidqueue !"
    10. " videorate ! video/x-raw-yuv,framerate=25/1,width=640,height=480 !"
    11. " ffenc_mpeg2video ! avimux name=mx ! filesink location=foo.avi sndsrc. "
    12. "! queue ! alsasink vidsrc.! queue ! xvimagesink name=x11w";
    13.  
    14. const char* VIEW = "alsasrc device=plughw:1,0 ! "
    15. "queue name=sndqueue max-size-buffers=100 ! audiorate !"
    16. " audio/x-raw-int,width=8,rate=16000 ! alsasink v4lsrc typefind=true"
    17. " ! queue name=vidqueue ! videorate !"
    18. " video/x-raw-yuv,framerate=25/1,width=640,height=480 ! "
    19. "queue ! xvimagesink name=x11w";
    20.  
    21. //code
    22. //code
    23. //code
    24.  
    25. void GstFrame::create_pipeline()
    26. {
    27. if(pipeline) destroy_pipeline();
    28.  
    29. GError *err=0;
    30. pipeline = gst_parse_launch(pipmode,&err);
    31.  
    32. if (err != NULL) {
    33. /* Report error to user, and free error */
    34. cerr << "Unable to create pipeline: " << err->message << endl;
    35. return;
    36. } else {
    37. assert(pipeline!=0);
    38. }
    39. xvimagesink = gst_bin_get_by_name(GST_BIN(pipeline), "x11w");
    40. gst_x_overlay_set_xwindow_id(GST_X_OVERLAY(xvimagesink), gstframe->winId());
    41.  
    42. bus = gst_pipeline_get_bus(GST_PIPELINE(pipeline));
    43. bus_poll_timer->start(50);
    44.  
    45. pipeline_state = GST_STATE_NULL;
    46. set_eos(false);
    47. }
    To copy to clipboard, switch view to plain text mode 
    When I come to run this code, i get pipeline=0, and assert fails.
    no element alsasrc found


    sorry if the post is misplaced, or it is a trivial question, but I have never programmed that stuff before...
    thanks!
    Last edited by wysota; 28th April 2009 at 19:45. Reason: missing [code] tags

  3. #3
    Join Date
    Mar 2009
    Posts
    4
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: GStreamer, Qt4, QDevelop and C++

    Another question please, thanks in advance!

    How can I get an entire row from a TableWidget, by just clicking on it?

    When I click on a row, I need the data inside to be returned so as to pick what I want...

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,360
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: GStreamer, Qt4, QDevelop and C++

    Quote Originally Posted by midiangr View Post
    How can I get an entire row from a TableWidget, by just clicking on it?

    When I click on a row, I need the data inside to be returned so as to pick what I want...
    What did you already try?
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. QDevelop - global variables & help
    By impeteperry in forum Qt-based Software
    Replies: 2
    Last Post: 9th June 2011, 23:28
  2. Code completion for a Qwidget at Qt4 in QDevelop 4.3.1
    By sipklaus in forum Qt-based Software
    Replies: 3
    Last Post: 9th August 2010, 09:46
  3. Steps to configure Ctags with QDevelop
    By gmx234 in forum Qt-based Software
    Replies: 7
    Last Post: 11th June 2008, 22:41
  4. QDevelop auto-complete function and Qt4
    By degs2k4 in forum Qt-based Software
    Replies: 8
    Last Post: 6th May 2008, 18:43
  5. QDevelop - current development
    By ghorwin in forum Qt-based Software
    Replies: 2
    Last Post: 30th March 2007, 14:54

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.