summaryrefslogtreecommitdiff
path: root/gst/audiovisualizers
diff options
context:
space:
mode:
authorStefan Sauer <ensonic@users.sf.net>2012-06-24 20:54:24 +0200
committerStefan Sauer <ensonic@users.sf.net>2012-06-24 20:55:37 +0200
commit65fa897f9317ff1a889faaab2909557fb59d7c59 (patch)
tree12c12ec8aea687d192f88e43f9e505377ff3c60f /gst/audiovisualizers
parent2f15ebca96e02ce1375bc9e80053e4074e700a58 (diff)
downloadgstreamer-plugins-bad-65fa897f9317ff1a889faaab2909557fb59d7c59.tar.gz
audiovisualizers: fix input buffer handling
Use _replace instead of _append to fix growing buffers.
Diffstat (limited to 'gst/audiovisualizers')
-rw-r--r--gst/audiovisualizers/README9
-rw-r--r--gst/audiovisualizers/gstbaseaudiovisualizer.c2
2 files changed, 9 insertions, 2 deletions
diff --git a/gst/audiovisualizers/README b/gst/audiovisualizers/README
index 3c59f0e01..264bc4be1 100644
--- a/gst/audiovisualizers/README
+++ b/gst/audiovisualizers/README
@@ -75,6 +75,7 @@ GST_DEBUG="*:2,*scope*:4"
GST_PLUGIN_PATH=$GST_PLUGIN_PATH:$PWD gst-inspect scopes
+== 0.10 ==
GST_PLUGIN_PATH=$GST_PLUGIN_PATH:$PWD gst-launch audiotestsrc ! audioconvert ! wavescope ! colorspace ! ximagesink
GST_PLUGIN_PATH=$GST_PLUGIN_PATH:$PWD gst-launch filesrc location=$HOME/Music/1.mp3 ! decodebin2 ! audioconvert ! wavescope ! colorspace ! ximagesink
GST_PLUGIN_PATH=$GST_PLUGIN_PATH:$PWD gst-launch filesrc location=$HOME/Music/1.mp3 ! decodebin2 ! audioconvert ! wavescope style=lines shade-amount=0x00080402 ! edgetv ! vertigotv ! ximagesink
@@ -87,5 +88,11 @@ GST_PLUGIN_PATH=$GST_PLUGIN_PATH:$PWD gst-launch filesrc location=$HOME/Music/1.
GST_PLUGIN_PATH=$GST_PLUGIN_PATH:$PWD gst-launch filesrc location=$HOME/Music/1.mp3 ! decodebin2 ! tee name=t ! queue ! audioconvert ! synaesthesia ! ximagesink t. ! queue ! synaescope shade-amount=0x00040404 ! colorspace ! ximagesink
-gst-launch filesrc location=$HOME/Music/1.mp3 ! decodebin2 ! tee name=t ! queue ! audioconvert ! wavescope style=color-lines shade-amount=0x00080402 ! alpha alpha=0.5 ! videomixer2 name=m background=black ! colorspace ! vertigotv ! ximagesink t. ! queue ! audioconvert ! spacescope style=color-lines shade-amount=0x00080402 ! alpha alpha=0.5 ! m. t. ! queue ! pulsesink
+== 0.11/1.0 ==
+gst-launch-1.0 audiotestsrc ! audioconvert ! wavescope ! videoconvert ! ximagesink
+
+gst-launch-1.0 filesrc location=$HOME/Music/1.mp3 ! decodebin ! audioconvert ! spectrascope ! videoconvert ! ximagesink
+
+gst-launch-1.0 filesrc location=$HOME/Music/1.mp3 ! decodebin ! tee name=t ! queue ! audioconvert ! wavescope style=color-lines shade-amount=0x00080402 ! alpha alpha=0.5 ! videomixer name=m background=black ! videoconvert ! vertigotv ! ximagesink t. ! queue ! audioconvert ! spacescope style=color-lines shade-amount=0x00080402 ! alpha alpha=0.5 ! m. t. ! queue ! autoaudiosink
+
diff --git a/gst/audiovisualizers/gstbaseaudiovisualizer.c b/gst/audiovisualizers/gstbaseaudiovisualizer.c
index ade18a06a..8ec317140 100644
--- a/gst/audiovisualizers/gstbaseaudiovisualizer.c
+++ b/gst/audiovisualizers/gstbaseaudiovisualizer.c
@@ -881,7 +881,7 @@ gst_base_audio_visualizer_chain (GstPad * pad, GstObject * parent,
if (!(adata = (gpointer) gst_adapter_map (scope->adapter, sbpf)))
break;
- gst_buffer_append_memory (inbuf,
+ gst_buffer_replace_all_memory (inbuf,
gst_memory_new_wrapped (GST_MEMORY_FLAG_READONLY, adata, sbpf, 0,
sbpf, NULL, NULL));