Title: [194948] branches/safari-601-branch/Source/WebCore

Diff

Modified: branches/safari-601-branch/Source/WebCore/ChangeLog (194947 => 194948)


--- branches/safari-601-branch/Source/WebCore/ChangeLog	2016-01-13 01:41:44 UTC (rev 194947)
+++ branches/safari-601-branch/Source/WebCore/ChangeLog	2016-01-13 01:41:46 UTC (rev 194948)
@@ -1,5 +1,26 @@
 2016-01-12  Matthew Hanson  <matthew_han...@apple.com>
 
+        Merge r194751. rdar://problem/24043054
+
+    2016-01-07  Brent Fulgham  <bfulg...@apple.com>
+
+            Correct missing EXT_sRGB Format Handling
+            https://bugs.webkit.org/show_bug.cgi?id=152876
+            <rdar://problem/23284389>
+
+            Reviewed by Alex Christensen.
+
+            Tested by WebGL 1.0.4 suite.
+
+            * platform/graphics/GraphicsContext3D.cpp:
+            (getDataFormat): Handle missing SRGB and SRGB_ALPHA cases.
+            * platform/graphics/GraphicsContext3D.h: Add missing SRGB_ALPHA value from the Khronos standard.
+            * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
+            (WebCore::GraphicsContext3D::texImage2D): Add an assertion that we are not being handed
+            an internal format to a method that works with normal formats.
+
+2016-01-12  Matthew Hanson  <matthew_han...@apple.com>
+
         Merge r194745. rdar://problem/24101258
 
     2016-01-07  Jer Noble  <jer.no...@apple.com>

Modified: branches/safari-601-branch/Source/WebCore/platform/graphics/GraphicsContext3D.cpp (194947 => 194948)


--- branches/safari-601-branch/Source/WebCore/platform/graphics/GraphicsContext3D.cpp	2016-01-13 01:41:44 UTC (rev 194947)
+++ branches/safari-601-branch/Source/WebCore/platform/graphics/GraphicsContext3D.cpp	2016-01-13 01:41:46 UTC (rev 194948)
@@ -62,6 +62,12 @@
         case GraphicsContext3D::LUMINANCE_ALPHA:
             dstFormat = GraphicsContext3D::DataFormatRA8;
             break;
+        case GraphicsContext3D::SRGB:
+            dstFormat = GraphicsContext3D::DataFormatRGB8;
+            break;
+        case GraphicsContext3D::SRGB_ALPHA:
+            dstFormat = GraphicsContext3D::DataFormatRGBA8;
+            break;
         default:
             ASSERT_NOT_REACHED();
         }
@@ -92,6 +98,12 @@
         case GraphicsContext3D::LUMINANCE_ALPHA:
             dstFormat = GraphicsContext3D::DataFormatRA16F;
             break;
+        case GraphicsContext3D::SRGB:
+            dstFormat = GraphicsContext3D::DataFormatRGB16F;
+            break;
+        case GraphicsContext3D::SRGB_ALPHA:
+            dstFormat = GraphicsContext3D::DataFormatRGBA16F;
+            break;
         default:
             ASSERT_NOT_REACHED();
         }
@@ -113,6 +125,12 @@
         case GraphicsContext3D::LUMINANCE_ALPHA:
             dstFormat = GraphicsContext3D::DataFormatRA32F;
             break;
+        case GraphicsContext3D::SRGB:
+            dstFormat = GraphicsContext3D::DataFormatRGB32F;
+            break;
+        case GraphicsContext3D::SRGB_ALPHA:
+            dstFormat = GraphicsContext3D::DataFormatRGBA32F;
+            break;
         default:
             ASSERT_NOT_REACHED();
         }

Modified: branches/safari-601-branch/Source/WebCore/platform/graphics/GraphicsContext3D.h (194947 => 194948)


--- branches/safari-601-branch/Source/WebCore/platform/graphics/GraphicsContext3D.h	2016-01-13 01:41:44 UTC (rev 194947)
+++ branches/safari-601-branch/Source/WebCore/platform/graphics/GraphicsContext3D.h	2016-01-13 01:41:46 UTC (rev 194948)
@@ -504,6 +504,7 @@
         FLOAT_MAT4x3 = 0x8B6A,
         SRGB = 0x8C40,
         SRGB8 = 0x8C41,
+        SRGB_ALPHA = 0x8C42,
         SRGB8_ALPHA8 = 0x8C43,
         COMPARE_REF_TO_TEXTURE = 0x884E,
         RGBA32F = 0x8814,

Modified: branches/safari-601-branch/Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGL.cpp (194947 => 194948)


--- branches/safari-601-branch/Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGL.cpp	2016-01-13 01:41:44 UTC (rev 194947)
+++ branches/safari-601-branch/Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGL.cpp	2016-01-13 01:41:46 UTC (rev 194948)
@@ -344,6 +344,7 @@
         type = GL_HALF_FLOAT_ARB;
     }
 
+    ASSERT(format != Extensions3D::SRGB8_ALPHA8_EXT);
     if (format == Extensions3D::SRGB_ALPHA_EXT)
         openGLFormat = GL_RGBA;
     else if (format == Extensions3D::SRGB_EXT)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to