gmerlin
|
00001 /***************************************************************** 00002 * gmerlin - a general purpose multimedia framework and applications 00003 * 00004 * Copyright (c) 2001 - 2011 Members of the Gmerlin project 00005 * gmerlin-general@lists.sourceforge.net 00006 * http://gmerlin.sourceforge.net 00007 * 00008 * This program is free software: you can redistribute it and/or modify 00009 * it under the terms of the GNU General Public License as published by 00010 * the Free Software Foundation, either version 2 of the License, or 00011 * (at your option) any later version. 00012 * 00013 * This program is distributed in the hope that it will be useful, 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00016 * GNU General Public License for more details. 00017 * 00018 * You should have received a copy of the GNU General Public License 00019 * along with this program. If not, see <http://www.gnu.org/licenses/>. 00020 * *****************************************************************/ 00021 00022 00023 #include <gavl/gavl.h> 00024 #include <gmerlin/bggavl.h> 00025 #include <gmerlin/plugin.h> 00026 00027 00028 00041 typedef struct bg_audio_filter_chain_s bg_audio_filter_chain_t; 00042 00049 typedef struct bg_video_filter_chain_s bg_video_filter_chain_t; 00050 00051 /* Audio */ 00052 00060 bg_audio_filter_chain_t * 00061 bg_audio_filter_chain_create(const bg_gavl_audio_options_t * opt, 00062 bg_plugin_registry_t * plugin_reg); 00063 00072 const bg_parameter_info_t * 00073 bg_audio_filter_chain_get_parameters(bg_audio_filter_chain_t * ch); 00074 00085 void bg_audio_filter_chain_set_parameter(void * data, 00086 const char * name, 00087 const bg_parameter_value_t * val); 00088 00098 int bg_audio_filter_chain_need_rebuild(bg_audio_filter_chain_t * ch); 00099 00109 int bg_audio_filter_chain_need_restart(bg_audio_filter_chain_t * ch); 00110 00111 00112 00122 void bg_audio_filter_chain_connect_input(bg_audio_filter_chain_t * ch, 00123 bg_read_audio_func_t func, 00124 void * priv, 00125 int stream); 00126 00133 int bg_audio_filter_chain_init(bg_audio_filter_chain_t * ch, 00134 const gavl_audio_format_t * in_format, 00135 gavl_audio_format_t * out_format); 00136 00142 void bg_audio_filter_chain_set_input_format(bg_audio_filter_chain_t * ch, 00143 const gavl_audio_format_t * in_format); 00144 00154 int bg_audio_filter_chain_set_out_format(bg_audio_filter_chain_t * ch, 00155 const gavl_audio_format_t * out_format); 00156 00165 int bg_audio_filter_chain_read(void * priv, gavl_audio_frame_t* frame, 00166 int stream, 00167 int num_samples); 00168 00173 void bg_audio_filter_chain_destroy(bg_audio_filter_chain_t * ch); 00174 00182 void bg_audio_filter_chain_lock(bg_audio_filter_chain_t * ch); 00183 00191 void bg_audio_filter_chain_unlock(bg_audio_filter_chain_t * ch); 00192 00199 void bg_audio_filter_chain_reset(bg_audio_filter_chain_t * ch); 00200 00201 /* Video */ 00202 00210 bg_video_filter_chain_t * 00211 bg_video_filter_chain_create(const bg_gavl_video_options_t * opt, 00212 bg_plugin_registry_t * plugin_reg); 00213 00222 const bg_parameter_info_t * 00223 bg_video_filter_chain_get_parameters(bg_video_filter_chain_t * ch); 00224 00236 void bg_video_filter_chain_set_parameter(void * data, const char * name, 00237 const bg_parameter_value_t * val); 00238 00248 int bg_video_filter_chain_need_rebuild(bg_video_filter_chain_t * ch); 00249 00259 int bg_video_filter_chain_need_restart(bg_video_filter_chain_t * ch); 00260 00261 00271 void bg_video_filter_chain_connect_input(bg_video_filter_chain_t * ch, 00272 bg_read_video_func_t func, 00273 void * priv, int stream); 00274 00281 int bg_video_filter_chain_init(bg_video_filter_chain_t * ch, 00282 const gavl_video_format_t * in_format, 00283 gavl_video_format_t * out_format); 00284 00290 void bg_video_filter_chain_set_input_format(bg_video_filter_chain_t * ch, 00291 const gavl_video_format_t * in_format); 00292 00301 int bg_video_filter_chain_set_out_format(bg_video_filter_chain_t * ch, 00302 const gavl_video_format_t * out_format); 00303 00304 00312 int bg_video_filter_chain_read(void * priv, gavl_video_frame_t* frame, 00313 int stream); 00314 00319 void bg_video_filter_chain_destroy(bg_video_filter_chain_t * ch); 00320 00328 void bg_video_filter_chain_lock(bg_video_filter_chain_t * ch); 00329 00337 void bg_video_filter_chain_unlock(bg_video_filter_chain_t * ch); 00338 00345 void bg_video_filter_chain_reset(bg_video_filter_chain_t * ch); 00346