libs/gst/controller/gst-controller.c: fixed boolean again

Original commit message from CVS:
* libs/gst/controller/gst-controller.c:
(gst_controlled_property_set_interpolation_mode),
(gst_controlled_property_new):
fixed boolean again
This commit is contained in:
Stefan Kost 2005-08-31 18:45:41 +00:00
parent e5d298f4f4
commit 41e26035dc
3 changed files with 31 additions and 12 deletions

View file

@ -1,3 +1,10 @@
2005-08-31 Stefan Kost <ensonic@users.sf.net>
* libs/gst/controller/gst-controller.c:
(gst_controlled_property_set_interpolation_mode),
(gst_controlled_property_new):
fixed boolean again
2005-08-31 Thomas Vander Stichele <thomas at apestaart dot org>
* docs/faq/gst-uninstalled:

View file

@ -205,7 +205,7 @@ gst_controlled_property_set_interpolation_mode (GstControlledProperty * self,
self->get = NULL;
self->get_value_array = NULL;
}
if (!self->get || !self->get_value_array) {
if (!self->get) { /* || !self->get_value_array) */
GST_WARNING ("incomplete implementation for type '%d'", self->type);
res = FALSE;
}
@ -306,16 +306,22 @@ gst_controlled_property_new (GObject * object, const gchar * name)
g_value_set_double (&prop->default_value, tpspec->default_value);
}
break;
case G_TYPE_BOOLEAN:{
GParamSpecBoolean *tpspec = G_PARAM_SPEC_BOOLEAN (pspec);
g_value_set_boolean (&prop->default_value, tpspec->default_value);
}
break;
default:
GST_WARNING ("incomplete implementation for paramspec type '%s'",
G_PARAM_SPEC_TYPE_NAME (pspec));
}
/* TODO what about adding a timedval with timestamp=0 and value=default
+ a bit easier for interpolators, example:
* first timestamp is at 5
* requested value if for timestamp=3
* LINEAR and Co. would need to interpolate from default value
to value at timestamp 5
* a bit easier for interpolators, example:
* first timestamp is at 5
* requested value if for timestamp=3
* LINEAR and Co. would need to interpolate from default value to value
* at timestamp 5
*/
signal_name = g_alloca (8 + 1 + strlen (name));
g_sprintf (signal_name, "notify::%s", name);

View file

@ -205,7 +205,7 @@ gst_controlled_property_set_interpolation_mode (GstControlledProperty * self,
self->get = NULL;
self->get_value_array = NULL;
}
if (!self->get || !self->get_value_array) {
if (!self->get) { /* || !self->get_value_array) */
GST_WARNING ("incomplete implementation for type '%d'", self->type);
res = FALSE;
}
@ -306,16 +306,22 @@ gst_controlled_property_new (GObject * object, const gchar * name)
g_value_set_double (&prop->default_value, tpspec->default_value);
}
break;
case G_TYPE_BOOLEAN:{
GParamSpecBoolean *tpspec = G_PARAM_SPEC_BOOLEAN (pspec);
g_value_set_boolean (&prop->default_value, tpspec->default_value);
}
break;
default:
GST_WARNING ("incomplete implementation for paramspec type '%s'",
G_PARAM_SPEC_TYPE_NAME (pspec));
}
/* TODO what about adding a timedval with timestamp=0 and value=default
+ a bit easier for interpolators, example:
* first timestamp is at 5
* requested value if for timestamp=3
* LINEAR and Co. would need to interpolate from default value
to value at timestamp 5
* a bit easier for interpolators, example:
* first timestamp is at 5
* requested value if for timestamp=3
* LINEAR and Co. would need to interpolate from default value to value
* at timestamp 5
*/
signal_name = g_alloca (8 + 1 + strlen (name));
g_sprintf (signal_name, "notify::%s", name);