rem: GST_STREAM_UNLOCK (spad);
context: change_visualization_quality (BaconVideoWidget *bvw){  GstPad *pad, *spad;  GstCaps *caps;  GstStructure *s;  int fps, w, h;  /* get size */  get_visualization_size (bvw, &w, &h, &fps);  /* first unset any old filter, otherwise _get_allowed_caps takes the   * old one into account. */  g_object_set (bvw->priv->vis_capsfilter, "caps", NULL, NULL);  /* see what we can do */  pad = gst_element_get_pad (bvw->priv->vis_element, "src");  spad = gst_element_get_pad (bvw->priv->vis_element, "sink");  caps = gst_pad_get_allowed_caps (pad);  /* fixate */  s = gst_caps_get_structure (caps, 0);  gst_caps_structure_fixate_field_nearest_int (s, "width", w);  gst_caps_structure_fixate_field_nearest_int (s, "height", h);  gst_caps_structure_fixate_field_nearest_double (s, "framerate", fps);  /* set this */  g_object_set (bvw->priv->vis_capsfilter, "caps", caps, NULL);  /* re-negotiate - FIXME: is this still needed? */  GST_STREAM_LOCK (spad);  gst_pad_set_caps (pad, NULL);  GST_STREAM_UNLOCK (spad);  gst_object_unref (spad);  gst_object_unref (pad);}