2011-02-02 Steve Lacey <sjl@chromium.org>
authordbates@webkit.org <dbates@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 2 Feb 2011 19:56:36 +0000 (19:56 +0000)
committerdbates@webkit.org <dbates@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 2 Feb 2011 19:56:36 +0000 (19:56 +0000)
        Reviewed by Eric Carlson.

        Implement basic media statistics on media elements.
        https://bugs.webkit.org/show_bug.cgi?id=53322

        * win/tools/vsprops/FeatureDefines.vsprops:
        * win/tools/vsprops/FeatureDefinesCairo.vsprops:
2011-02-02  Steve Lacey  <sjl@chromium.org>

        Reviewed by Eric Carlson.

        Implement basic media statistics on media elements.
        https://bugs.webkit.org/show_bug.cgi?id=53322

        * configure.ac:
2011-02-02  Steve Lacey  <sjl@chromium.org>

        Reviewed by Eric Carlson.

        Implement basic media statistics on media elements.
        https://bugs.webkit.org/show_bug.cgi?id=53322

        * Scripts/build-webkit:
2011-02-02  Steve Lacey  <sjl@chromium.org>

        Reviewed by Eric Carlson.

        Implement basic media statistics on media elements.
        https://bugs.webkit.org/show_bug.cgi?id=53322

        * Configurations/FeatureDefines.xcconfig:
2011-02-02  Steve Lacey  <sjl@chromium.org>

        Reviewed by Eric Carlson.

        Implement basic media statistics on media elements.
        https://bugs.webkit.org/show_bug.cgi?id=53322

        * Configurations/FeatureDefines.xcconfig:
2011-02-02  Steve Lacey  <sjl@chromium.org>

        Reviewed by Eric Carlson.

        Implement basic media statistics on media elements.
        https://bugs.webkit.org/show_bug.cgi?id=53322

        * Configurations/FeatureDefines.xcconfig:
        * GNUmakefile.am:
        * features.pri:
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::webkitAudioBytesDecoded):
        (WebCore::HTMLMediaElement::webkitVideoBytesDecoded):
        * html/HTMLMediaElement.h:
        * html/HTMLMediaElement.idl:
        * html/HTMLVideoElement.cpp:
        (WebCore::HTMLVideoElement::webkitDecodedFrames):
        (WebCore::HTMLVideoElement::webkitDroppedFrames):
        * html/HTMLVideoElement.h:
        * html/HTMLVideoElement.idl:
        * platform/graphics/MediaPlayer.cpp:
        (WebCore::MediaPlayer::decodedFrames):
        (WebCore::MediaPlayer::droppedFrames):
        (WebCore::MediaPlayer::audioBytesDecoded):
        (WebCore::MediaPlayer::videoBytesDecoded):
        * platform/graphics/MediaPlayer.h:
        * platform/graphics/MediaPlayerPrivate.h:
        (WebCore::MediaPlayerPrivateInterface::decodedFrames):
        (WebCore::MediaPlayerPrivateInterface::droppedFrames):
        (WebCore::MediaPlayerPrivateInterface::audioBytesDecoded):
        (WebCore::MediaPlayerPrivateInterface::videoBytesDecoded):
2011-02-02  Steve Lacey  <sjl@chromium.org>

        Reviewed by Eric Carlson.

        Implement basic media statistics on media elements.
        https://bugs.webkit.org/show_bug.cgi?id=53322

        * Configurations/FeatureDefines.xcconfig:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@77394 268f45cc-cd09-0410-ab3c-d52691b4dbfc

26 files changed:
ChangeLog
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/Configurations/FeatureDefines.xcconfig
Source/WebCore/ChangeLog
Source/WebCore/Configurations/FeatureDefines.xcconfig
Source/WebCore/GNUmakefile.am
Source/WebCore/features.pri
Source/WebCore/html/HTMLMediaElement.cpp
Source/WebCore/html/HTMLMediaElement.h
Source/WebCore/html/HTMLMediaElement.idl
Source/WebCore/html/HTMLVideoElement.cpp
Source/WebCore/html/HTMLVideoElement.h
Source/WebCore/html/HTMLVideoElement.idl
Source/WebCore/platform/graphics/MediaPlayer.cpp
Source/WebCore/platform/graphics/MediaPlayer.h
Source/WebCore/platform/graphics/MediaPlayerPrivate.h
Source/WebKit/mac/ChangeLog
Source/WebKit/mac/Configurations/FeatureDefines.xcconfig
Source/WebKit2/ChangeLog
Source/WebKit2/Configurations/FeatureDefines.xcconfig
Tools/ChangeLog
Tools/Scripts/build-webkit
WebKitLibraries/ChangeLog
WebKitLibraries/win/tools/vsprops/FeatureDefines.vsprops
WebKitLibraries/win/tools/vsprops/FeatureDefinesCairo.vsprops
configure.ac

index 95148a5a3085f263667e5dc751def2b823174f13..f421134578738c82be6600f15f6d9cb4e19c2b05 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2011-02-02  Steve Lacey  <sjl@chromium.org>
+
+        Reviewed by Eric Carlson.
+
+        Implement basic media statistics on media elements.
+        https://bugs.webkit.org/show_bug.cgi?id=53322
+
+        * configure.ac:
+
 2011-02-02  Kevin Ollivier  <kevino@theolliviers.com>
 
         [wx] Build fixes for wxWebKit.
index 8747b5c68e45d83d827a5571557646a3dcc8f6db..c637a10e231f772da7392b3c4f55b92fce4cb6f1 100644 (file)
@@ -1,3 +1,12 @@
+2011-02-02  Steve Lacey  <sjl@chromium.org>
+
+        Reviewed by Eric Carlson.
+
+        Implement basic media statistics on media elements.
+        https://bugs.webkit.org/show_bug.cgi?id=53322
+
+        * Configurations/FeatureDefines.xcconfig:
+
 2011-02-02  Kevin Ollivier  <kevino@theolliviers.com>
 
         [wx] Build fixes for wxWebKit.
index 8feca2efdd0ebf36654045978462618ef68accbe..012c66113a2816112f388e72b49576f4cd6e1962 100644 (file)
@@ -106,6 +106,8 @@ ENABLE_SVG_FOREIGN_OBJECT = ENABLE_SVG_FOREIGN_OBJECT;
 ENABLE_SVG_USE = ENABLE_SVG_USE;
 ENABLE_VIDEO = ENABLE_VIDEO;
 
+ENABLE_MEDIA_STATISTICS = ;
+
 ENABLE_WEB_AUDIO = ;
 
 ENABLE_WEB_SOCKETS = $(ENABLE_WEB_SOCKETS_$(REAL_PLATFORM_NAME));
@@ -121,4 +123,4 @@ ENABLE_XHTMLMP = ;
 ENABLE_XPATH = ENABLE_XPATH;
 ENABLE_XSLT = ENABLE_XSLT;
 
-FEATURE_DEFINES = $(ENABLE_LINK_PREFETCH) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_WEBGL) $(ENABLE_3D_RENDERING) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_FILE_SYSTEM) $(ENABLE_FULLSCREEN_API) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_IMAGE_RESIZER) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_SPEECH) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_METER_TAG) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_PROGRESS_TAG) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);
+FEATURE_DEFINES = $(ENABLE_LINK_PREFETCH) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_WEBGL) $(ENABLE_3D_RENDERING) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_FILE_SYSTEM) $(ENABLE_FULLSCREEN_API) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_IMAGE_RESIZER) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_SPEECH) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_METER_TAG) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_PROGRESS_TAG) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_MEDIA_STATISTICS) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);
index f91f4577c5938e1ba47ee3d8d9f54624d500e731..a65d59754d3935b5b12d4ee1795073c858f76416 100644 (file)
@@ -1,3 +1,35 @@
+2011-02-02  Steve Lacey  <sjl@chromium.org>
+
+        Reviewed by Eric Carlson.
+
+        Implement basic media statistics on media elements.
+        https://bugs.webkit.org/show_bug.cgi?id=53322
+
+        * Configurations/FeatureDefines.xcconfig:
+        * GNUmakefile.am:
+        * features.pri:
+        * html/HTMLMediaElement.cpp:
+        (WebCore::HTMLMediaElement::webkitAudioBytesDecoded):
+        (WebCore::HTMLMediaElement::webkitVideoBytesDecoded):
+        * html/HTMLMediaElement.h:
+        * html/HTMLMediaElement.idl:
+        * html/HTMLVideoElement.cpp:
+        (WebCore::HTMLVideoElement::webkitDecodedFrames):
+        (WebCore::HTMLVideoElement::webkitDroppedFrames):
+        * html/HTMLVideoElement.h:
+        * html/HTMLVideoElement.idl:
+        * platform/graphics/MediaPlayer.cpp:
+        (WebCore::MediaPlayer::decodedFrames):
+        (WebCore::MediaPlayer::droppedFrames):
+        (WebCore::MediaPlayer::audioBytesDecoded):
+        (WebCore::MediaPlayer::videoBytesDecoded):
+        * platform/graphics/MediaPlayer.h:
+        * platform/graphics/MediaPlayerPrivate.h:
+        (WebCore::MediaPlayerPrivateInterface::decodedFrames):
+        (WebCore::MediaPlayerPrivateInterface::droppedFrames):
+        (WebCore::MediaPlayerPrivateInterface::audioBytesDecoded):
+        (WebCore::MediaPlayerPrivateInterface::videoBytesDecoded):
+
 2011-02-02  Luiz Agostini  <luiz.agostini@openbossa.org>
 
         Reviewed by David Hyatt.
index 8feca2efdd0ebf36654045978462618ef68accbe..012c66113a2816112f388e72b49576f4cd6e1962 100644 (file)
@@ -106,6 +106,8 @@ ENABLE_SVG_FOREIGN_OBJECT = ENABLE_SVG_FOREIGN_OBJECT;
 ENABLE_SVG_USE = ENABLE_SVG_USE;
 ENABLE_VIDEO = ENABLE_VIDEO;
 
+ENABLE_MEDIA_STATISTICS = ;
+
 ENABLE_WEB_AUDIO = ;
 
 ENABLE_WEB_SOCKETS = $(ENABLE_WEB_SOCKETS_$(REAL_PLATFORM_NAME));
@@ -121,4 +123,4 @@ ENABLE_XHTMLMP = ;
 ENABLE_XPATH = ENABLE_XPATH;
 ENABLE_XSLT = ENABLE_XSLT;
 
-FEATURE_DEFINES = $(ENABLE_LINK_PREFETCH) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_WEBGL) $(ENABLE_3D_RENDERING) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_FILE_SYSTEM) $(ENABLE_FULLSCREEN_API) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_IMAGE_RESIZER) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_SPEECH) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_METER_TAG) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_PROGRESS_TAG) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);
+FEATURE_DEFINES = $(ENABLE_LINK_PREFETCH) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_WEBGL) $(ENABLE_3D_RENDERING) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_FILE_SYSTEM) $(ENABLE_FULLSCREEN_API) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_IMAGE_RESIZER) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_SPEECH) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_METER_TAG) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_PROGRESS_TAG) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_MEDIA_STATISTICS) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);
index 5865e34b472162e5af6b62f93f71d19d017603f4..2b147b2063cfe9402cf78365513afb93862f466e 100644 (file)
@@ -4183,6 +4183,16 @@ webcore_libadd += \
 endif # END USE_GSTREAMER
 endif # END ENABLE_VIDEO
 
+# ----
+# Media Statistics Support
+# ----
+if ENABLE_MEDIA_STATISTICS
+FEATURE_DEFINES += ENABLE_MEDIA_STATISTICS=1
+webcore_cppflags += -DENABLE_MEDIA_STATISTICS=1
+else
+webcore_cppflags += -DENABLE_MEDIA_STATISTICS=0
+endif # END ENABLE_MEDIA_STATISTICS
+
 # ----
 # Javascript Fullscreen Support
 # ----
index 54e967bb40f495edd6d2e4b0adc2330709f7ee09..b3f0e2d915e555dbf517567a04ab7e92aa6ef0b7 100644 (file)
@@ -74,6 +74,7 @@ contains(DEFINES, ENABLE_SINGLE_THREADED=1) {
 !contains(DEFINES, ENABLE_3D_RENDERING=.): DEFINES += ENABLE_3D_RENDERING=1
 !contains(DEFINES, ENABLE_WEB_AUDIO=.): DEFINES += ENABLE_WEB_AUDIO=0
 !contains(DEFINES, ENABLE_WEBGL=.): DEFINES += ENABLE_WEBGL=0
+!contains(DEFINES, ENABLE_MEDIA_STATISTICS=.): DEFINES += ENABLE_MEDIA_STATISTICS=0
 
 # SVG support
 !contains(DEFINES, ENABLE_SVG=0) {
@@ -209,3 +210,4 @@ contains(DEFINES, ENABLE_METER_TAG=1): FEATURE_DEFINES_JAVASCRIPT += ENABLE_METE
 contains(DEFINES, ENABLE_PROGRESS_TAG=1): FEATURE_DEFINES_JAVASCRIPT += ENABLE_PROGRESS_TAG=1
 contains(DEFINES, ENABLE_GEOLOCATION=1): FEATURE_DEFINES_JAVASCRIPT += ENABLE_GEOLOCATION=1
 contains(DEFINES, ENABLE_BLOB=1): FEATURE_DEFINES_JAVASCRIPT += ENABLE_BLOB=1
+contains(DEFINES, ENABLE_MEDIA_STATISTICS=1): FEATURE_DEFINES_JAVASCRIPT += ENABLE_MEDIA_STATISTICS=1
index 9f11aa5e488b9c0183f8fccf982ee4509db61539..f0b703da501f7039a4916094048ada8ed8eb42c5 100644 (file)
@@ -2484,6 +2484,22 @@ bool HTMLMediaElement::webkitHasClosedCaptions() const
     return hasClosedCaptions();
 }
 
+#if ENABLE(MEDIA_STATISTICS)
+unsigned long HTMLMediaElement::webkitAudioBytesDecoded() const
+{
+    if (!m_player)
+        return 0;
+    return m_player->audioBytesDecoded();
+}
+
+unsigned long HTMLMediaElement::webkitVideoBytesDecoded() const
+{
+    if (!m_player)
+        return 0;
+    return m_player->videoBytesDecoded();
+}
+#endif
+
 void HTMLMediaElement::mediaCanStart()
 {
     LOG(Media, "HTMLMediaElement::mediaCanStart");
index e261ad9e1360010b23152d619b9e813bc290315e..9778fd4d384695a2a158067394abd8cea2e09ba2 100644 (file)
@@ -129,6 +129,12 @@ public:
     bool webkitClosedCaptionsVisible() const;
     void setWebkitClosedCaptionsVisible(bool);
 
+#if ENABLE(MEDIA_STATISTICS)
+// Statistics
+    unsigned long webkitAudioBytesDecoded() const;
+    unsigned long webkitVideoBytesDecoded() const;
+#endif
+
 // controls
     bool controls() const;
     void setControls(bool);
index d6ba79dd7f24ac826c2497ac667fab079f22e2a6..9d4602d1dae93cc0e7489e231325c20bc00c3bc9 100644 (file)
@@ -81,5 +81,11 @@ interface [Conditional=VIDEO] HTMLMediaElement : HTMLElement {
 
     readonly attribute boolean webkitHasClosedCaptions;
     attribute boolean webkitClosedCaptionsVisible;
+
+#if defined(ENABLE_MEDIA_STATISTICS) && ENABLE_MEDIA_STATISTICS
+    // The number of bytes consumed by the media decoder.
+    readonly attribute unsigned long webkitAudioBytesDecoded;
+    readonly attribute unsigned long webkitVideoBytesDecoded;
+#endif
 };
 }
index bbda53a59abce5ecdf81af2047b8ea4b1d3e0f45..2004e483a2fdd524c14752e0f780f95dc82eaa3b 100644 (file)
@@ -263,6 +263,24 @@ void HTMLVideoElement::willMoveToNewOwnerDocument()
     HTMLMediaElement::willMoveToNewOwnerDocument();
 }
 
+#if ENABLE(MEDIA_STATISTICS)
+unsigned long HTMLVideoElement::webkitDecodedFrames() const
+{
+    if (!player())
+        return 0;
+
+    return player()->decodedFrames();
+}
+
+unsigned long HTMLVideoElement::webkitDroppedFrames() const
+{
+    if (!player())
+        return 0;
+
+    return player()->droppedFrames();
+}
+#endif
+
 }
 
 #endif
index d893411c45ca0714cdf23c6e64f4d758da87d918..dd38a595f14643e1c3c16d9a16063207e739b9b8 100644 (file)
@@ -55,6 +55,12 @@ public:
     void webkitEnterFullScreen(bool isUserGesture, ExceptionCode& ec) { webkitEnterFullscreen(isUserGesture, ec); }
     void webkitExitFullScreen() { webkitExitFullscreen(); }
 
+#if ENABLE(MEDIA_STATISTICS)
+    // Statistics
+    unsigned long webkitDecodedFrames() const;
+    unsigned long webkitDroppedFrames() const;
+#endif
+
     // Used by canvas to gain raw pixel access
     void paintCurrentFrameInContext(GraphicsContext*, const IntRect&);
 
index 770e4b2d3ebd442c809d35835a1cdd559f28d465..50513d421824c1622249ac51bd7bece9c0f8a7c1 100644 (file)
@@ -42,5 +42,15 @@ module html {
     
         [NeedsUserGestureCheck] void webkitEnterFullScreen() raises (DOMException);
         void webkitExitFullScreen();
+
+#if defined(ENABLE_MEDIA_STATISTICS) && ENABLE_MEDIA_STATISTICS
+        // The number of frames that have been decoded and made available for
+        // playback.
+        readonly attribute unsigned long webkitDecodedFrames;
+
+        // The number of decoded frames that have been dropped by the player
+        // for performance reasons during playback.
+        readonly attribute unsigned long webkitDroppedFrames;
+#endif
     };
 }
index ba19ec550141027990f127056611867e19b21cd9..22bdaf73614204c0891f4cca86fd33116d6bc00a 100644 (file)
@@ -692,6 +692,26 @@ double MediaPlayer::maximumDurationToCacheMediaTime() const
     return m_private->maximumDurationToCacheMediaTime();
 }
 
+unsigned long MediaPlayer::decodedFrames() const
+{
+    return m_private->decodedFrames();
+}
+
+unsigned long MediaPlayer::droppedFrames() const
+{
+    return m_private->droppedFrames();
+}
+
+unsigned long MediaPlayer::audioBytesDecoded() const
+{
+    return m_private->audioBytesDecoded();
+}
+
+unsigned long MediaPlayer::videoBytesDecoded() const
+{
+    return m_private->videoBytesDecoded();
+}
+
 void MediaPlayer::reloadTimerFired(Timer<MediaPlayer>*)
 {
     m_private->cancelLoad();
index 1cbbe15f59612a4281d9e13ff5dead9c9e89595d..8c9484cfe426da69068d385450cbf07e09d12fc7 100644 (file)
@@ -282,6 +282,11 @@ public:
 
     double maximumDurationToCacheMediaTime() const;
 
+    unsigned long decodedFrames() const;
+    unsigned long droppedFrames() const;
+    unsigned long audioBytesDecoded() const;
+    unsigned long videoBytesDecoded() const;
+
 private:
     MediaPlayer(MediaPlayerClient*);
     void loadWithNextMediaEngine(MediaPlayerFactory*);
index 6abe258b7ff2dec74bcaf02f099f8a870e549912..04b2612d13d8286b9867b64d7f3c8034eded344c 100644 (file)
@@ -136,6 +136,10 @@ public:
     // it is OK to calculate movie time before refreshing the cached time.
     virtual double maximumDurationToCacheMediaTime() const { return 0; }
 
+    virtual unsigned long decodedFrames() const { return 0; }
+    virtual unsigned long droppedFrames() const { return 0; }
+    virtual unsigned long audioBytesDecoded() const { return 0; }
+    virtual unsigned long videoBytesDecoded() const { return 0; }
 };
 
 }
index 71a714daecc45d10ac8db2649d637984cc121a66..aa8ff5c6b39776dea02dc1cc27b39db6a9930df1 100644 (file)
@@ -1,3 +1,12 @@
+2011-02-02  Steve Lacey  <sjl@chromium.org>
+
+        Reviewed by Eric Carlson.
+
+        Implement basic media statistics on media elements.
+        https://bugs.webkit.org/show_bug.cgi?id=53322
+
+        * Configurations/FeatureDefines.xcconfig:
+
 2011-02-01  Sam Weinig  <sam@webkit.org>
 
         Reviewed by Beth Dakin.
index 8feca2efdd0ebf36654045978462618ef68accbe..012c66113a2816112f388e72b49576f4cd6e1962 100644 (file)
@@ -106,6 +106,8 @@ ENABLE_SVG_FOREIGN_OBJECT = ENABLE_SVG_FOREIGN_OBJECT;
 ENABLE_SVG_USE = ENABLE_SVG_USE;
 ENABLE_VIDEO = ENABLE_VIDEO;
 
+ENABLE_MEDIA_STATISTICS = ;
+
 ENABLE_WEB_AUDIO = ;
 
 ENABLE_WEB_SOCKETS = $(ENABLE_WEB_SOCKETS_$(REAL_PLATFORM_NAME));
@@ -121,4 +123,4 @@ ENABLE_XHTMLMP = ;
 ENABLE_XPATH = ENABLE_XPATH;
 ENABLE_XSLT = ENABLE_XSLT;
 
-FEATURE_DEFINES = $(ENABLE_LINK_PREFETCH) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_WEBGL) $(ENABLE_3D_RENDERING) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_FILE_SYSTEM) $(ENABLE_FULLSCREEN_API) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_IMAGE_RESIZER) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_SPEECH) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_METER_TAG) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_PROGRESS_TAG) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);
+FEATURE_DEFINES = $(ENABLE_LINK_PREFETCH) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_WEBGL) $(ENABLE_3D_RENDERING) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_FILE_SYSTEM) $(ENABLE_FULLSCREEN_API) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_IMAGE_RESIZER) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_SPEECH) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_METER_TAG) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_PROGRESS_TAG) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_MEDIA_STATISTICS) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);
index a9d63da5cd2ffd0663a1049c34aeac1c727ae1f7..df49c6a8f8103ae3144270564113ef229766fd83 100644 (file)
@@ -1,3 +1,12 @@
+2011-02-02  Steve Lacey  <sjl@chromium.org>
+
+        Reviewed by Eric Carlson.
+
+        Implement basic media statistics on media elements.
+        https://bugs.webkit.org/show_bug.cgi?id=53322
+
+        * Configurations/FeatureDefines.xcconfig:
+
 2011-02-01  Alexey Proskuryakov  <ap@apple.com>
 
         Reviewed by Sam Weinig.
index 8feca2efdd0ebf36654045978462618ef68accbe..012c66113a2816112f388e72b49576f4cd6e1962 100644 (file)
@@ -106,6 +106,8 @@ ENABLE_SVG_FOREIGN_OBJECT = ENABLE_SVG_FOREIGN_OBJECT;
 ENABLE_SVG_USE = ENABLE_SVG_USE;
 ENABLE_VIDEO = ENABLE_VIDEO;
 
+ENABLE_MEDIA_STATISTICS = ;
+
 ENABLE_WEB_AUDIO = ;
 
 ENABLE_WEB_SOCKETS = $(ENABLE_WEB_SOCKETS_$(REAL_PLATFORM_NAME));
@@ -121,4 +123,4 @@ ENABLE_XHTMLMP = ;
 ENABLE_XPATH = ENABLE_XPATH;
 ENABLE_XSLT = ENABLE_XSLT;
 
-FEATURE_DEFINES = $(ENABLE_LINK_PREFETCH) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_WEBGL) $(ENABLE_3D_RENDERING) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_FILE_SYSTEM) $(ENABLE_FULLSCREEN_API) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_IMAGE_RESIZER) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_SPEECH) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_METER_TAG) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_PROGRESS_TAG) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);
+FEATURE_DEFINES = $(ENABLE_LINK_PREFETCH) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_WEBGL) $(ENABLE_3D_RENDERING) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CLIENT_BASED_GEOLOCATION) $(ENABLE_DATABASE) $(ENABLE_DATAGRID) $(ENABLE_DATALIST) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_DOM_STORAGE) $(ENABLE_EVENTSOURCE) $(ENABLE_FILTERS) $(ENABLE_FILE_SYSTEM) $(ENABLE_FULLSCREEN_API) $(ENABLE_GEOLOCATION) $(ENABLE_ICONDATABASE) $(ENABLE_IMAGE_RESIZER) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_SPEECH) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_MATHML) $(ENABLE_METER_TAG) $(ENABLE_NOTIFICATIONS) $(ENABLE_OFFLINE_WEB_APPLICATIONS) $(ENABLE_PROGRESS_TAG) $(ENABLE_SHARED_WORKERS) $(ENABLE_SVG) $(ENABLE_SVG_ANIMATION) $(ENABLE_SVG_AS_IMAGE) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_SVG_FOREIGN_OBJECT) $(ENABLE_SVG_USE) $(ENABLE_VIDEO) $(ENABLE_MEDIA_STATISTICS) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WML) $(ENABLE_WORKERS) $(ENABLE_XHTMLMP) $(ENABLE_XPATH) $(ENABLE_XSLT);
index 21d91afd217bd9116fac159574a990f512fae586..53db646c0dbaf6f6727ed5edf98820a171f525a3 100644 (file)
@@ -1,3 +1,12 @@
+2011-02-02  Steve Lacey  <sjl@chromium.org>
+
+        Reviewed by Eric Carlson.
+
+        Implement basic media statistics on media elements.
+        https://bugs.webkit.org/show_bug.cgi?id=53322
+
+        * Scripts/build-webkit:
+
 2011-02-02  Kevin Ollivier  <kevino@theolliviers.com>
 
         [wx] Build fixes for wxWebKit.
index d788edaed0dbd31b4f2b8e6481de02f0da7d6d0b..32a81e8eae791801d671b91e76882609569ffa0e 100755 (executable)
@@ -85,6 +85,7 @@ my (
     $javaScriptDebuggerSupport,
     $linkPrefetchSupport,
     $mathmlSupport,
+    $mediaStatisticsSupport,
     $meterTagSupport,
     $netscapePluginSupport,
     $notificationsSupport,
@@ -194,6 +195,9 @@ my @features = (
     { option => "mathml", desc => "Toggle MathML support",
       define => "ENABLE_MATHML", default => 1, value => \$mathmlSupport },
 
+    { option => "media-statistics", desc => "Toggle Media Statistics support",
+      define => "ENABLE_MEDIA_STATISTICS", default => 0, value => \$mediaStatisticsSupport },
+
     { option => "meter-tag", desc => "Meter Tag support",
       define => "ENABLE_METER_TAG", default => !isGtk() && !isAppleWinWebKit(), value => \$meterTagSupport },
 
index 074fc3e75b88ba632ccc69b6e5328972e4d3377a..b43b442612e47a382b3fb03dc27333c75fe7d74b 100644 (file)
@@ -1,3 +1,13 @@
+2011-02-02  Steve Lacey  <sjl@chromium.org>
+
+        Reviewed by Eric Carlson.
+
+        Implement basic media statistics on media elements.
+        https://bugs.webkit.org/show_bug.cgi?id=53322
+
+        * win/tools/vsprops/FeatureDefines.vsprops:
+        * win/tools/vsprops/FeatureDefinesCairo.vsprops:
+
 2011-01-28  Anders Carlsson  <andersca@apple.com>
 
         Build fix.
index eaa660b69685dadbee467938d67632016b271151..47355bc312b0a335560fa173c527c72ba8a3b986 100644 (file)
@@ -9,7 +9,7 @@
        >
   <Tool
                Name="VCCLCompilerTool"
-               PreprocessorDefinitions="$(ENABLE_3D_CANVAS);$(ENABLE_3D_RENDERING);$(ENABLE_ACCELERATED_2D_CANVAS);$(ENABLE_BLOB);$(ENABLE_CHANNEL_MESSAGING);$(ENABLE_CLIENT_BASED_GEOLOCATION);$(ENABLE_DATABASE);$(ENABLE_DATAGRID);$(ENABLE_DATALIST);$(ENABLE_DEVICE_ORIENTATION);$(ENABLE_DIRECTORY_UPLOAD);$(ENABLE_DOM_STORAGE);$(ENABLE_EVENTSOURCE);$(ENABLE_FILTERS);$(ENABLE_FILE_SYSTEM);$(ENABLE_FULLSCREEN_API);$(ENABLE_GEOLOCATION);$(ENABLE_ICONDATABASE);$(ENABLE_IMAGE_RESIZER);$(ENABLE_INDEXED_DATABASE);$(ENABLE_INPUT_SPEECH);$(ENABLE_JAVASCRIPT_DEBUGGER);$(ENABLE_LINK_PREFETCH);$(ENABLE_MATHML);$(ENABLE_METER_TAG);$(ENABLE_NOTIFICATIONS);$(ENABLE_OFFLINE_WEB_APPLICATIONS);$(ENABLE_PROGRESS_TAG);$(ENABLE_SHARED_WORKERS);$(ENABLE_SVG);$(ENABLE_SVG_ANIMATION);$(ENABLE_SVG_AS_IMAGE);$(ENABLE_SVG_DOM_OBJC_BINDINGS);$(ENABLE_SVG_FONTS);$(ENABLE_SVG_FOREIGN_OBJECT);$(ENABLE_SVG_USE);$(ENABLE_VIDEO);$(ENABLE_WEB_SOCKETS);$(ENABLE_WEB_TIMING);$(ENABLE_WML);$(ENABLE_WORKERS);$(ENABLE_XHTMLMP);$(ENABLE_XPATH);$(ENABLE_XSLT)"
+               PreprocessorDefinitions="$(ENABLE_3D_CANVAS);$(ENABLE_3D_RENDERING);$(ENABLE_ACCELERATED_2D_CANVAS);$(ENABLE_BLOB);$(ENABLE_CHANNEL_MESSAGING);$(ENABLE_CLIENT_BASED_GEOLOCATION);$(ENABLE_DATABASE);$(ENABLE_DATAGRID);$(ENABLE_DATALIST);$(ENABLE_DEVICE_ORIENTATION);$(ENABLE_DIRECTORY_UPLOAD);$(ENABLE_DOM_STORAGE);$(ENABLE_EVENTSOURCE);$(ENABLE_FILTERS);$(ENABLE_FILE_SYSTEM);$(ENABLE_FULLSCREEN_API);$(ENABLE_GEOLOCATION);$(ENABLE_ICONDATABASE);$(ENABLE_IMAGE_RESIZER);$(ENABLE_INDEXED_DATABASE);$(ENABLE_INPUT_SPEECH);$(ENABLE_JAVASCRIPT_DEBUGGER);$(ENABLE_LINK_PREFETCH);$(ENABLE_MATHML);$(ENABLE_METER_TAG);$(ENABLE_NOTIFICATIONS);$(ENABLE_OFFLINE_WEB_APPLICATIONS);$(ENABLE_PROGRESS_TAG);$(ENABLE_SHARED_WORKERS);$(ENABLE_SVG);$(ENABLE_SVG_ANIMATION);$(ENABLE_SVG_AS_IMAGE);$(ENABLE_SVG_DOM_OBJC_BINDINGS);$(ENABLE_SVG_FONTS);$(ENABLE_SVG_FOREIGN_OBJECT);$(ENABLE_SVG_USE);$(ENABLE_VIDEO);$(ENABLE_MEDIA_STATISTICS);$(ENABLE_WEB_SOCKETS);$(ENABLE_WEB_TIMING);$(ENABLE_WML);$(ENABLE_WORKERS);$(ENABLE_XHTMLMP);$(ENABLE_XPATH);$(ENABLE_XSLT)"
        />
   <UserMacro
                Name="ENABLE_3D_CANVAS"
                Value="ENABLE_VIDEO"
                PerformEnvironmentSet="true"
        />
+  <UserMacro
+               Name="ENABLE_MEDIA_STATISTICS"
+               Value="ENABLE_MEDIA_STATISTICS"
+               PerformEnvironmentSet="true"
+       />
   <UserMacro
                Name="ENABLE_WEB_AUDIO"
                Value=""
index 1dd6532fdeffc2957c3b800e2308e3414f56ac2a..c5f4bc9f30a93506b714d77624c28ae38c20f4e0 100644 (file)
@@ -9,7 +9,7 @@
        >
   <Tool
                Name="VCCLCompilerTool"
-               PreprocessorDefinitions="$(ENABLE_3D_CANVAS);$(ENABLE_3D_RENDERING);$(ENABLE_ACCELERATED_2D_CANVAS);$(ENABLE_BLOB);$(ENABLE_CHANNEL_MESSAGING);$(ENABLE_CLIENT_BASED_GEOLOCATION);$(ENABLE_DATABASE);$(ENABLE_DATAGRID);$(ENABLE_DATALIST);$(ENABLE_DEVICE_ORIENTATION);$(ENABLE_DIRECTORY_UPLOAD);$(ENABLE_DOM_STORAGE);$(ENABLE_EVENTSOURCE);$(ENABLE_FILTERS);$(ENABLE_FILE_SYSTEM);$(ENABLE_FULLSCREEN_API);$(ENABLE_GEOLOCATION);$(ENABLE_ICONDATABASE);$(ENABLE_IMAGE_RESIZER);$(ENABLE_INDEXED_DATABASE);$(ENABLE_INPUT_SPEECH);$(ENABLE_JAVASCRIPT_DEBUGGER);$(ENABLE_LINK_PREFETCH);$(ENABLE_MATHML);$(ENABLE_METER_TAG);$(ENABLE_NOTIFICATIONS);$(ENABLE_OFFLINE_WEB_APPLICATIONS);$(ENABLE_PROGRESS_TAG);$(ENABLE_SHARED_WORKERS);$(ENABLE_SVG);$(ENABLE_SVG_ANIMATION);$(ENABLE_SVG_AS_IMAGE);$(ENABLE_SVG_DOM_OBJC_BINDINGS);$(ENABLE_SVG_FONTS);$(ENABLE_SVG_FOREIGN_OBJECT);$(ENABLE_SVG_USE);$(ENABLE_VIDEO);$(ENABLE_WEB_SOCKETS);$(ENABLE_WEB_TIMING);$(ENABLE_WML);$(ENABLE_WORKERS);$(ENABLE_XHTMLMP);$(ENABLE_XPATH);$(ENABLE_XSLT)"
+               PreprocessorDefinitions="$(ENABLE_3D_CANVAS);$(ENABLE_3D_RENDERING);$(ENABLE_ACCELERATED_2D_CANVAS);$(ENABLE_BLOB);$(ENABLE_CHANNEL_MESSAGING);$(ENABLE_CLIENT_BASED_GEOLOCATION);$(ENABLE_DATABASE);$(ENABLE_DATAGRID);$(ENABLE_DATALIST);$(ENABLE_DEVICE_ORIENTATION);$(ENABLE_DIRECTORY_UPLOAD);$(ENABLE_DOM_STORAGE);$(ENABLE_EVENTSOURCE);$(ENABLE_FILTERS);$(ENABLE_FILE_SYSTEM);$(ENABLE_FULLSCREEN_API);$(ENABLE_GEOLOCATION);$(ENABLE_ICONDATABASE);$(ENABLE_IMAGE_RESIZER);$(ENABLE_INDEXED_DATABASE);$(ENABLE_INPUT_SPEECH);$(ENABLE_JAVASCRIPT_DEBUGGER);$(ENABLE_LINK_PREFETCH);$(ENABLE_MATHML);$(ENABLE_METER_TAG);$(ENABLE_NOTIFICATIONS);$(ENABLE_OFFLINE_WEB_APPLICATIONS);$(ENABLE_PROGRESS_TAG);$(ENABLE_SHARED_WORKERS);$(ENABLE_SVG);$(ENABLE_SVG_ANIMATION);$(ENABLE_SVG_AS_IMAGE);$(ENABLE_SVG_DOM_OBJC_BINDINGS);$(ENABLE_SVG_FONTS);$(ENABLE_SVG_FOREIGN_OBJECT);$(ENABLE_SVG_USE);$(ENABLE_VIDEO);$(ENABLE_MEDIA_STATISTICS);$(ENABLE_WEB_SOCKETS);$(ENABLE_WEB_TIMING);$(ENABLE_WML);$(ENABLE_WORKERS);$(ENABLE_XHTMLMP);$(ENABLE_XPATH);$(ENABLE_XSLT)"
        />
   <UserMacro
                Name="ENABLE_3D_CANVAS"
                Value=""
                PerformEnvironmentSet="true"
        />
+  <UserMacro
+               Name="ENABLE_MEDIA_STATISTICS"
+               Value=""
+               PerformEnvironmentSet="true"
+       />
   <UserMacro
                Name="ENABLE_WEB_AUDIO"
                Value=""
index c0a796e4f9a0724b459c1abb9bb71eec07c9fff0..591d8c3a41adf8dc91b1efa5e1658f663ab9f44b 100644 (file)
@@ -467,6 +467,14 @@ AC_ARG_ENABLE(video,
               [],[enable_video="yes"])
 AC_MSG_RESULT([$enable_video])
 
+# check whether to enable media statistics support
+AC_MSG_CHECKING([whether to enable media statistics support])
+AC_ARG_ENABLE(media_statistics,
+              AC_HELP_STRING([--enable-media-statistics],
+                             [enable support for media statistics [default=no]]),
+              [], [enable_media_statistics="no"])
+AC_MSG_RESULT([$enable_media_statistics])
+
 # check whether to enable Javascript Fullscreen API support
 AC_MSG_CHECKING([whether to enable Fullscreen API support])
 AC_ARG_ENABLE(fullscreen_api,
@@ -964,6 +972,7 @@ AM_CONDITIONAL([ENABLE_FILTERS],[test "$enable_filters" = "yes"])
 AM_CONDITIONAL([ENABLE_GEOLOCATION], [test "$enable_geolocation" = "yes"])
 AM_CONDITIONAL([ENABLE_MATHML], [test "$enable_mathml" = "yes"])
 AM_CONDITIONAL([ENABLE_VIDEO],[test "$enable_video" = "yes"])
+AM_CONDITIONAL([ENABLE_MEDIA_STATISTICS],[test "$enable_media_statistics" = "yes"])
 AM_CONDITIONAL([ENABLE_FULLSCREEN_API],[test "$enable_fullscreen_api" = "yes"])
 AM_CONDITIONAL([ENABLE_NOTIFICATIONS],[test "$enable_notifications" = "yes"])
 AM_CONDITIONAL([ENABLE_ORIENTATION_EVENTS],[test "$enable_orientation_events" = "yes"])
@@ -1039,6 +1048,7 @@ Features:
  Geolocation support                                      : $enable_geolocation
  JavaScript debugger/profiler support                     : $enable_javascript_debugger
  MathML support                                           : $enable_mathml
+ Media statistics                                         : $enable_media_statistics
  HTML5 offline web applications support                   : $enable_offline_web_applications
  HTML5 channel messaging support                          : $enable_channel_messaging
  HTML5 client-side session and persistent storage support : $enable_dom_storage