After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 680777 - Update for bindings
Update for bindings
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-rtsp-server
git master
Other Linux
: Normal normal
: 1.2.3
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2012-07-29 10:09 UTC by Sebastian Pölsterl
Modified: 2014-02-25 22:27 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fixed comments and GIR annotations (13.44 KB, patch)
2012-10-04 15:50 UTC, Sebastian Pölsterl
committed Details | Review
Add boxed types to allow access from bindings (6.27 KB, patch)
2012-10-04 15:51 UTC, Sebastian Pölsterl
reviewed Details | Review
Rename find_media to find_factory (2.89 KB, patch)
2012-10-04 15:51 UTC, Sebastian Pölsterl
committed Details | Review
Update Vala bindings (54.54 KB, patch)
2012-10-04 15:52 UTC, Sebastian Pölsterl
rejected Details | Review
Add additional annotations (3.33 KB, patch)
2012-10-28 12:52 UTC, Sebastian Pölsterl
committed Details | Review

Description Sebastian Pölsterl 2012-07-29 10:09:19 UTC
Using gst-rtsp-server from git and trying to use the generated GIR with Vala results in the following error:

GstRtspServer-1.0.gir:549.7-549.25: warning: Signal `Gst.RTSPMedia.new_state' conflicts with method of the same name
      <virtual-method name="new_state">
      ^^^^^^^^^^^^^^^^^^^
Comment 1 Tim-Philipp Müller 2012-08-05 19:12:35 UTC
Out of curiosity, why has this not been a problem before.  Both have been there since 2010 afaict, so hard to change now.

Also, why is it not a problem for e.g. GtkButton's "clicked" signal and clicked vfunc and gst_button_clicked() ?
Comment 2 Sebastian Pölsterl 2012-08-05 21:53:19 UTC
Having a closer look at https://live.gnome.org/Vala/UpstreamGuide, it says that you have to resolve such issues in the .metadata file. In order to generate a new VAPI for gst-rtsp-server the Vala bindings of its dependencies have to be created first. I couldn't find bindings for gstreamer-1.0, at least they are not part of Vala (as are the 0.10 bindings).
Comment 3 Sebastian Pölsterl 2012-08-05 21:56:14 UTC
(In reply to comment #1)
> Out of curiosity, why has this not been a problem before.  Both have been there
> since 2010 afaict, so hard to change now.
> 
The Vala bindings haven't been updated for ~2 years and never where based on the GIR file, that's what I want to change.
Comment 4 Tim-Philipp Müller 2012-08-05 22:26:25 UTC
For what it's worth, someone else was also working on creating Vala bindings for GStreamer based on the g-i info Don't remember the name right now, but you could ask on IRC.
Comment 5 Sebastian Pölsterl 2012-10-04 15:50:59 UTC
Created attachment 225823 [details] [review]
Fixed comments and GIR annotations
Comment 6 Sebastian Pölsterl 2012-10-04 15:51:24 UTC
Created attachment 225824 [details] [review]
Add boxed types to allow access from bindings
Comment 7 Sebastian Pölsterl 2012-10-04 15:51:48 UTC
Created attachment 225825 [details] [review]
Rename find_media to find_factory
Comment 8 Sebastian Pölsterl 2012-10-04 15:52:08 UTC
Created attachment 225826 [details] [review]
Update Vala bindings
Comment 9 Sebastian Pölsterl 2012-10-04 15:55:32 UTC
The patches add support for Vala bindings based on the GIR file and gstreamer 1.0. I had to do some changes to the API in order to get proper bindings. This should be helpful for pygobject bindings, too.

It's still work in progress as the copy functions of the newly added boxed types are only placeholders!

Patches are also available at https://github.com/sebp/gst-rtsp-server/tree/vala
Comment 10 Wim Taymans 2012-10-05 14:03:31 UTC
Does not seem to want to compile:

....
libtoolize: Remember to add `LT_INIT' to configure.ac.
+ running aclocal -I m4 -I common/m4 ...
+ running autoheader ...
+ running autoconf ...
+ running automake --add-missing --copy...
bindings/vala/Makefile.am:1: ENABLE_VAPIGEN does not appear in AM_CONDITIONAL
Comment 11 Sebastian Pölsterl 2012-10-07 18:17:43 UTC
You are probably missing vapigen.m4 which is available from http://git.gnome.org/browse/vala/tree/vapigen/vapigen.m4
Comment 12 Wim Taymans 2012-10-10 08:37:07 UTC
I have this file: /usr/share/vala-0.18/vapigen.m4

Am I supposed to copy it into our common directory?
Comment 13 Tim-Philipp Müller 2012-10-10 08:49:04 UTC
More like gst-rtsp-server/m4/ 

But I think the vala bindings should be removed from the gst-rtsp-server module altogether and be maintained externally as part of vala or g-i or whatever, just like we do for all other modules.
Comment 14 Sebastian Pölsterl 2012-10-10 15:39:29 UTC
I would be fine maintaining the Vala bindings outside, the annotation and boxed type changes are necessary nevertheless, though.
Comment 15 Tim-Philipp Müller 2012-10-18 18:46:21 UTC
Pushed two of these patches.

About the boxed types for GstRTSPSessionStream, GstRTSPSessionMedia, and GstRTSPMediaStream: maybe those should just be made refcounted ? (and/or turned into mini objects?).

Wim?



 commit 5cec59737ba163409176af4a5e910aae177c8938
 Author: Sebastian Pölsterl <sebp@k-d-w.org>
 Date:   Mon Oct 1 20:03:43 2012 +0200

    rtsp-media-mapping: rename find_media vfunc to find_factory
    
    The virtual method and class method should have the same name
    so it is correctly represented in GIR file
    
    https://bugzilla.gnome.org/show_bug.cgi?id=680777

 commit e11e855ac8b3b3b90fc410631a0608050c4453e8
 Author: Sebastian Pölsterl <sebp@k-d-w.org>
 Date:   Mon Oct 1 19:46:15 2012 +0200

    rtsp-server: fixed comments and GIR annotations
    
    https://bugzilla.gnome.org/show_bug.cgi?id=680777
Comment 16 Tim-Philipp Müller 2012-10-20 18:46:52 UTC
Marking as blocker, since this is ABI relevant (if we want to make it a mini object).
Comment 17 Tim-Philipp Müller 2012-10-20 18:50:10 UTC
Comment on attachment 225826 [details] [review]
Update Vala bindings

Let's reunite the gst-rtsp-server vala bindings with the rest of the GStreamer vala bindings family :)
Comment 18 Sebastian Pölsterl 2012-10-28 12:52:25 UTC
Created attachment 227456 [details] [review]
Add additional annotations

Due to refactoring by Wim in master, defining boxed types is no longer necessary, I updated a couple of annotations, though. I'm going to get the vala bindings accepted vala now.
Comment 19 Tim-Philipp Müller 2012-10-28 15:41:26 UTC
Great, thanks! I guess we can close this then (if not, re-open please).

commit 75598337a90ad7dd390e81063d62c464e52ec56e
Author: Sebastian Pölsterl <sebp@k-d-w.org>
Date:   Sun Oct 28 13:48:44 2012 +0100

    rtsp-server: added annotations to indicate type of ownership transfer of return values
    
    https://bugzilla.gnome.org/show_bug.cgi?id=680777

commit 09718e294dd423b3a46a43f740ccad01b6f96997
Author: Tim-Philipp Müller <tim@centricular.net>
Date:   Sun Oct 28 15:09:04 2012 +0000

    bindings: remove vala bindings
    
    They'll be reunited with the other GStreamer bindings
    
    https://bugzilla.gnome.org/show_bug.cgi?id=680777