Frameworks/libpurple.framework/Versions/0.6.0/Headers/media-gst.h
changeset 2592 e8d15275025e
parent 2591 f66a716bfc79
child 2593 b4bd28402abc
     1.1 --- a/Frameworks/libpurple.framework/Versions/0.6.0/Headers/media-gst.h	Fri Aug 21 13:24:36 2009 -0700
     1.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 @@ -1,173 +0,0 @@
     1.4 -/**
     1.5 - * @file media-gst.h Media API
     1.6 - * @ingroup core
     1.7 - */
     1.8 -
     1.9 -/* purple
    1.10 - *
    1.11 - * Purple is the legal property of its developers, whose names are too numerous
    1.12 - * to list here.  Please refer to the COPYRIGHT file distributed with this
    1.13 - * source distribution.
    1.14 - *
    1.15 - * This program is free software; you can redistribute it and/or modify
    1.16 - * it under the terms of the GNU General Public License as published by
    1.17 - * the Free Software Foundation; either version 2 of the License, or
    1.18 - * (at your option) any later version.
    1.19 - *
    1.20 - * This program is distributed in the hope that it will be useful,
    1.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    1.23 - * GNU General Public License for more details.
    1.24 - *
    1.25 - * You should have received a copy of the GNU General Public License
    1.26 - * along with this program; if not, write to the Free Software
    1.27 - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
    1.28 - */
    1.29 -
    1.30 -#ifndef _PURPLE_MEDIA_GST_H_
    1.31 -#define _PURPLE_MEDIA_GST_H_
    1.32 -
    1.33 -#include "media.h"
    1.34 -#include "mediamanager.h"
    1.35 -
    1.36 -#include <gst/gst.h>
    1.37 -
    1.38 -G_BEGIN_DECLS
    1.39 -
    1.40 -#define PURPLE_TYPE_MEDIA_ELEMENT_TYPE           (purple_media_element_type_get_type())
    1.41 -#define PURPLE_TYPE_MEDIA_ELEMENT_INFO           (purple_media_element_info_get_type())
    1.42 -#define PURPLE_MEDIA_ELEMENT_INFO(obj)            (G_TYPE_CHECK_INSTANCE_CAST((obj), PURPLE_TYPE_MEDIA_ELEMENT_INFO, PurpleMediaElementInfo))
    1.43 -#define PURPLE_MEDIA_ELEMENT_INFO_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST((klass), PURPLE_TYPE_MEDIA_ELEMENT_INFO, PurpleMediaElementInfo))
    1.44 -#define PURPLE_IS_MEDIA_ELEMENT_INFO(obj)         (G_TYPE_CHECK_INSTANCE_TYPE((obj), PURPLE_TYPE_MEDIA_ELEMENT_INFO))
    1.45 -#define PURPLE_IS_MEDIA_ELEMENT_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), PURPLE_TYPE_MEDIA_ELEMENT_INFO))
    1.46 -#define PURPLE_MEDIA_ELEMENT_INFO_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS((obj), PURPLE_TYPE_MEDIA_ELEMENT_INFO, PurpleMediaElementInfo))
    1.47 -
    1.48 -/** @copydoc _PurpleMediaElementInfo */
    1.49 -typedef struct _PurpleMediaElementInfo PurpleMediaElementInfo;
    1.50 -typedef struct _PurpleMediaElementInfoClass PurpleMediaElementInfoClass;
    1.51 -typedef GstElement *(*PurpleMediaElementCreateCallback)(PurpleMedia *media,
    1.52 -			const gchar *session_id, const gchar *participant);
    1.53 -
    1.54 -typedef enum {
    1.55 -	PURPLE_MEDIA_ELEMENT_NONE = 0,			/** empty element */
    1.56 -	PURPLE_MEDIA_ELEMENT_AUDIO = 1,			/** supports audio */
    1.57 -	PURPLE_MEDIA_ELEMENT_VIDEO = 1 << 1,		/** supports video */
    1.58 -	PURPLE_MEDIA_ELEMENT_AUDIO_VIDEO = PURPLE_MEDIA_ELEMENT_AUDIO
    1.59 -			| PURPLE_MEDIA_ELEMENT_VIDEO, 	/** supports audio and video */
    1.60 -
    1.61 -	PURPLE_MEDIA_ELEMENT_NO_SRCS = 0,		/** has no src pads */
    1.62 -	PURPLE_MEDIA_ELEMENT_ONE_SRC = 1 << 2,		/** has one src pad */
    1.63 -	PURPLE_MEDIA_ELEMENT_MULTI_SRC = 1 << 3, 	/** has multiple src pads */
    1.64 -	PURPLE_MEDIA_ELEMENT_REQUEST_SRC = 1 << 4, 	/** src pads must be requested */
    1.65 -
    1.66 -	PURPLE_MEDIA_ELEMENT_NO_SINKS = 0,		/** has no sink pads */
    1.67 -	PURPLE_MEDIA_ELEMENT_ONE_SINK = 1 << 5, 	/** has one sink pad */
    1.68 -	PURPLE_MEDIA_ELEMENT_MULTI_SINK = 1 << 6, 	/** has multiple sink pads */
    1.69 -	PURPLE_MEDIA_ELEMENT_REQUEST_SINK = 1 << 7, 	/** sink pads must be requested */
    1.70 -
    1.71 -	PURPLE_MEDIA_ELEMENT_UNIQUE = 1 << 8,		/** This element is unique and
    1.72 -							 only one instance of it should
    1.73 -							 be created at a time */
    1.74 -
    1.75 -	PURPLE_MEDIA_ELEMENT_SRC = 1 << 9,		/** can be set as an active src */
    1.76 -	PURPLE_MEDIA_ELEMENT_SINK = 1 << 10,		/** can be set as an active sink */
    1.77 -} PurpleMediaElementType;
    1.78 -
    1.79 -#ifdef __cplusplus
    1.80 -extern "C" {
    1.81 -#endif
    1.82 -
    1.83 -/**
    1.84 - * Gets the element type's GType.
    1.85 - *
    1.86 - * @return The element type's GType.
    1.87 - *
    1.88 - * @since 2.6.0
    1.89 - */
    1.90 -GType purple_media_element_type_get_type(void);
    1.91 -
    1.92 -/**
    1.93 - * Gets the element info's GType.
    1.94 - *
    1.95 - * @return The element info's GType.
    1.96 - *
    1.97 - * @since 2.6.0
    1.98 - */
    1.99 -GType purple_media_element_info_get_type(void);
   1.100 -
   1.101 -/**
   1.102 - * Gets the source from a session
   1.103 - *
   1.104 - * @param media The media object the session is in.
   1.105 - * @param sess_id The session id of the session to get the source from.
   1.106 - *
   1.107 - * @return The source retrieved.
   1.108 - *
   1.109 - * @since 2.6.0
   1.110 - */
   1.111 -GstElement *purple_media_get_src(PurpleMedia *media, const gchar *sess_id);
   1.112 -
   1.113 -/**
   1.114 - * Gets the tee from a given session/stream.
   1.115 - *
   1.116 - * @param media The instance to get the tee from.
   1.117 - * @param session_id The id of the session to get the tee from.
   1.118 - * @param participant Optionally, the participant of the stream to get the tee from.
   1.119 - *
   1.120 - * @return The GstTee element from the chosen session/stream.
   1.121 - *
   1.122 - * @since 2.6.0
   1.123 - */
   1.124 -GstElement *purple_media_get_tee(PurpleMedia *media,
   1.125 -		const gchar *session_id, const gchar *participant);
   1.126 -
   1.127 -
   1.128 -/**
   1.129 - * Gets the pipeline from the media manager.
   1.130 - *
   1.131 - * @param manager The media manager to get the pipeline from.
   1.132 - *
   1.133 - * @return The pipeline.
   1.134 - *
   1.135 - * @since 2.6.0
   1.136 - */
   1.137 -GstElement *purple_media_manager_get_pipeline(PurpleMediaManager *manager);
   1.138 -
   1.139 -/**
   1.140 - * Returns a GStreamer source or sink for audio or video.
   1.141 - *
   1.142 - * @param manager The media manager to use to obtain the source/sink.
   1.143 - * @param type The type of source/sink to get.
   1.144 - *
   1.145 - * @since 2.6.0
   1.146 - */
   1.147 -GstElement *purple_media_manager_get_element(PurpleMediaManager *manager,
   1.148 -		PurpleMediaSessionType type, PurpleMedia *media,
   1.149 -		const gchar *session_id, const gchar *participant);
   1.150 -
   1.151 -PurpleMediaElementInfo *purple_media_manager_get_element_info(
   1.152 -		PurpleMediaManager *manager, const gchar *name);
   1.153 -gboolean purple_media_manager_register_element(PurpleMediaManager *manager,
   1.154 -		PurpleMediaElementInfo *info);
   1.155 -gboolean purple_media_manager_unregister_element(PurpleMediaManager *manager,
   1.156 -		const gchar *name);
   1.157 -gboolean purple_media_manager_set_active_element(PurpleMediaManager *manager,
   1.158 -		PurpleMediaElementInfo *info);
   1.159 -PurpleMediaElementInfo *purple_media_manager_get_active_element(
   1.160 -		PurpleMediaManager *manager, PurpleMediaElementType type);
   1.161 -
   1.162 -gchar *purple_media_element_info_get_id(PurpleMediaElementInfo *info);
   1.163 -gchar *purple_media_element_info_get_name(PurpleMediaElementInfo *info);
   1.164 -PurpleMediaElementType purple_media_element_info_get_element_type(
   1.165 -		PurpleMediaElementInfo *info);
   1.166 -GstElement *purple_media_element_info_call_create(
   1.167 -		PurpleMediaElementInfo *info, PurpleMedia *media,
   1.168 -		const gchar *session_id, const gchar *participant);
   1.169 -
   1.170 -#ifdef __cplusplus
   1.171 -}
   1.172 -#endif
   1.173 -
   1.174 -G_END_DECLS
   1.175 -
   1.176 -#endif  /* _PURPLE_MEDIA_GST_H_ */