Changing properties of Base classes

mariannasb mariannasb at yahoo.com.br
Fri Oct 21 11:54:45 UTC 2016


Hi Arun,

Thanks,

>Maybe this is useful to you:
>
>https://developer.gnome.org/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-class-override-property

Yeah, I took a look at that function as well but from the information I can
find that is only useful for redirecting the set/get_property() functions
and not really to be able to change the default value.

Moreover I can see I mixed a bit the two of the things I wanted to do in my
previous post, so just to explain again:
- I want to set the show-preroll-frame from GstVideoSink to always false
(set default to false and make it readonly)
- And I also want to set max-lateness from GstBaseSink to -1 (note that it
gets set to 20ms by VideoSink)

Calling g_object_set(G_OBJECT(mysink), "max-lateness", -1, NULL) inside my
element init() function works exactly how I want (it also is reflected in
gst-inspect)

However, for some bizarre reason, doing the same with show-preroll-frame
does not work, the property does not seem to get set at all.
If I call it instead from the start() function it gets set upon going to
paused, but then as expected it is not reflected in gst-inspect.
And using g_object_set() does not allow me to make it read only.

By looking at the source I could see a difference in the install_property
calls from BaseSink and VideoSink.
VideoSink is using G_PARAM_CONSTRUCT for the preroll property.
Could this be the cause in their different behaviour?




--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Changing-properties-of-Base-classes-tp4680156p4680160.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list