Changeset 246512 in webkit
- Timestamp:
- Jun 17, 2019 1:23:46 PM (5 years ago)
- Location:
- trunk/Source
- Files:
-
- 2 deleted
- 20 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/ThirdParty/ANGLE/ANGLE.xcodeproj/project.pbxproj
r246501 r246512 2558 2558 312BDB0B15FECAB00097EBC7 /* CopyFiles */, 2559 2559 312BDB0D15FECACE0097EBC7 /* CopyFiles */, 2560 6E28B8742294DD8000717E69 /* ShellScript */,2561 2560 ); 2562 2561 buildRules = ( … … 2596 2595 }; 2597 2596 /* End PBXProject section */ 2598 2599 /* Begin PBXShellScriptBuildPhase section */2600 6E28B8742294DD8000717E69 /* ShellScript */ = {2601 isa = PBXShellScriptBuildPhase;2602 buildActionMask = 2147483647;2603 files = (2604 );2605 inputFileListPaths = (2606 );2607 inputPaths = (2608 );2609 outputFileListPaths = (2610 );2611 outputPaths = (2612 );2613 runOnlyForDeploymentPostprocessing = 0;2614 shellPath = /bin/sh;2615 shellScript = "/bin/sh $SRCROOT/adjust-angle-include-paths.sh\n";2616 };2617 /* End PBXShellScriptBuildPhase section */2618 2597 2619 2598 /* Begin PBXSourcesBuildPhase section */ -
trunk/Source/ThirdParty/ANGLE/ChangeLog
r246501 r246512 1 2019-06-17 Ryan Haddad <ryanhaddad@apple.com> 2 3 Unreviewed, rolling out r246501. 4 5 Breaks Apple internal builds. 6 7 Reverted changeset: 8 9 "Support using ANGLE as the backend for the WebGL 10 implementation" 11 https://bugs.webkit.org/show_bug.cgi?id=197755 12 https://trac.webkit.org/changeset/246501 13 1 14 2019-06-17 Kenneth Russell <kbr@chromium.org> 2 15 -
trunk/Source/WTF/ChangeLog
r246501 r246512 1 2019-06-17 Ryan Haddad <ryanhaddad@apple.com> 2 3 Unreviewed, rolling out r246501. 4 5 Breaks Apple internal builds. 6 7 Reverted changeset: 8 9 "Support using ANGLE as the backend for the WebGL 10 implementation" 11 https://bugs.webkit.org/show_bug.cgi?id=197755 12 https://trac.webkit.org/changeset/246501 13 1 14 2019-06-17 Kenneth Russell <kbr@chromium.org> 2 15 -
trunk/Source/WTF/wtf/Platform.h
r246501 r246512 1102 1102 1103 1103 #if ENABLE(WEBGL) 1104 /* USE_ANGLE=1 uses ANGLE for the WebGL backend.1105 It replaces USE_OPENGL, USE_OPENGL_ES and USE_EGL. */1106 1104 #if PLATFORM(MAC) 1107 1105 #define USE_OPENGL 1 1108 1106 #define USE_OPENGL_ES 0 1109 #define USE_ANGLE 01110 1107 #elif PLATFORM(IOSMAC) && __has_include(<OpenGL/OpenGL.h>) 1111 1108 #define USE_OPENGL 1 1112 1109 #define USE_OPENGL_ES 0 1113 #define USE_ANGLE 01114 1110 #else 1115 1111 #define USE_OPENGL 0 1116 1112 #define USE_OPENGL_ES 1 1117 #define USE_ANGLE 01118 1113 #endif 1119 1114 #if PLATFORM(COCOA) … … 1136 1131 #define USE_OPENGL_ES 1 1137 1132 #define USE_EGL 1 1138 #endif1139 1140 #if ENABLE(WEBGL)1141 #if (USE_ANGLE && (USE_OPENGL || USE_OPENGL_ES || (defined(USE_EGL) && USE_EGL)))1142 #error USE_ANGLE is incompatible with USE_OPENGL, USE_OPENGL_ES and USE_EGL1143 #endif1144 1133 #endif 1145 1134 -
trunk/Source/WebCore/ChangeLog
r246501 r246512 1 2019-06-17 Ryan Haddad <ryanhaddad@apple.com> 2 3 Unreviewed, rolling out r246501. 4 5 Breaks Apple internal builds. 6 7 Reverted changeset: 8 9 "Support using ANGLE as the backend for the WebGL 10 implementation" 11 https://bugs.webkit.org/show_bug.cgi?id=197755 12 https://trac.webkit.org/changeset/246501 13 1 14 2019-06-17 Kenneth Russell <kbr@chromium.org> 2 15 -
trunk/Source/WebCore/SourcesCocoa.txt
r246501 r246512 220 220 221 221 platform/graphics/MediaPlaybackTargetPicker.cpp 222 223 // These sources can't be unified with others in case they are merged224 // with files that use the system OpenGL.225 platform/graphics/angle/Extensions3DANGLE.cpp @no-unify226 platform/graphics/angle/GraphicsContext3DANGLE.cpp @no-unify227 platform/graphics/angle/TemporaryANGLESetting.cpp @no-unify228 222 229 223 platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.mm @no-unify -
trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj
r246501 r246512 2008 2008 6E67D2A71280E8A4008758F7 /* Extensions3DOpenGL.h in Headers */ = {isa = PBXBuildFile; fileRef = 6E67D2A51280E8A4008758F7 /* Extensions3DOpenGL.h */; }; 2009 2009 6E67D2A91280E8BD008758F7 /* Extensions3D.h in Headers */ = {isa = PBXBuildFile; fileRef = 6E67D2A81280E8BD008758F7 /* Extensions3D.h */; }; 2010 6E72F54C229DCD0C00B3E151 /* Extensions3DANGLE.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 6E27F243229C9F8400F1F632 /* Extensions3DANGLE.cpp */; };2011 6E72F54E229DCD1000B3E151 /* GraphicsContext3DANGLE.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 6E27F2422298CE4B00F1F632 /* GraphicsContext3DANGLE.cpp */; };2012 6E72F54F229DCD1300B3E151 /* TemporaryANGLESetting.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 6E290861229DB950000986E2 /* TemporaryANGLESetting.cpp */; };2013 6E72F550229DCD1700B3E151 /* Extensions3DANGLE.h in Headers */ = {isa = PBXBuildFile; fileRef = 6E27F244229C9F8D00F1F632 /* Extensions3DANGLE.h */; };2014 6E72F551229DCD1A00B3E151 /* TemporaryANGLESetting.h in Headers */ = {isa = PBXBuildFile; fileRef = 6E290863229DB970000986E2 /* TemporaryANGLESetting.h */; };2015 2010 6E84E9E117668BF100815B68 /* RasterShape.h in Headers */ = {isa = PBXBuildFile; fileRef = 6E84E9DF17668BAD00815B68 /* RasterShape.h */; settings = {ATTRIBUTES = (Private, ); }; }; 2016 2011 6EBF0E4812A8926100DB1709 /* OESTextureFloat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 6EBF0E4512A8926100DB1709 /* OESTextureFloat.cpp */; }; … … 9106 9101 6E21C6BF1126338500A7BE02 /* GraphicsContext3D.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GraphicsContext3D.cpp; sourceTree = "<group>"; }; 9107 9102 6E21C6C11126339900A7BE02 /* GraphicsContext3DCG.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GraphicsContext3DCG.cpp; sourceTree = "<group>"; }; 9108 6E27F2422298CE4B00F1F632 /* GraphicsContext3DANGLE.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GraphicsContext3DANGLE.cpp; sourceTree = "<group>"; };9109 6E27F243229C9F8400F1F632 /* Extensions3DANGLE.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Extensions3DANGLE.cpp; sourceTree = "<group>"; };9110 6E27F244229C9F8D00F1F632 /* Extensions3DANGLE.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Extensions3DANGLE.h; sourceTree = "<group>"; };9111 6E290861229DB950000986E2 /* TemporaryANGLESetting.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TemporaryANGLESetting.cpp; sourceTree = "<group>"; };9112 6E290863229DB970000986E2 /* TemporaryANGLESetting.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TemporaryANGLESetting.h; sourceTree = "<group>"; };9113 9103 6E3FAD3614733F4000E42306 /* JSWebGLCompressedTextureS3TC.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSWebGLCompressedTextureS3TC.cpp; sourceTree = "<group>"; }; 9114 9104 6E3FAD3614733F4000E42307 /* JSWebGLDepthTexture.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSWebGLDepthTexture.cpp; sourceTree = "<group>"; }; … … 20415 20405 usesTabs = 0; 20416 20406 }; 20417 6E27F2412298CE2E00F1F632 /* angle */ = {20418 isa = PBXGroup;20419 children = (20420 6E27F243229C9F8400F1F632 /* Extensions3DANGLE.cpp */,20421 6E27F244229C9F8D00F1F632 /* Extensions3DANGLE.h */,20422 6E27F2422298CE4B00F1F632 /* GraphicsContext3DANGLE.cpp */,20423 6E290861229DB950000986E2 /* TemporaryANGLESetting.cpp */,20424 6E290863229DB970000986E2 /* TemporaryANGLESetting.h */,20425 );20426 path = angle;20427 sourceTree = "<group>";20428 };20429 20407 6FCFC055212DACC2007695D2 /* floats */ = { 20430 20408 isa = PBXGroup; … … 24378 24356 isa = PBXGroup; 24379 24357 children = ( 24380 6E27F2412298CE2E00F1F632 /* angle */,24381 24358 076F0D0812B8192700C26AA4 /* avfoundation */, 24382 24359 499B3EC0128CCC1800E726C2 /* ca */, … … 29062 29039 31DCDF441DA1C45400EA5B93 /* ExtendedColor.h in Headers */, 29063 29040 6E67D2A91280E8BD008758F7 /* Extensions3D.h in Headers */, 29064 6E72F550229DCD1700B3E151 /* Extensions3DANGLE.h in Headers */,29065 29041 6E67D2A71280E8A4008758F7 /* Extensions3DOpenGL.h in Headers */, 29066 29042 44DAB5B215A623580097C1E4 /* Extensions3DOpenGLCommon.h in Headers */, … … 31842 31818 7CC564B818BABEA6001B9652 /* TelephoneNumberDetector.h in Headers */, 31843 31819 C65046A9167BFB5500CC2A4D /* TemplateContentDocumentFragment.h in Headers */, 31844 6E72F551229DCD1A00B3E151 /* TemporaryANGLESetting.h in Headers */,31845 31820 26E944DD1AC4B4EA007B85B5 /* Term.h in Headers */, 31846 31821 6550B6A6099DF0270090D781 /* Text.h in Headers */, … … 32742 32717 515BE18F1D54F5FB00DD7C68 /* EmptyGamepadProvider.cpp in Sources */, 32743 32718 724ED32C1A3A7E5400F5F13C /* EXTBlendMinMax.cpp in Sources */, 32744 6E72F54C229DCD0C00B3E151 /* Extensions3DANGLE.cpp in Sources */,32745 32719 72F1ADA21A3904DC00014E18 /* EXTFragDepth.cpp in Sources */, 32746 32720 5C4304B0191AC908000E2BC0 /* EXTShaderTextureLOD.cpp in Sources */, … … 32756 32730 D084033C221CBF6900007205 /* GPUBuffer.cpp in Sources */, 32757 32731 6E21C6C01126338500A7BE02 /* GraphicsContext3D.cpp in Sources */, 32758 6E72F54E229DCD1000B3E151 /* GraphicsContext3DANGLE.cpp in Sources */,32759 32732 7C3E510B18DF8F3500C112F7 /* HTMLConverter.mm in Sources */, 32760 32733 A8D06B3A0A265DCD005E7203 /* HTMLNames.cpp in Sources */, … … 32841 32814 CDC8B5AA18047FF10016E685 /* SourceBufferPrivateAVFObjC.mm in Sources */, 32842 32815 A833C7CA0A2CF06B00D57664 /* SVGNames.cpp in Sources */, 32843 6E72F54F229DCD1300B3E151 /* TemporaryANGLESetting.cpp in Sources */,32844 32816 9759E93F14EF1CF80026A2DD /* TextTrack.cpp in Sources */, 32845 32817 9759E94214EF1CF80026A2DD /* TextTrackCue.cpp in Sources */, -
trunk/Source/WebCore/platform/graphics/ANGLEWebKitBridge.h
r246501 r246512 39 39 #if USE(OPENGL_ES) 40 40 #import <OpenGLES/ES2/glext.h> 41 #el if USE(OPENGL)41 #else 42 42 #include <OpenGL/gl.h> 43 #elif USE(ANGLE)44 #include <ANGLE/gl2.h>45 #else46 #error Unsupported configuration47 43 #endif 48 44 -
trunk/Source/WebCore/platform/graphics/GraphicsContext3D.h
r246501 r246512 65 65 #endif // USE(OPENGL_ES) 66 66 67 #if USE(OPENGL)67 #if !USE(OPENGL_ES) 68 68 typedef struct _CGLContextObject *CGLContextObj; 69 69 typedef CGLContextObj PlatformGraphicsContext3D; 70 #endif // USE(OPENGL) 71 72 #if USE(ANGLE) 73 typedef void* PlatformGraphicsContext3D; 74 #endif // USE(ANGLE) 70 #endif 75 71 76 72 OBJC_CLASS CALayer; … … 99 95 #if !PLATFORM(COCOA) && USE(OPENGL_ES) 100 96 class Extensions3DOpenGLES; 101 #el if USE(OPENGL) || (PLATFORM(COCOA) && USE(OPENGL_ES))97 #else 102 98 class Extensions3DOpenGL; 103 #elif USE(ANGLE)104 class Extensions3DANGLE;105 99 #endif 106 100 class HostWindow; … … 1438 1432 #if !PLATFORM(COCOA) && USE(OPENGL_ES) 1439 1433 friend class Extensions3DOpenGLES; 1434 std::unique_ptr<Extensions3DOpenGLES> m_extensions; 1435 #else 1436 friend class Extensions3DOpenGL; 1437 std::unique_ptr<Extensions3DOpenGL> m_extensions; 1438 #endif 1440 1439 friend class Extensions3DOpenGLCommon; 1441 std::unique_ptr<Extensions3DOpenGLES> m_extensions;1442 #elif USE(OPENGL) || (PLATFORM(COCOA) && USE(OPENGL_ES))1443 friend class Extensions3DOpenGL;1444 friend class Extensions3DOpenGLCommon;1445 std::unique_ptr<Extensions3DOpenGL> m_extensions;1446 #elif USE(ANGLE)1447 friend class Extensions3DANGLE;1448 std::unique_ptr<Extensions3DANGLE> m_extensions;1449 #endif1450 1440 1451 1441 GraphicsContext3DAttributes m_attrs; -
trunk/Source/WebCore/platform/graphics/GraphicsContext3DManager.cpp
r246501 r246512 36 36 #endif 37 37 38 #if PLATFORM(MAC) && USE(OPENGL)38 #if PLATFORM(MAC) 39 39 #include "SwitchingGPUClient.h" 40 40 #include <OpenGL/OpenGL.h> … … 135 135 void GraphicsContext3DManager::updateAllContexts() 136 136 { 137 // FIXME: determine whether to do anything when using ANGLE. 138 #if PLATFORM(MAC) && USE(OPENGL) 137 #if PLATFORM(MAC) 139 138 for (const auto& context : m_contexts) { 140 139 context->updateCGLContext(); … … 219 218 void GraphicsContext3DManager::updateHighPerformanceState() 220 219 { 221 #if PLATFORM(MAC) && USE(OPENGL)220 #if PLATFORM(MAC) 222 221 if (!hasLowAndHighPowerGPUs()) 223 222 return; … … 259 258 260 259 m_requestingHighPerformance = false; 261 #if PLATFORM(MAC) && USE(OPENGL)260 #if PLATFORM(MAC) 262 261 SwitchingGPUClient::singleton().releaseHighPerformanceGPU(); 263 262 #endif -
trunk/Source/WebCore/platform/graphics/cocoa/GraphicsContext3DCocoa.mm
r246501 r246512 29 29 #import "GraphicsContext3D.h" 30 30 31 #if PLATFORM(IOS_FAMILY) && !USE(ANGLE)31 #if PLATFORM(IOS_FAMILY) 32 32 #import "GraphicsContext3DIOS.h" 33 33 #endif 34 34 35 35 #import "CanvasRenderingContext.h" 36 #import "Extensions3DOpenGL.h" 36 37 #import "GraphicsContext.h" 37 38 #import "GraphicsContext3DManager.h" … … 56 57 #import <QuartzCore/QuartzCore.h> 57 58 #import <pal/spi/ios/OpenGLESSPI.h> 58 #el if USE(OPENGL)59 #else 59 60 #import <IOKit/IOKitLib.h> 60 61 #import <OpenGL/CGLRenderers.h> 61 62 #import <OpenGL/gl.h> 62 #elif USE(ANGLE)63 #include <ANGLE/entry_points_gles_2_0_autogen.h>64 #endif65 66 #if USE(OPENGL_ES) || USE(OPENGL)67 #include "Extensions3DOpenGL.h"68 #elif USE(ANGLE)69 #include "Extensions3DANGLE.h"70 63 #endif 71 64 … … 169 162 } 170 163 171 #if PLATFORM(MAC) && USE(OPENGL)164 #if PLATFORM(MAC) 172 165 173 166 #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 101300 … … 248 241 #endif 249 242 250 #endif // PLATFORM(MAC) && USE(OPENGL)243 #endif // !PLATFORM(MAC) 251 244 252 245 GraphicsContext3D::GraphicsContext3D(GraphicsContext3DAttributes attrs, HostWindow* hostWindow, GraphicsContext3D::RenderStyle, GraphicsContext3D* sharedContext) … … 254 247 , m_private(std::make_unique<GraphicsContext3DPrivate>(this)) 255 248 { 256 #if USE(ANGLE)257 if (m_attrs.isWebGL2)258 m_compiler = ANGLEWebKitBridge(SH_ESSL_OUTPUT, SH_WEBGL2_SPEC);259 else260 m_compiler = ANGLEWebKitBridge(SH_ESSL_OUTPUT);261 #else262 249 #if PLATFORM(IOS_FAMILY) 263 250 if (m_attrs.isWebGL2) … … 268 255 if (m_attrs.isWebGL2) 269 256 m_compiler = ANGLEWebKitBridge(SH_GLSL_410_CORE_OUTPUT, SH_WEBGL2_SPEC); 270 #endif // PLATFORM(IOS_FAMILY) 271 #endif // USE(ANGLE) 257 #endif 272 258 273 259 #if USE(OPENGL_ES) … … 282 268 if (m_attrs.isWebGL2) 283 269 ::glEnable(GraphicsContext3D::PRIMITIVE_RESTART_FIXED_INDEX); 284 #el if USE(OPENGL)270 #else 285 271 Vector<CGLPixelFormatAttribute> attribs; 286 272 CGLPixelFormatObj pixelFormatObj = 0; … … 368 354 ::glEnable(GraphicsContext3D::PRIMITIVE_RESTART); 369 355 370 #elif USE(ANGLE) 371 372 // FIXME: implement context setup via ANGLE. 373 UNUSED_PARAM(hostWindow); 374 UNUSED_PARAM(sharedContext); 375 376 #endif 356 #endif // !USE(OPENGL_ES) 377 357 378 358 validateAttributes(); … … 394 374 #if USE(OPENGL_ES) 395 375 ::glGenRenderbuffers(1, &m_texture); 396 #el if USE(OPENGL)376 #else 397 377 ::glGenTextures(1, &m_texture); 398 378 // We bind to GL_TEXTURE_RECTANGLE_EXT rather than TEXTURE_2D because … … 404 384 ::glTexParameteri(GL_TEXTURE_RECTANGLE_EXT, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); 405 385 ::glBindTexture(GL_TEXTURE_RECTANGLE_EXT, 0); 406 #elif USE(ANGLE) 407 // FIXME: implement back buffer setup via ANGLE. 408 #else 409 #error Unsupported configuration 410 #endif 411 412 #if USE(OPENGL) || USE(OPENGL_ES) 386 #endif 387 413 388 // Create the framebuffer object. 414 389 ::glGenFramebuffersEXT(1, &m_fbo); … … 428 403 ::glGenRenderbuffersEXT(1, &m_multisampleDepthStencilBuffer); 429 404 } 430 #endif // USE(ANGLE) || USE(OPENGL_ES) 431 405 432 406 // ANGLE initialization. 433 407 … … 458 432 #endif 459 433 460 #if USE(OPENGL) || USE(OPENGL_ES)461 434 ::glClearColor(0, 0, 0, 0); 462 #endif463 435 464 436 LOG(WebGL, "Created a GraphicsContext3D (%p).", this); … … 474 446 [m_contextObj renderbufferStorage:GL_RENDERBUFFER fromDrawable:nil]; 475 447 ::glDeleteRenderbuffers(1, &m_texture); 476 #el if USE(OPENGL)448 #else 477 449 CGLSetCurrentContext(m_contextObj); 478 450 ::glDeleteTextures(1, &m_texture); 479 #elif USE(ANGLE) 480 // FIXME: make context current via ANGLE. 481 #endif 482 483 #if USE(OPENGL) || USE(OPENGL_ES) 451 #endif 484 452 if (m_attrs.antialias) { 485 453 ::glDeleteRenderbuffersEXT(1, &m_multisampleColorBuffer); … … 492 460 } 493 461 ::glDeleteFramebuffersEXT(1, &m_fbo); 494 #endif495 496 462 #if USE(OPENGL_ES) 497 463 [EAGLContext setCurrentContext:0]; 498 464 [static_cast<EAGLContext*>(m_contextObj) release]; 499 #el if USE(OPENGL)465 #else 500 466 CGLSetCurrentContext(0); 501 467 CGLDestroyContext(m_contextObj); 502 #elif USE(ANGLE)503 // FIXME: implement context teardown via ANGLE.504 468 #endif 505 469 [m_webGLLayer setContext:nullptr]; … … 533 497 if ([EAGLContext currentContext] != m_contextObj) 534 498 return [EAGLContext setCurrentContext:static_cast<EAGLContext*>(m_contextObj)]; 535 #el if USE(OPENGL)499 #else 536 500 CGLContextObj currentContext = CGLGetCurrentContext(); 537 501 if (currentContext != m_contextObj) 538 502 return CGLSetCurrentContext(m_contextObj) == kCGLNoError; 539 #elif USE(ANGLE)540 // FIXME: implement making context current via ANGLE.541 503 #endif 542 504 return true; … … 551 513 #if USE(OPENGL) 552 514 CGLSetCurrentContext(0); 553 #el if USE(OPENGL_ES)515 #else 554 516 [EAGLContext setCurrentContext:0]; 555 #elif USE(ANGLE)556 // FIXME: implement forced context loss via ANGLE.557 517 #endif 558 518 return; … … 577 537 CGLSetCurrentContext(0); 578 538 } 579 #el if USE(OPENGL_ES)539 #else 580 540 EAGLContext* currentContext = static_cast<EAGLContext*>(PlatformGraphicsContext3D()); 581 541 [currentContext getParameter:kEAGLCPGPURestartStatus to:&restartStatus]; … … 585 545 [EAGLContext setCurrentContext:0]; 586 546 } 587 #elif USE(ANGLE)588 // FIXME: check via KHR_robustness.589 restartStatus = 0;590 547 #endif 591 548 } … … 704 661 if (!m_contextObj) 705 662 return; 706 #if USE(ANGLE)707 UNUSED_PARAM(displayID);708 #else709 663 #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 101300 710 // FIXME: figure out whether to integrate more code into ANGLE to have this effect.711 #if USE(OPENGL)712 664 if (!m_hasSwitchedToHighPerformanceGPU) 713 665 setGPUByRegistryID(m_contextObj, CGLGetPixelFormat(m_contextObj), gpuIDForDisplay(displayID)); 714 #endif715 666 #else 716 667 setGPUByDisplayMask(m_contextObj, CGLGetPixelFormat(m_contextObj), displayMaskForDisplay(displayID)); 717 #endif // __MAC_OS_X_VERSION_MIN_REQUIRED >= 101300 718 #endif // USE(ANGLE) 668 #endif 719 669 } 720 670 #endif // !PLATFORM(MAC) -
trunk/Source/WebCore/platform/graphics/cocoa/WebGLLayer.h
r246501 r246512 39 39 #if USE(OPENGL) 40 40 @interface WebGLLayer : CALayer 41 #el if USE(OPENGL_ES)41 #else 42 42 @interface WebGLLayer : CAEAGLLayer 43 #elif USE(ANGLE) && PLATFORM(MAC)44 @interface WebGLLayer : CALayer45 #elif USE(ANGLE) && PLATFORM(IOS_FAMILY)46 @interface WebGLLayer : CAEAGLLayer47 #else48 #error Unsupported platform49 43 #endif 50 44 { -
trunk/Source/WebCore/platform/graphics/cocoa/WebGLLayer.mm
r246501 r246512 137 137 [self bindFramebufferToNextAvailableSurface]; 138 138 } 139 #el if USE(OPENGL_ES)139 #else 140 140 _context->presentRenderbuffer(); 141 #elif USE(ANGLE)142 // FIXME: display rendering results via ANGLE.143 141 #endif 144 142 -
trunk/Source/WebCore/platform/graphics/cv/TextureCacheCV.mm
r246501 r246512 40 40 #if USE(OPENGL_ES) 41 41 CVReturn error = CVOpenGLESTextureCacheCreate(kCFAllocatorDefault, nullptr, context.platformGraphicsContext3D(), nullptr, &cache); 42 #el if USE(OPENGL)42 #else 43 43 CVReturn error = CVOpenGLTextureCacheCreate(kCFAllocatorDefault, nullptr, context.platformGraphicsContext3D(), CGLGetPixelFormat(context.platformGraphicsContext3D()), nullptr, &cache); 44 #elif USE(ANGLE)45 // FIXME: figure out how to do this integrating via ANGLE.46 UNUSED_PARAM(context);47 CVReturn error = kCVReturnSuccess + 1;48 44 #endif 49 45 if (error != kCVReturnSuccess) … … 68 64 if (kCVReturnSuccess != CVOpenGLESTextureCacheCreateTextureFromImage(kCFAllocatorDefault, m_cache.get(), image, nullptr, outputTarget, internalFormat, width, height, format, type, level, &bareVideoTexture)) 69 65 return nullptr; 70 #el if USE(OPENGL)66 #else 71 67 UNUSED_PARAM(outputTarget); 72 68 UNUSED_PARAM(level); … … 76 72 if (kCVReturnSuccess != CVOpenGLTextureCacheCreateTextureFromImage(kCFAllocatorDefault, m_cache.get(), image, nullptr, &bareVideoTexture)) 77 73 return nullptr; 78 #elif USE(ANGLE)79 // FIXME: figure out how to do this integrating via ANGLE.80 UNUSED_PARAM(image);81 UNUSED_PARAM(outputTarget);82 UNUSED_PARAM(level);83 UNUSED_PARAM(internalFormat);84 UNUSED_PARAM(format);85 UNUSED_PARAM(type);86 return nullptr;87 74 #endif 88 75 RetainPtr<TextureType> videoTexture = adoptCF(bareVideoTexture); -
trunk/Source/WebCore/platform/graphics/cv/VideoTextureCopierCV.cpp
r246501 r246512 404 404 if (map.get().empty()) { 405 405 StringMap stringMap; 406 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RGB));407 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RGBA));408 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::LUMINANCE_ALPHA));409 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::LUMINANCE));410 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::ALPHA));411 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R8));412 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R16F));413 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R32F));414 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R8UI));415 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R8I));416 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R16UI));417 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R16I));418 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R32UI));419 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::R32I));420 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG8));421 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG16F));422 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG32F));423 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG8UI));424 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG8I));425 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG16UI));426 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG16I));427 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG32UI));428 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG32I));429 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RGB8));430 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::SRGB8));431 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RGBA8));432 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::SRGB8_ALPHA8));433 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RGBA4));434 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RGB10_A2));435 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::DEPTH_COMPONENT16));436 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::DEPTH_COMPONENT24));437 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::DEPTH_COMPONENT32F));438 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::DEPTH24_STENCIL8));439 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::DEPTH32F_STENCIL8));440 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RGB));441 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RGBA));442 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::LUMINANCE_ALPHA));443 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::LUMINANCE));444 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::ALPHA));445 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RED));446 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::RG_INTEGER));447 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::DEPTH_STENCIL));448 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::UNSIGNED_BYTE));449 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::UNSIGNED_SHORT_5_6_5));450 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::UNSIGNED_SHORT_4_4_4_4));451 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::UNSIGNED_SHORT_5_5_5_1));452 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::BYTE));453 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::HALF_FLOAT));454 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::FLOAT));455 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::UNSIGNED_SHORT));456 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::SHORT));457 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::UNSIGNED_INT));458 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::INT));459 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::UNSIGNED_INT_2_10_10_10_REV));460 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::UNSIGNED_INT_24_8));461 map.get().emplace(STRINGIFY_PAIR(G raphicsContext3D::FLOAT_32_UNSIGNED_INT_24_8_REV));406 map.get().emplace(STRINGIFY_PAIR(GL_RGB)); 407 map.get().emplace(STRINGIFY_PAIR(GL_RGBA)); 408 map.get().emplace(STRINGIFY_PAIR(GL_LUMINANCE_ALPHA)); 409 map.get().emplace(STRINGIFY_PAIR(GL_LUMINANCE)); 410 map.get().emplace(STRINGIFY_PAIR(GL_ALPHA)); 411 map.get().emplace(STRINGIFY_PAIR(GL_R8)); 412 map.get().emplace(STRINGIFY_PAIR(GL_R16F)); 413 map.get().emplace(STRINGIFY_PAIR(GL_R32F)); 414 map.get().emplace(STRINGIFY_PAIR(GL_R8UI)); 415 map.get().emplace(STRINGIFY_PAIR(GL_R8I)); 416 map.get().emplace(STRINGIFY_PAIR(GL_R16UI)); 417 map.get().emplace(STRINGIFY_PAIR(GL_R16I)); 418 map.get().emplace(STRINGIFY_PAIR(GL_R32UI)); 419 map.get().emplace(STRINGIFY_PAIR(GL_R32I)); 420 map.get().emplace(STRINGIFY_PAIR(GL_RG8)); 421 map.get().emplace(STRINGIFY_PAIR(GL_RG16F)); 422 map.get().emplace(STRINGIFY_PAIR(GL_RG32F)); 423 map.get().emplace(STRINGIFY_PAIR(GL_RG8UI)); 424 map.get().emplace(STRINGIFY_PAIR(GL_RG8I)); 425 map.get().emplace(STRINGIFY_PAIR(GL_RG16UI)); 426 map.get().emplace(STRINGIFY_PAIR(GL_RG16I)); 427 map.get().emplace(STRINGIFY_PAIR(GL_RG32UI)); 428 map.get().emplace(STRINGIFY_PAIR(GL_RG32I)); 429 map.get().emplace(STRINGIFY_PAIR(GL_RGB8)); 430 map.get().emplace(STRINGIFY_PAIR(GL_SRGB8)); 431 map.get().emplace(STRINGIFY_PAIR(GL_RGBA8)); 432 map.get().emplace(STRINGIFY_PAIR(GL_SRGB8_ALPHA8)); 433 map.get().emplace(STRINGIFY_PAIR(GL_RGBA4)); 434 map.get().emplace(STRINGIFY_PAIR(GL_RGB10_A2)); 435 map.get().emplace(STRINGIFY_PAIR(GL_DEPTH_COMPONENT16)); 436 map.get().emplace(STRINGIFY_PAIR(GL_DEPTH_COMPONENT24)); 437 map.get().emplace(STRINGIFY_PAIR(GL_DEPTH_COMPONENT32F)); 438 map.get().emplace(STRINGIFY_PAIR(GL_DEPTH24_STENCIL8)); 439 map.get().emplace(STRINGIFY_PAIR(GL_DEPTH32F_STENCIL8)); 440 map.get().emplace(STRINGIFY_PAIR(GL_RGB)); 441 map.get().emplace(STRINGIFY_PAIR(GL_RGBA)); 442 map.get().emplace(STRINGIFY_PAIR(GL_LUMINANCE_ALPHA)); 443 map.get().emplace(STRINGIFY_PAIR(GL_LUMINANCE)); 444 map.get().emplace(STRINGIFY_PAIR(GL_ALPHA)); 445 map.get().emplace(STRINGIFY_PAIR(GL_RED)); 446 map.get().emplace(STRINGIFY_PAIR(GL_RG_INTEGER)); 447 map.get().emplace(STRINGIFY_PAIR(GL_DEPTH_STENCIL)); 448 map.get().emplace(STRINGIFY_PAIR(GL_UNSIGNED_BYTE)); 449 map.get().emplace(STRINGIFY_PAIR(GL_UNSIGNED_SHORT_5_6_5)); 450 map.get().emplace(STRINGIFY_PAIR(GL_UNSIGNED_SHORT_4_4_4_4)); 451 map.get().emplace(STRINGIFY_PAIR(GL_UNSIGNED_SHORT_5_5_5_1)); 452 map.get().emplace(STRINGIFY_PAIR(GL_BYTE)); 453 map.get().emplace(STRINGIFY_PAIR(GL_HALF_FLOAT)); 454 map.get().emplace(STRINGIFY_PAIR(GL_FLOAT)); 455 map.get().emplace(STRINGIFY_PAIR(GL_UNSIGNED_SHORT)); 456 map.get().emplace(STRINGIFY_PAIR(GL_SHORT)); 457 map.get().emplace(STRINGIFY_PAIR(GL_UNSIGNED_INT)); 458 map.get().emplace(STRINGIFY_PAIR(GL_INT)); 459 map.get().emplace(STRINGIFY_PAIR(GL_UNSIGNED_INT_2_10_10_10_REV)); 460 map.get().emplace(STRINGIFY_PAIR(GL_UNSIGNED_INT_24_8)); 461 map.get().emplace(STRINGIFY_PAIR(GL_FLOAT_32_UNSIGNED_INT_24_8_REV)); 462 462 463 463 #if USE(OPENGL_ES) … … 531 531 fragmentShaderSource.appendLiteral("precision mediump float;\n"); 532 532 fragmentShaderSource.appendLiteral("uniform sampler2D u_texture;\n"); 533 #el if USE(OPENGL)533 #else 534 534 fragmentShaderSource.appendLiteral("uniform sampler2DRect u_texture;\n"); 535 #elif USE(ANGLE)536 // FIXME: determine how to access rectangular textures via ANGLE.537 ASSERT_NOT_REACHED();538 #else539 #error Unsupported configuration540 535 #endif 541 536 fragmentShaderSource.appendLiteral("varying vec2 v_texturePosition;\n"); … … 547 542 #if USE(OPENGL_ES) 548 543 fragmentShaderSource.appendLiteral(" vec4 color = texture2D(u_texture, texPos);\n"); 549 #el if USE(OPENGL)544 #else 550 545 fragmentShaderSource.appendLiteral(" vec4 color = texture2DRect(u_texture, texPos);\n"); 551 #elif USE(ANGLE)552 // FIXME: determine how to access rectangular textures via ANGLE.553 ASSERT_NOT_REACHED();554 #else555 #error Unsupported configuration556 546 #endif 557 547 fragmentShaderSource.appendLiteral(" if (u_swapColorChannels == 1) {\n"); … … 634 624 " v_yTextureCoordinate = normalizedPosition;\n" 635 625 " v_uvTextureCoordinate = normalizedPosition;\n" 636 #el if USE(OPENGL)626 #else 637 627 " v_yTextureCoordinate = normalizedPosition * u_yTextureSize;\n" 638 628 " v_uvTextureCoordinate = normalizedPosition * u_uvTextureSize;\n" 639 #elif USE(ANGLE)640 // FIXME: determine how to access rectangular textures via ANGLE.641 #else642 #error Unsupported configuration643 629 #endif 644 630 "}\n"_s … … 662 648 "#define SAMPLERTYPE sampler2D\n" 663 649 "#define TEXTUREFUNC texture2D\n" 664 #el if USE(OPENGL)650 #else 665 651 "#define SAMPLERTYPE sampler2DRect\n" 666 652 "#define TEXTUREFUNC texture2DRect\n" 667 #elif USE(ANGLE)668 // FIXME: determine how to access rectangular textures via ANGLE.669 #else670 #error Unsupported configuration671 653 #endif 672 654 "uniform SAMPLERTYPE u_yTexture;\n" … … 809 791 #if USE(OPENGL_ES) 810 792 GC3Denum videoTextureTarget = GraphicsContext3D::TEXTURE_2D; 811 #el if USE(OPENGL)793 #else 812 794 GC3Denum videoTextureTarget = GL_TEXTURE_RECTANGLE_ARB; 813 #elif USE(ANGLE)814 // FIXME: determine how to access rectangular textures via ANGLE.815 GC3Denum videoTextureTarget = GraphicsContext3D::TEXTURE_2D;816 #else817 #error Unsupported configuration818 795 #endif 819 796 auto uvTexture = m_context->createTexture(); … … 824 801 m_context->texParameteri(videoTextureTarget, GraphicsContext3D::TEXTURE_WRAP_S, GraphicsContext3D::CLAMP_TO_EDGE); 825 802 m_context->texParameteri(videoTextureTarget, GraphicsContext3D::TEXTURE_WRAP_T, GraphicsContext3D::CLAMP_TO_EDGE); 826 if (!m_context->texImageIOSurface2D(videoTextureTarget, G raphicsContext3D::RG, uvPlaneWidth, uvPlaneHeight, GraphicsContext3D::RG, GraphicsContext3D::UNSIGNED_BYTE, surface, 1)) {803 if (!m_context->texImageIOSurface2D(videoTextureTarget, GL_RG, uvPlaneWidth, uvPlaneHeight, GL_RG, GL_UNSIGNED_BYTE, surface, 1)) { 827 804 m_context->deleteTexture(uvTexture); 828 805 return false; … … 836 813 m_context->texParameteri(videoTextureTarget, GraphicsContext3D::TEXTURE_WRAP_S, GraphicsContext3D::CLAMP_TO_EDGE); 837 814 m_context->texParameteri(videoTextureTarget, GraphicsContext3D::TEXTURE_WRAP_T, GraphicsContext3D::CLAMP_TO_EDGE); 838 if (!m_context->texImageIOSurface2D(videoTextureTarget, G raphicsContext3D::LUMINANCE, yPlaneWidth, yPlaneHeight, GraphicsContext3D::LUMINANCE, GraphicsContext3D::UNSIGNED_BYTE, surface, 0)) {815 if (!m_context->texImageIOSurface2D(videoTextureTarget, GL_LUMINANCE, yPlaneWidth, yPlaneHeight, GL_LUMINANCE, GL_UNSIGNED_BYTE, surface, 0)) { 839 816 m_context->deleteTexture(yTexture); 840 817 m_context->deleteTexture(uvTexture); … … 891 868 GC3Denum videoTextureTarget = CVOpenGLESTextureGetTarget(inputVideoTexture); 892 869 CVOpenGLESTextureGetCleanTexCoords(inputVideoTexture, lowerLeft, lowerRight, upperRight, upperLeft); 893 #el if USE(OPENGL)870 #else 894 871 Platform3DObject videoTextureName = CVOpenGLTextureGetName(inputVideoTexture); 895 872 GC3Denum videoTextureTarget = CVOpenGLTextureGetTarget(inputVideoTexture); 896 873 CVOpenGLTextureGetCleanTexCoords(inputVideoTexture, lowerLeft, lowerRight, upperRight, upperLeft); 897 #elif USE(ANGLE)898 Platform3DObject videoTextureName = CVOpenGLTextureGetName(inputVideoTexture);899 GC3Denum videoTextureTarget = CVOpenGLTextureGetTarget(inputVideoTexture);900 CVOpenGLTextureGetCleanTexCoords(inputVideoTexture, lowerLeft, lowerRight, upperRight, upperLeft);901 // FIXME: determine how to access rectangular textures via ANGLE.902 ASSERT_NOT_REACHED();903 874 #endif 904 875 -
trunk/Source/WebCore/platform/graphics/opengl/Extensions3DOpenGL.cpp
r246501 r246512 26 26 #include "config.h" 27 27 28 #if ENABLE(GRAPHICS_CONTEXT_3D) && (USE(OPENGL) || (PLATFORM(COCOA) && USE(OPENGL_ES)))28 #if ENABLE(GRAPHICS_CONTEXT_3D) 29 29 30 30 #include "Extensions3DOpenGL.h" … … 309 309 } // namespace WebCore 310 310 311 #endif // ENABLE(GRAPHICS_CONTEXT_3D) && (USE(OPENGL) || (PLATFORM(COCOA) && USE(OPENGL_ES)))311 #endif // ENABLE(GRAPHICS_CONTEXT_3D) -
trunk/Source/WebCore/platform/graphics/opengl/Extensions3DOpenGLCommon.cpp
r246501 r246512 27 27 #include "config.h" 28 28 29 #if ENABLE(GRAPHICS_CONTEXT_3D) && (USE(OPENGL) || USE(OPENGL_ES))29 #if ENABLE(GRAPHICS_CONTEXT_3D) 30 30 #include "Extensions3DOpenGLCommon.h" 31 31 … … 257 257 } // namespace WebCore 258 258 259 #endif // ENABLE(GRAPHICS_CONTEXT_3D) && (USE(OPENGL) || USE(OPENGL_ES))259 #endif // ENABLE(GRAPHICS_CONTEXT_3D) -
trunk/Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGL.cpp
r246501 r246512 27 27 #include "config.h" 28 28 29 #if ENABLE(GRAPHICS_CONTEXT_3D) && (USE(OPENGL) || (PLATFORM(COCOA) && USE(OPENGL_ES)))29 #if ENABLE(GRAPHICS_CONTEXT_3D) 30 30 31 31 #include "GraphicsContext3D.h" … … 504 504 } 505 505 506 #endif // ENABLE(GRAPHICS_CONTEXT_3D) && (USE(OPENGL) || (PLATFORM(COCOA) && USE(OPENGL_ES)))506 #endif // ENABLE(GRAPHICS_CONTEXT_3D) -
trunk/Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp
r246501 r246512 29 29 #include "config.h" 30 30 31 #if ENABLE(GRAPHICS_CONTEXT_3D) && (USE(OPENGL) || USE(OPENGL_ES))31 #if ENABLE(GRAPHICS_CONTEXT_3D) 32 32 33 33 #include "GraphicsContext3D.h" … … 2080 2080 } 2081 2081 2082 #endif // ENABLE(GRAPHICS_CONTEXT_3D) && (USE(OPENGL) || USE(OPENGL_ES))2082 #endif // ENABLE(GRAPHICS_CONTEXT_3D) -
trunk/Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp
r246501 r246512 29 29 #include "config.h" 30 30 31 #if ENABLE(GRAPHICS_CONTEXT_3D) && USE(OPENGL_ES) &&!PLATFORM(IOS_FAMILY)31 #if ENABLE(GRAPHICS_CONTEXT_3D) && !PLATFORM(IOS_FAMILY) 32 32 33 33 #include "GraphicsContext3D.h" … … 401 401 } 402 402 403 #endif // ENABLE(GRAPHICS_CONTEXT_3D) && USE(OPENGL_ES) &&!PLATFORM(IOS_FAMILY)403 #endif // ENABLE(GRAPHICS_CONTEXT_3D) && !PLATFORM(IOS_FAMILY)
Note: See TracChangeset
for help on using the changeset viewer.