-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
More changes for generating gstreamer bindings #159
base: 4
Are you sure you want to change the base?
Conversation
There seems to be a diff now. I checked the docs for the GSignalFlags:
I don't think that is is necessary to generate methods for those. The diff in the actions pipeline confirms that IMHO. Type safe emit calls would be very nice though. |
The borrowing creates code like this: https://github.com/go-gst/go-gst/blob/generated_bindings/pkg/gst/gst.go#L35155 or search for "borrow" in the generated packages. |
@@ -445,6 +445,53 @@ func (conv *Converter) cgoConverter(value *ValueConverted) bool { | |||
} | |||
return true | |||
|
|||
case "Gst.MiniObject", "Gst.Structure", "Gst.Caps", "Gst.Buffer", "Gst.BufferList", "Gst.Memory", "Gst.Message", "Gst.Query", "Gst.Sample": |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI I'm likely not going to accept this PR as-is. This diff is a good study for me to add additional APIs into the GIR generator that would permit this for external generators, but adding edge cases from external generators into gotk4 directly is not sustainable in the long term.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please keep this diff around so I can go back and reference it, but I would strongly recommend moving this to a draft PR so that it doesn't block this PR from being merged.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm completely on your side. I'd like to move the cases for the special types into the go-gst repo, and add some functionality to this PR that allows me to hook into this function.
I'm not quite sure how to do this though, because this is fairly deep into the call stack and quite far from the genmain.Data
. If you have a suggestion please let me know.
will be removed when an appropriate hook is added
…or c_name in docs possible
I got some closure name collisions for the generated Connect callbacks. The collisions only happened on action signals which are only to be emitted AFAIK (please verify).
I also needed to preprocess enum member names so I added a set name.