Title: [142391] trunk/Source/WebCore
Revision
142391
Author
ph...@webkit.org
Date
2013-02-10 02:00:29 -0800 (Sun, 10 Feb 2013)

Log Message

[GStreamer] audio is muted when playback rate is between 0.8 and 2.0
https://bugs.webkit.org/show_bug.cgi?id=109362

Reviewed by Martin Robinson.

Don't mute sound if the audio pitch is preserved. If this is not
the case mute it if it's too extreme, as the HTML5 spec recommends.

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::setRate):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (142390 => 142391)


--- trunk/Source/WebCore/ChangeLog	2013-02-10 08:36:47 UTC (rev 142390)
+++ trunk/Source/WebCore/ChangeLog	2013-02-10 10:00:29 UTC (rev 142391)
@@ -1,3 +1,16 @@
+2013-02-10  Philippe Normand  <pnorm...@igalia.com>
+
+        [GStreamer] audio is muted when playback rate is between 0.8 and 2.0
+        https://bugs.webkit.org/show_bug.cgi?id=109362
+
+        Reviewed by Martin Robinson.
+
+        Don't mute sound if the audio pitch is preserved. If this is not
+        the case mute it if it's too extreme, as the HTML5 spec recommends.
+
+        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
+        (WebCore::MediaPlayerPrivateGStreamer::setRate):
+
 2013-02-09  Dominic Mazzoni  <dmazz...@google.com>
 
         fast/encoding/parser-tests-*.html tests sometimes crash

Modified: trunk/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp (142390 => 142391)


--- trunk/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp	2013-02-10 08:36:47 UTC (rev 142390)
+++ trunk/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp	2013-02-10 10:00:29 UTC (rev 142391)
@@ -541,9 +541,9 @@
 
     LOG_MEDIA_MESSAGE("Set Rate to %f", rate);
     if (rate > 0) {
-        // Mute the sound if the playback rate is too extreme.
-        // TODO: in other cases we should perform pitch adjustments.
-        mute = (bool) (rate < 0.8 || rate > 2);
+        // Mute the sound if the playback rate is too extreme and
+        // audio pitch is not adjusted.
+        mute = (!m_preservesPitch && (rate < 0.8 || rate > 2));
         start = currentPosition;
         end = GST_CLOCK_TIME_NONE;
     } else {
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to