Announcement

Collapse
No announcement yet.

VLC With Phonon Back-End Is Now Ready For Use

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #51
    Originally posted by pingufunkybeat View Post
    Anyway, for those who still haven't figured it out:

    This is how you play an ogg/vorbis file using GStreamer directly: http://gstreamer.freedesktop.org/dat...ion-helloworld

    This is how you play an ogg/vorbis file using phonon: http://techbase.kde.org/Development/...n/Introduction

    That's what "high-level API" means. 4 lines instead of 100 lines. Phonon hides the unnecessary complexity from you, so even people who are not multimedia professionals can play a friggin' mp3. I mean, deleting pipeline objects by hand? g_main_loop_run( loop ) ?!? Just play the bloody thing!

    Not everybody needs frame-accurate seeking, 1000 plugins and advanced postprocessing. People who do not need this use Phonon.
    Is it 100 lines, or is it 10?
    Code:
    import gst, gobject
    
    bin = gst.element_factory_make("playbin")
    bin.set_property("uri", "file:///path/to/coolmusic.ogg")
    bin.set_state(gst.STATE_PLAYING)
    bus = bin.get_bus()
    bus.add_signal_watch()
    main = gobject.MainLoop()
    bus.connect("message::eos", main.quit)
    main.run()

    Comment


    • #52
      Originally posted by TemplarGR View Post
      Gstreamer IS a better solution. If KDE devs had their way in everything, we would remain in HAL for ever... GNOME, while conservative, makes better infrastructure choices...
      Useless KDE remark, as you seem very keen to do.
      Gstreamer has not worked for me for the last five years, as I do not use neither Fedora nor Ubuntu. I tried to install it myself 4 years ago and it doesn't work. It is now packaged by Slack but still doesn't work for me. Ubuntu and Fedora may have taken the trouble of configuring it to make it work, even perhaps patching it to do so, but it just doesn't work out of the box in my experience, while all other multimedia solution on linux, whether xine, mplayer or VLC do.
      Thus, I'm actually very pleased that KDE made Phonon, as I've been able to get multimedia on my systems without the slightest issue for the last seven years, including subtitles in DVDs and MKVs.
      If in the future, the Gstreamer or the VLC backend work better than the xine one for Phonon, then I'll switch and it won't mean I have to change the apps I use, it'll be transparent.
      This is my experience and contrary to you, I won't use it to generalize and say that Gnome or Gstreamer suck. It's just that KDE and Phonon work better for me on my distro of choice.

      Comment


      • #53
        Originally posted by TemplarGR View Post
        Stop spreading FUD please...

        Gstreamer is fine. Your problems belong to the phonon-gstreamer backend, not gstreamer itself. Have you ever used gstreamer in gnome? It just works, without problems.
        What a load of bull. Totem doesn't even play sound without PulseAudio, VLC does.
        Hence VLC > GStreamer.

        GStreamer is shit, PulseAudio is shit, together they are huge shit and GStreamer without PulseAudio is even bigger shit.

        Ever since I removed everything related to PulseAudio and as much from GStreamer as possible, my multimedia-related life is nothing but pleasant.
        VLC as movie player and Phonon-VLC for Juk (music) directly talking to ALSA and everything works just fine.

        Comment


        • #54
          Originally posted by Remco View Post
          Is it 100 lines, or is it 10?
          Well, that depends on the language, of course.

          Since most desktop applications are not written in Python, I took the hello world example from the gstreamer tutorial.

          And there you need to pass cryptic pointers around and deal with event loops explicitly.

          Comment


          • #55
            Originally posted by TemplarGR View Post
            Most people use gstreamer.
            No, most people use Windows' sound system. And considering that VLC also works on Windows and Mac OS X and unlike GStreamer VLC is actually popular there, I doubt that more people use GStreamer than VLC.

            GStreamer is only shipped with Linux distributions because they can ?legally? play MP3s with it (using a proprietary GStreamer plug-in).

            Comment


            • #56
              Originally posted by pingufunkybeat View Post
              Well, that depends on the language, of course.

              Since most desktop applications are not written in Python, I took the hello world example from the gstreamer tutorial.

              And there you need to pass cryptic pointers around and deal with event loops explicitly.
              That's what you get for writing in C. Gstreamer itself does quite a bit of handholding if you want it to.

              Comment


              • #57
                It's still a low-level API, suitable for proper multimedia applications, such as media players, video editing software, etc. In that case, you use a lower-level lib, like gstreamer, or xinelib, or hacked mplayer, or ffmpeg directly.

                But phonon is meant for adding simple multimedia functionality to non-multimedia apps. Playing an ogg in a flashcard program, or showing a short theora video with instructions in a kids' learning game, stuff like that. That's what a high-level API is for. You just want to play the bloody thing, you don't need to know about inner state changes and when to free pointers, that's nonsense.

                The fact is that KDE provides such an API, and that is a good thing because it makes multimedia easy and ensures that a program written for phonon will keep working with all future KDE4 versions.

                Comment


                • #58
                  There is also a phonon-mplayer backend, don't know why but couple of times in this thread people mention mplayer hack, why would mplayer be hack and vlc not, both are media players, not libraries. Maybe it is harder to use mplayer slave mode but SMPlayer did that well both on Windows and Linux, as I read phonon-vlc do not behave well on windows.

                  Phonon can use gstreamer as backend, they are not comparable as was explained in some posts. I use Gnome but don't have gstreamer at all because I do not like it, I do not hate it but don't want it on my system.

                  When I try some program (clementine for example) I prefer xine to gstreamer, but I realy like when application uses ffmpeg, libogg etc. directly, not through gstreamer (deadbeef for example).

                  I prefer to use MPlayer for everything, for analog TV, radio, teletext, movies, thumbnails for nautilus, I use phonon-mplayer for minitube, qmmp with mplayer plugin etc. I use ffmpeg-mt with mplayer so all apps that I use benefit from this, and if all can use my ~/.mplayer/config that is even better.

                  Beside, all frameworks/libs basicaly use ffmpeg. MPlayer devs work on ffmpeg (ffmpeg site was hosted before on mplayerhq if I am not mistaken).
                  There are libs like libplayer from enna project that can use MPlayer, vlc, xine or gstreamer as phonon can do, so please refrain from calling everything that use MPlayer as a hack. It is a hack as is everything else out there.

                  Comment


                  • #59
                    xinelib is actually a library, which was cleanly separated from the rest of xine, precisely so that it can be used as a backend.

                    Mplayer doesn't provide such a library. GStreamer is a set of such libraries. I'm not sure how it is done with VLC.

                    I do like SMPlayer, which works remarkably well in slave mode.

                    Comment


                    • #60
                      Originally posted by pingufunkybeat View Post
                      I'm not sure how it is done with VLC.
                      VLC is also a library.

                      Comment

                      Working...
                      X