static void
ges_transition_clip_class_init (GESTransitionClipClass * klass)
{
  GObjectClass *object_class = G_OBJECT_CLASS (klass);
  GESClipClass *timobj_class = GES_CLIP_CLASS (klass);
  GESContainerClass *container_class = GES_CONTAINER_CLASS (klass);

  g_type_class_add_private (klass, sizeof (GESTransitionClipPrivate));

  object_class->get_property = ges_transition_clip_get_property;
  object_class->set_property = ges_transition_clip_set_property;

  /**
   * GESTransitionClip:vtype:
   *
   * a #GESVideoStandardTransitionType representing the wipe to use
   */
  g_object_class_install_property (object_class, PROP_VTYPE,
      g_param_spec_enum ("vtype", "VType",
          "The SMPTE video wipe to use, or 0 for crossfade",
          GES_VIDEO_STANDARD_TRANSITION_TYPE_TYPE,
          GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE,
          G_PARAM_READWRITE | G_PARAM_CONSTRUCT));

  container_class->child_added = _child_added;
  container_class->child_removed = _child_removed;

  timobj_class->create_track_element = _create_track_element;
  timobj_class->need_fill_track = FALSE;
}
예제 #2
0
static gint
compare_grouping_prio (GType * a, GType * b)
{
    gint ret = 0;
    GObjectClass *aclass = g_type_class_ref (*a);
    GObjectClass *bclass = g_type_class_ref (*b);

    /* We want higher prios to be first */
    if (GES_CONTAINER_CLASS (aclass)->grouping_priority <
            GES_CONTAINER_CLASS (bclass)->grouping_priority)
        ret = 1;
    else if (GES_CONTAINER_CLASS (aclass)->grouping_priority >
             GES_CONTAINER_CLASS (bclass)->grouping_priority)
        ret = -1;

    g_type_class_unref (aclass);
    g_type_class_unref (bclass);
    return ret;
}
예제 #3
0
static void
ges_title_clip_class_init (GESTitleClipClass * klass)
{
  GObjectClass *object_class = G_OBJECT_CLASS (klass);
  GESClipClass *timobj_class = GES_CLIP_CLASS (klass);
  GESContainerClass *container_class = GES_CONTAINER_CLASS (klass);

  g_type_class_add_private (klass, sizeof (GESTitleClipPrivate));

  object_class->get_property = ges_title_clip_get_property;
  object_class->set_property = ges_title_clip_set_property;
  object_class->dispose = ges_title_clip_dispose;

  /**
   * GESTitleClip:text:
   *
   * The text to diplay
   *
   * Deprecated: use ges_track_element_get/set_children_properties on the
   * underlying GESTrackElement instead
   */
  g_object_class_install_property (object_class, PROP_TEXT,
      g_param_spec_string ("text", "Text", "The text to display",
          DEFAULT_TEXT, G_PARAM_READWRITE | G_PARAM_CONSTRUCT |
          GES_PARAM_NO_SERIALIZATION));

  /**
   * GESTitleClip:font-desc:
   *
   * Pango font description string
   *
   * Deprecated: use ges_track_element_get/set_children_properties on the
   * underlying GESTrackElement instead
   */
  g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_FONT_DESC,
      g_param_spec_string ("font-desc", "font description",
          "Pango font description of font to be used for rendering. "
          "See documentation of pango_font_description_from_string "
          "for syntax.", DEFAULT_FONT_DESC,
          G_PARAM_READWRITE | G_PARAM_CONSTRUCT | G_PARAM_STATIC_STRINGS |
          GES_PARAM_NO_SERIALIZATION));

  /**
   * GESTitleClip:valignment:
   *
   * Vertical alignent of the text
   *
   * Deprecated: use ges_track_element_get/set_children_properties on the
   * underlying GESTrackElement instead
   */
  g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_VALIGNMENT,
      g_param_spec_enum ("valignment", "vertical alignment",
          "Vertical alignment of the text", GES_TEXT_VALIGN_TYPE,
          DEFAULT_VALIGNMENT,
          G_PARAM_READWRITE | G_PARAM_CONSTRUCT | G_PARAM_STATIC_STRINGS |
          GES_PARAM_NO_SERIALIZATION));
  /**
   * GESTitleClip:halignment:
   *
   * Horizontal alignment of the text
   *
   * Deprecated: use ges_track_element_get/set_children_properties on the
   * underlying GESTrackElement instead
   */
  g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_HALIGNMENT,
      g_param_spec_enum ("halignment", "horizontal alignment",
          "Horizontal alignment of the text",
          GES_TEXT_HALIGN_TYPE, DEFAULT_HALIGNMENT,
          G_PARAM_READWRITE | G_PARAM_CONSTRUCT | G_PARAM_STATIC_STRINGS |
          GES_PARAM_NO_SERIALIZATION));

  timobj_class->create_track_element = ges_title_clip_create_track_element;

  container_class->child_added = _child_added;
  container_class->child_removed = _child_removed;

  /**
   * GESTitleClip:color:
   *
   * The color of the text
   *
   * Deprecated: use ges_track_element_get/set_children_properties on the
   * underlying GESTrackElement instead
   */

  g_object_class_install_property (object_class, PROP_COLOR,
      g_param_spec_uint ("color", "Color", "The color of the text",
          0, G_MAXUINT32, G_MAXUINT32, G_PARAM_READWRITE | G_PARAM_CONSTRUCT |
          GES_PARAM_NO_SERIALIZATION));

  /**
   * GESTitleClip:background:
   *
   * The background of the text
   *
   * Deprecated: use ges_track_element_get/set_children_properties on the
   * underlying GESTrackElement instead
   */

  g_object_class_install_property (object_class, PROP_BACKGROUND,
      g_param_spec_uint ("background", "Background",
          "The background of the text", 0, G_MAXUINT32, G_MAXUINT32,
          G_PARAM_READWRITE | G_PARAM_CONSTRUCT | GES_PARAM_NO_SERIALIZATION));

  /**
   * GESTitleClip:xpos:
   *
   * The horizontal position of the text
   *
   * Deprecated: use ges_track_element_get/set_children_properties on the
   * underlying GESTrackElement instead
   */

  g_object_class_install_property (object_class, PROP_XPOS,
      g_param_spec_double ("xpos", "Xpos", "The horizontal position",
          0, 1, 0.5, G_PARAM_READWRITE | G_PARAM_CONSTRUCT
          | GES_PARAM_NO_SERIALIZATION));

  /**
   * GESTitleClip:ypos:
   *
   * The vertical position of the text
   *
   * Deprecated: use ges_track_element_get/set_children_properties on the
   * underlying GESTrackElement instead
   */

  g_object_class_install_property (object_class, PROP_YPOS,
      g_param_spec_double ("ypos", "Ypos", "The vertical position",
          0, 1, 0.5, G_PARAM_READWRITE | G_PARAM_CONSTRUCT
          | GES_PARAM_NO_SERIALIZATION));
}