Title: [101347] trunk
Revision
101347
Author
commit-qu...@webkit.org
Date
2011-11-29 02:47:32 -0800 (Tue, 29 Nov 2011)

Log Message

[Texmap][EFL] Accelerated compositing support using TextureMapper on EFL port
https://bugs.webkit.org/show_bug.cgi?id=73111

.:

Add feature define for TextureMapper and OpenGL package.

Patch by Hyowon Kim <hw1008....@samsung.com> on 2011-11-29
Reviewed by Noam Rosenthal.

* Source/cmake/OptionsEfl.cmake:

Source/WebCore:

This patch adds Texture Mapper related files to PlatformEfl.cmake
and removes Qt-specific types in TextureMapperNode.cpp.

Patch by Hyowon Kim <hw1008....@samsung.com> on 2011-11-29
Reviewed by Noam Rosenthal.

* PlatformEfl.cmake:
* platform/graphics/GraphicsLayer.cpp:
* platform/graphics/GraphicsLayer.h:
* platform/graphics/efl/GraphicsLayerEfl.cpp: Removed.
* platform/graphics/efl/GraphicsLayerEfl.h: Removed.
* platform/graphics/texmap/TextureMapperNode.cpp:
(WebCore::solveCubicBezierFunction):
(WebCore::solveStepsFunction):

Modified Paths

Removed Paths

Diff

Modified: trunk/ChangeLog (101346 => 101347)


--- trunk/ChangeLog	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/ChangeLog	2011-11-29 10:47:32 UTC (rev 101347)
@@ -1,3 +1,14 @@
+2011-11-29  Hyowon Kim  <hw1008....@samsung.com>
+
+        [Texmap][EFL] Accelerated compositing support using TextureMapper on EFL port
+        https://bugs.webkit.org/show_bug.cgi?id=73111
+
+        Add feature define for TextureMapper and OpenGL package.
+
+        Reviewed by Noam Rosenthal.
+
+        * Source/cmake/OptionsEfl.cmake:
+
 2011-11-29  Roland Steiner  <rolandstei...@chromium.org>
 
         <style scoped>: add ENABLE(STYLE_SCOPED) flag to WebKit

Modified: trunk/Source/WebCore/ChangeLog (101346 => 101347)


--- trunk/Source/WebCore/ChangeLog	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/Source/WebCore/ChangeLog	2011-11-29 10:47:32 UTC (rev 101347)
@@ -1,3 +1,22 @@
+2011-11-29  Hyowon Kim  <hw1008....@samsung.com>
+
+        [Texmap][EFL] Accelerated compositing support using TextureMapper on EFL port
+        https://bugs.webkit.org/show_bug.cgi?id=73111
+
+        This patch adds Texture Mapper related files to PlatformEfl.cmake
+        and removes Qt-specific types in TextureMapperNode.cpp.
+
+        Reviewed by Noam Rosenthal.
+
+        * PlatformEfl.cmake:
+        * platform/graphics/GraphicsLayer.cpp:
+        * platform/graphics/GraphicsLayer.h:
+        * platform/graphics/efl/GraphicsLayerEfl.cpp: Removed.
+        * platform/graphics/efl/GraphicsLayerEfl.h: Removed.
+        * platform/graphics/texmap/TextureMapperNode.cpp:
+        (WebCore::solveCubicBezierFunction):
+        (WebCore::solveStepsFunction):
+
 2011-11-28  Pavel Feldman  <pfeld...@google.com>
 
         Web Inspector: put inspector agents into a vector in the InspectorController.

Modified: trunk/Source/WebCore/PlatformEfl.cmake (101346 => 101347)


--- trunk/Source/WebCore/PlatformEfl.cmake	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/Source/WebCore/PlatformEfl.cmake	2011-11-29 10:47:32 UTC (rev 101347)
@@ -55,7 +55,6 @@
   platform/efl/TemporaryLinkStubs.cpp
   platform/efl/WidgetEfl.cpp
   platform/graphics/ImageSource.cpp
-  platform/graphics/efl/GraphicsLayerEfl.cpp
   platform/graphics/efl/IconEfl.cpp
   platform/graphics/efl/ImageEfl.cpp
   platform/graphics/efl/IntPointEfl.cpp
@@ -208,6 +207,21 @@
   )
 ENDIF ()
 
+IF (WTF_USE_TEXTURE_MAPPER)
+  LIST(APPEND WebCore_INCLUDE_DIRECTORIES
+    ${OPENGL_INCLUDE_DIR}
+    "${WEBCORE_DIR}/platform/graphics/texmap"
+  )
+  LIST(APPEND WebCore_SOURCES
+    platform/graphics/opengl/TextureMapperGL.cpp
+    platform/graphics/texmap/GraphicsLayerTextureMapper.cpp
+    platform/graphics/texmap/TextureMapperNode.cpp
+  )
+   LIST(APPEND WebCore_LIBRARIES
+    ${OPENGL_gl_LIBRARY}
+  )
+ENDIF ()
+
 LIST(APPEND WebCore_LIBRARIES
   ${Cairo_LIBRARIES}
   ${ECORE_X_LIBRARIES}

Modified: trunk/Source/WebCore/platform/graphics/GraphicsLayer.cpp (101346 => 101347)


--- trunk/Source/WebCore/platform/graphics/GraphicsLayer.cpp	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/Source/WebCore/platform/graphics/GraphicsLayer.cpp	2011-11-29 10:47:32 UTC (rev 101347)
@@ -347,7 +347,7 @@
     }
 }
 
-#if PLATFORM(QT)
+#if PLATFORM(QT) || PLATFORM(EFL)
 GraphicsLayer::GraphicsLayerFactory* GraphicsLayer::s_graphicsLayerFactory = 0;
 
 void GraphicsLayer::setGraphicsLayerFactory(GraphicsLayer::GraphicsLayerFactory factory)

Modified: trunk/Source/WebCore/platform/graphics/GraphicsLayer.h (101346 => 101347)


--- trunk/Source/WebCore/platform/graphics/GraphicsLayer.h	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/Source/WebCore/platform/graphics/GraphicsLayer.h	2011-11-29 10:47:32 UTC (rev 101347)
@@ -68,6 +68,11 @@
 class LayerChromium;
 typedef LayerChromium PlatformLayer;
 }
+#elif PLATFORM(EFL)
+namespace WebCore {
+class TextureMapperPlatformLayer;
+typedef TextureMapperPlatformLayer PlatformLayer;
+};
 #else
 typedef void* PlatformLayer;
 #endif
@@ -377,7 +382,7 @@
 
     bool usingTiledLayer() const { return m_usingTiledLayer; }
 
-#if PLATFORM(QT)
+#if PLATFORM(QT) || PLATFORM(EFL)
     // This allows several alternative GraphicsLayer implementations in the same port,
     // e.g. if a different GraphicsLayer implementation is needed in WebKit1 vs. WebKit2.
     typedef PassOwnPtr<GraphicsLayer> GraphicsLayerFactory(GraphicsLayerClient*);
@@ -449,7 +454,7 @@
 
     int m_repaintCount;
 
-#if PLATFORM(QT)
+#if PLATFORM(QT) || PLATFORM(EFL)
     static GraphicsLayer::GraphicsLayerFactory* s_graphicsLayerFactory;
 #endif
 };

Deleted: trunk/Source/WebCore/platform/graphics/efl/GraphicsLayerEfl.cpp (101346 => 101347)


--- trunk/Source/WebCore/platform/graphics/efl/GraphicsLayerEfl.cpp	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/Source/WebCore/platform/graphics/efl/GraphicsLayerEfl.cpp	2011-11-29 10:47:32 UTC (rev 101347)
@@ -1,56 +0,0 @@
-/*
-Copyright (C) 2009-2011 Samsung Electronics
-
-This library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public
-License as published by the Free Software Foundation; either
-version 2 of the License, or (at your option) any later version.
-
-This library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public License
-along with this library; see the file COPYING.LIB.  If not, write to
-the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-Boston, MA 02110-1301, USA.
-*/
-
-#include "config.h"
-
-#if USE(ACCELERATED_COMPOSITING)
-
-#include "GraphicsLayerEfl.h"
-
-#include "NotImplemented.h"
-
-namespace WebCore {
-
-PassOwnPtr<GraphicsLayer> GraphicsLayer::create(GraphicsLayerClient* client)
-{
-    return adoptPtr(new GraphicsLayerEfl(client));
-}
-
-GraphicsLayerEfl::GraphicsLayerEfl(GraphicsLayerClient* client)
-    : GraphicsLayer(client)
-{
-}
-
-GraphicsLayerEfl::~GraphicsLayerEfl()
-{
-}
-
-void GraphicsLayerEfl::setNeedsDisplay()
-{
-    notImplemented();
-}
-
-void GraphicsLayerEfl::setNeedsDisplayInRect(const FloatRect&)
-{
-    notImplemented();
-}
-
-} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)

Deleted: trunk/Source/WebCore/platform/graphics/efl/GraphicsLayerEfl.h (101346 => 101347)


--- trunk/Source/WebCore/platform/graphics/efl/GraphicsLayerEfl.h	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/Source/WebCore/platform/graphics/efl/GraphicsLayerEfl.h	2011-11-29 10:47:32 UTC (rev 101347)
@@ -1,42 +0,0 @@
-/*
-    Copyright (C) 2009-2011 Samsung Electronics
-
-    This library is free software; you can redistribute it and/or
-    modify it under the terms of the GNU Library General Public
-    License as published by the Free Software Foundation; either
-    version 2 of the License, or (at your option) any later version.
-
-    This library is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-    Library General Public License for more details.
-
-    You should have received a copy of the GNU Library General Public License
-    along with this library; see the file COPYING.LIB.  If not, write to
-    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-    Boston, MA 02110-1301, USA.
-*/
-
-#ifndef GraphicsLayerEfl_h
-#define GraphicsLayerEfl_h
-
-#if USE(ACCELERATED_COMPOSITING)
-
-#include "GraphicsLayer.h"
-
-namespace WebCore {
-
-class GraphicsLayerEfl : public GraphicsLayer {
-public:
-    GraphicsLayerEfl(GraphicsLayerClient*);
-    virtual ~GraphicsLayerEfl();
-
-    virtual void setNeedsDisplay();
-    virtual void setNeedsDisplayInRect(const FloatRect&);
-};
-
-} // namespace WebCore
-
-#endif // USE(ACCELERATED_COMPOSITING)
-
-#endif // GraphicsLayerEfl_h

Modified: trunk/Source/WebCore/platform/graphics/texmap/TextureMapperNode.cpp (101346 => 101347)


--- trunk/Source/WebCore/platform/graphics/texmap/TextureMapperNode.cpp	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/Source/WebCore/platform/graphics/texmap/TextureMapperNode.cpp	2011-11-29 10:47:32 UTC (rev 101347)
@@ -823,7 +823,7 @@
     return 1.0 / (200.0 * duration);
 }
 
-static inline double solveCubicBezierFunction(qreal p1x, qreal p1y, qreal p2x, qreal p2y, double t, double duration)
+static inline double solveCubicBezierFunction(double p1x, double p1y, double p2x, double p2y, double t, double duration)
 {
     UnitBezier bezier(p1x, p1y, p2x, p2y);
     return bezier.solve(t, solveEpsilon(duration));
@@ -832,7 +832,7 @@
 static inline double solveStepsFunction(int numSteps, bool stepAtStart, double t)
 {
     if (stepAtStart)
-        return qMin(1.0, (floor(numSteps * t) + 1) / numSteps);
+        return fmin(1.0, (floor(numSteps * t) + 1) / numSteps);
     return floor(numSteps * t) / numSteps;
 }
 

Modified: trunk/Source/cmake/OptionsEfl.cmake (101346 => 101347)


--- trunk/Source/cmake/OptionsEfl.cmake	2011-11-29 10:30:41 UTC (rev 101346)
+++ trunk/Source/cmake/OptionsEfl.cmake	2011-11-29 10:47:32 UTC (rev 101347)
@@ -36,6 +36,7 @@
 FIND_PACKAGE(Threads REQUIRED)
 FIND_PACKAGE(JPEG REQUIRED)
 FIND_PACKAGE(PNG REQUIRED)
+FIND_PACKAGE(OpenGL REQUIRED)
 
 ADD_DEFINITIONS(-DENABLE_CONTEXT_MENUS=0)
 
@@ -48,6 +49,9 @@
 SET(WTF_USE_CAIRO 1)
 ADD_DEFINITIONS(-DWTF_USE_CAIRO=1)
 
+SET(WTF_USE_TEXTURE_MAPPER 1)
+ADD_DEFINITIONS(-DWTF_USE_TEXTURE_MAPPER=1)
+
 SET(JSC_EXECUTABLE_NAME jsc_efl)
 SET(WTF_LIBRARY_NAME wtf_efl)
 SET(_javascript_Core_LIBRARY_NAME _javascript_core_efl)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to