• Home
  • Raw
  • Download

Lines Matching refs:replace

55 replace=$(echo $name | sed -e 's/_//g')
120 void gst_replace_free (GstReplace *replace);
121 void gst_replace_create_pipeline (GstReplace *replace);
122 void gst_replace_create_pipeline_playbin (GstReplace *replace, const char *uri);
123 void gst_replace_start (GstReplace *replace);
124 void gst_replace_stop (GstReplace *replace);
146 GstReplace *replace;
160 replace = gst_replace_new ();
169 gst_replace_create_pipeline_playbin (replace, uri);
172 gst_replace_create_pipeline (replace);
175 gst_replace_start (replace);
178 replace->main_loop = main_loop;
189 GstReplace *replace;
191 replace = g_new0 (GstReplace, 1);
193 return replace;
197 gst_replace_free (GstReplace *replace)
199 if (replace->source_element) {
200 gst_object_unref (replace->source_element);
201 replace->source_element = NULL;
203 if (replace->sink_element) {
204 gst_object_unref (replace->sink_element);
205 replace->sink_element = NULL;
208 if (replace->pipeline) {
209 gst_element_set_state (replace->pipeline, GST_STATE_NULL);
210 gst_object_unref (replace->pipeline);
211 replace->pipeline = NULL;
213 g_free (replace);
217 gst_replace_create_pipeline_playbin (GstReplace *replace, const char *uri)
233 replace->pipeline = pipeline;
236 replace->bus = gst_pipeline_get_bus (GST_PIPELINE(pipeline));
237 gst_bus_add_watch (replace->bus, gst_replace_handle_message, replace);
239 replace->source_element = gst_bin_get_by_name (GST_BIN(pipeline), "source");
240 g_print("source_element is %p\n", replace->source_element);
243 g_object_set (replace->source_element, "uri", uri, NULL);
247 gst_replace_create_pipeline (GstReplace *replace)
273 replace->pipeline = pipeline;
276 replace->bus = gst_pipeline_get_bus (GST_PIPELINE(pipeline));
277 gst_bus_add_watch (replace->bus, gst_replace_handle_message, replace);
279 replace->source_element = gst_bin_get_by_name (GST_BIN(pipeline), "source");
280 replace->sink_element = gst_bin_get_by_name (GST_BIN(pipeline), "sink");
284 gst_replace_start (GstReplace *replace)
286 gst_element_set_state (replace->pipeline, GST_STATE_READY);
288 replace->timer_id = g_timeout_add (1000, onesecond_timer, replace);
292 gst_replace_stop (GstReplace *replace)
294 gst_element_set_state (replace->pipeline, GST_STATE_NULL);
296 g_source_remove (replace->timer_id);
300 gst_replace_handle_eos (GstReplace *replace)
302 gst_replace_stop (replace);
306 gst_replace_handle_error (GstReplace *replace, GError *error,
310 gst_replace_stop (replace);
314 gst_replace_handle_warning (GstReplace *replace, GError *error,
321 gst_replace_handle_info (GstReplace *replace, GError *error,
328 gst_replace_handle_null_to_ready (GstReplace *replace)
330 gst_element_set_state (replace->pipeline, GST_STATE_PAUSED);
335 gst_replace_handle_ready_to_paused (GstReplace *replace)
337 if (!replace->paused_for_buffering) {
338 gst_element_set_state (replace->pipeline, GST_STATE_PLAYING);
343 gst_replace_handle_paused_to_playing (GstReplace *replace)
349 gst_replace_handle_playing_to_paused (GstReplace *replace)
355 gst_replace_handle_paused_to_ready (GstReplace *replace)
361 gst_replace_handle_ready_to_null (GstReplace *replace)
363 g_main_loop_quit (replace->main_loop);
372 GstReplace *replace = (GstReplace *) data;
376 gst_replace_handle_eos (replace);
384 gst_replace_handle_error (replace, error, debug);
394 gst_replace_handle_warning (replace, error, debug);
404 gst_replace_handle_info (replace, error, debug);
422 if (GST_ELEMENT(message->src) == replace->pipeline) {
428 gst_replace_handle_null_to_ready (replace);
431 gst_replace_handle_ready_to_paused (replace);
434 gst_replace_handle_paused_to_playing (replace);
437 gst_replace_handle_playing_to_paused (replace);
440 gst_replace_handle_paused_to_ready (replace);
443 gst_replace_handle_ready_to_null (replace);
458 if (!replace->paused_for_buffering && percent < 100) {
460 replace->paused_for_buffering = TRUE;
461 gst_element_set_state (replace->pipeline, GST_STATE_PAUSED);
462 } else if (replace->paused_for_buffering && percent == 100) {
464 replace->paused_for_buffering = FALSE;
465 gst_element_set_state (replace->pipeline, GST_STATE_PLAYING);
503 //GstReplace *replace = (GstReplace *)priv;
544 -e "s/replace/$replace/g" >$gstreplace.c