Changeset 220519 in webkit
- Timestamp:
- Aug 10, 2017 12:20:16 AM (7 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r220515 r220519 1 2017-08-10 Zan Dobersek <zdobersek@igalia.com> 2 3 [TexMap] Drop GraphicsContext3D usage from BitmapTextureGL 4 https://bugs.webkit.org/show_bug.cgi?id=175317 5 6 Reviewed by Carlos Garcia Campos. 7 8 Have BitmapTextureGL use direct OpenGL API entrypoints and constants 9 instead of leveraging the GraphicsContext3D class. Any GraphicsContext3D 10 object passed to BitmapTextureGL would assume rendering to the GL context 11 that's current on that thread, translating method invocations to the 12 OpenGL API. We can do this by ourselves and benefit by avoiding allocating 13 GraphicsContext3D resources like the ANGLE compiler that are by most useful 14 for WebGL. 15 16 BitmapTextureGL::create() call sites are adjusted to stop passing a 17 GraphicsContext3D reference. BitmapTextureGL::bindAsSurface() doesn't need 18 a replacement for the passed-in GraphicsContext3D object since that object 19 originated from the TextureMapperGL instance, whose GraphicsContext3D is by 20 default of the render-to-current-context nature. Other changes are direct 21 translations of GraphicsContext3D methods to OpenGL API calls, or of 22 GraphicsContext3D values to OpenGL API constants. 23 24 No new tests -- no change in behavior. 25 26 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: 27 (WebCore::MediaPlayerPrivateGStreamerBase::pushTextureToCompositor): 28 * platform/graphics/texmap/BitmapTextureGL.cpp: 29 Also remove an unnecessary GraphicsContext.h header inclusion. 30 (WebCore::BitmapTextureGL::BitmapTextureGL): 31 (WebCore::BitmapTextureGL::didReset): 32 (WebCore::BitmapTextureGL::updateContentsNoSwizzle): 33 (WebCore::BitmapTextureGL::updateContents): 34 (WebCore::BitmapTextureGL::initializeStencil): 35 (WebCore::BitmapTextureGL::initializeDepthBuffer): 36 (WebCore::BitmapTextureGL::clearIfNeeded): 37 (WebCore::BitmapTextureGL::createFboIfNeeded): 38 (WebCore::BitmapTextureGL::bindAsSurface): 39 (WebCore::BitmapTextureGL::~BitmapTextureGL): 40 (WebCore::BitmapTextureGL::copyFromExternalTexture): 41 * platform/graphics/texmap/BitmapTextureGL.h: 42 (WebCore::BitmapTextureGL::create): 43 (WebCore::BitmapTextureGL::textureTarget const): 44 (WebCore::BitmapTextureGL::internalFormat const): 45 * platform/graphics/texmap/BitmapTexturePool.cpp: 46 (WebCore::BitmapTexturePool::createTexture): 47 * platform/graphics/texmap/TextureMapperGL.cpp: 48 (WebCore::TextureMapperGL::bindSurface): 49 (WebCore::TextureMapperGL::createTexture): 50 1 51 2017-08-09 Michael Catanzaro <mcatanzaro@igalia.com> 2 52 -
trunk/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp
r220397 r220519 624 624 contextAttributes.initialize(); 625 625 626 auto texture = BitmapTextureGL::create(contextAttributes , *m_context3D);626 auto texture = BitmapTextureGL::create(contextAttributes); 627 627 texture->reset(size, GST_VIDEO_INFO_HAS_ALPHA(&videoInfo) ? BitmapTexture::SupportsAlpha : BitmapTexture::NoFlag); 628 628 buffer = std::make_unique<TextureMapperPlatformLayerBuffer>(WTFMove(texture)); -
trunk/Source/WebCore/platform/graphics/texmap/BitmapTextureGL.cpp
r220399 r220519 27 27 #include "Extensions3D.h" 28 28 #include "FilterOperations.h" 29 #include "GraphicsContext.h"30 29 #include "Image.h" 31 30 #include "LengthFunctions.h" … … 58 57 } 59 58 60 BitmapTextureGL::BitmapTextureGL(const TextureMapperContextAttributes& contextAttributes, RefPtr<GraphicsContext3D>&& context3D, const Flags flags, GC3Dint internalFormat)59 BitmapTextureGL::BitmapTextureGL(const TextureMapperContextAttributes& contextAttributes, const Flags flags, GLint internalFormat) 61 60 : m_contextAttributes(contextAttributes) 62 , m_context3D(WTFMove(context3D)) 63 { 64 if (internalFormat != GraphicsContext3D::DONT_CARE) { 61 { 62 if (internalFormat != GL_DONT_CARE) { 65 63 m_internalFormat = m_format = internalFormat; 66 64 return; … … 68 66 69 67 if (flags & FBOAttachment) 70 m_internalFormat = m_format = G raphicsContext3D::RGBA;68 m_internalFormat = m_format = GL_RGBA; 71 69 else { 72 70 // If GL_EXT_texture_format_BGRA8888 is supported in the OpenGLES 73 71 // internal and external formats need to be BGRA 74 m_internalFormat = G raphicsContext3D::RGBA;75 m_format = G raphicsContext3D::BGRA;72 m_internalFormat = GL_RGBA; 73 m_format = GL_BGRA; 76 74 if (m_contextAttributes.isGLES2Compliant) { 77 75 if (m_contextAttributes.supportsBGRA8888) 78 m_internalFormat = G raphicsContext3D::BGRA;76 m_internalFormat = GL_BGRA; 79 77 else 80 m_format = G raphicsContext3D::RGBA;78 m_format = GL_RGBA; 81 79 } 82 80 } … … 96 94 { 97 95 if (!m_id) 98 m_id = m_context3D->createTexture();96 glGenTextures(1, &m_id); 99 97 100 98 m_shouldClear = true; … … 103 101 104 102 m_textureSize = contentSize(); 105 m_context3D->bindTexture(GraphicsContext3D::TEXTURE_2D, m_id);106 m_context3D->texParameteri(GraphicsContext3D::TEXTURE_2D, GraphicsContext3D::TEXTURE_MIN_FILTER, GraphicsContext3D::LINEAR);107 m_context3D->texParameteri(GraphicsContext3D::TEXTURE_2D, GraphicsContext3D::TEXTURE_MAG_FILTER, GraphicsContext3D::LINEAR);108 m_context3D->texParameteri(GraphicsContext3D::TEXTURE_2D, GraphicsContext3D::TEXTURE_WRAP_S, GraphicsContext3D::CLAMP_TO_EDGE);109 m_context3D->texParameteri(GraphicsContext3D::TEXTURE_2D, GraphicsContext3D::TEXTURE_WRAP_T, GraphicsContext3D::CLAMP_TO_EDGE);110 111 m_context3D->texImage2DDirect(GraphicsContext3D::TEXTURE_2D, 0, m_internalFormat, m_textureSize.width(), m_textureSize.height(), 0, m_format, m_type, 0);112 } 113 114 void BitmapTextureGL::updateContentsNoSwizzle(const void* srcData, const IntRect& targetRect, const IntPoint& sourceOffset, int bytesPerLine, unsigned bytesPerPixel, Platform3DObject glFormat)103 glBindTexture(GL_TEXTURE_2D, m_id); 104 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); 105 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); 106 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); 107 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); 108 109 glTexImage2D(GL_TEXTURE_2D, 0, m_internalFormat, m_textureSize.width(), m_textureSize.height(), 0, m_format, m_type, 0); 110 } 111 112 void BitmapTextureGL::updateContentsNoSwizzle(const void* srcData, const IntRect& targetRect, const IntPoint& sourceOffset, int bytesPerLine, unsigned bytesPerPixel, GLuint glFormat) 115 113 { 116 114 // For ES drivers that don't support sub-images. 117 115 bool contextSupportsUnpackSubimage = m_contextAttributes.supportsUnpackSubimage; 118 116 119 m_context3D->bindTexture(GraphicsContext3D::TEXTURE_2D, m_id);117 glBindTexture(GL_TEXTURE_2D, m_id); 120 118 121 119 if (contextSupportsUnpackSubimage) { 122 120 // Use the OpenGL sub-image extension, now that we know it's available. 123 m_context3D->pixelStorei(GraphicsContext3D::UNPACK_ROW_LENGTH, bytesPerLine / bytesPerPixel);124 m_context3D->pixelStorei(GraphicsContext3D::UNPACK_SKIP_ROWS, sourceOffset.y());125 m_context3D->pixelStorei(GraphicsContext3D::UNPACK_SKIP_PIXELS, sourceOffset.x());126 } 127 128 m_context3D->texSubImage2D(GraphicsContext3D::TEXTURE_2D, 0, targetRect.x(), targetRect.y(), targetRect.width(), targetRect.height(), glFormat, m_type, srcData);121 glPixelStorei(GL_UNPACK_ROW_LENGTH, bytesPerLine / bytesPerPixel); 122 glPixelStorei(GL_UNPACK_SKIP_ROWS, sourceOffset.y()); 123 glPixelStorei(GL_UNPACK_SKIP_PIXELS, sourceOffset.x()); 124 } 125 126 glTexSubImage2D(GL_TEXTURE_2D, 0, targetRect.x(), targetRect.y(), targetRect.width(), targetRect.height(), glFormat, m_type, srcData); 129 127 130 128 if (contextSupportsUnpackSubimage) { 131 m_context3D->pixelStorei(GraphicsContext3D::UNPACK_ROW_LENGTH, 0);132 m_context3D->pixelStorei(GraphicsContext3D::UNPACK_SKIP_ROWS, 0);133 m_context3D->pixelStorei(GraphicsContext3D::UNPACK_SKIP_PIXELS, 0);129 glPixelStorei(GL_UNPACK_ROW_LENGTH, 0); 130 glPixelStorei(GL_UNPACK_SKIP_ROWS, 0); 131 glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0); 134 132 } 135 133 } … … 137 135 void BitmapTextureGL::updateContents(const void* srcData, const IntRect& targetRect, const IntPoint& sourceOffset, int bytesPerLine, UpdateContentsFlag updateContentsFlag) 138 136 { 139 m_context3D->bindTexture(GraphicsContext3D::TEXTURE_2D, m_id);137 glBindTexture(GL_TEXTURE_2D, m_id); 140 138 141 139 const unsigned bytesPerPixel = 4; … … 149 147 150 148 // prepare temporaryData if necessary 151 if ((m_format == G raphicsContext3D::RGBA && updateContentsFlag == UpdateCannotModifyOriginalImageData) || requireSubImageBuffer) {149 if ((m_format == GL_RGBA && updateContentsFlag == UpdateCannotModifyOriginalImageData) || requireSubImageBuffer) { 152 150 temporaryData.resize(targetRect.width() * targetRect.height() * bytesPerPixel); 153 151 data = temporaryData.data(); … … 166 164 } 167 165 168 if (m_format == G raphicsContext3D::RGBA)166 if (m_format == GL_RGBA) 169 167 swizzleBGRAToRGBA(reinterpret_cast_ptr<uint32_t*>(data), IntRect(adjustedSourceOffset, targetRect.size()), bytesPerLine / bytesPerPixel); 170 168 … … 262 260 return; 263 261 264 m_rbo = m_context3D->createRenderbuffer();265 m_context3D->bindRenderbuffer(GraphicsContext3D::RENDERBUFFER, m_rbo);266 m_context3D->renderbufferStorage(GraphicsContext3D::RENDERBUFFER, GraphicsContext3D::STENCIL_INDEX8, m_textureSize.width(), m_textureSize.height());267 m_context3D->bindRenderbuffer(GraphicsContext3D::RENDERBUFFER, 0);268 m_context3D->framebufferRenderbuffer(GraphicsContext3D::FRAMEBUFFER, GraphicsContext3D::STENCIL_ATTACHMENT, GraphicsContext3D::RENDERBUFFER, m_rbo);269 m_context3D->clearStencil(0);270 m_context3D->clear(GraphicsContext3D::STENCIL_BUFFER_BIT);262 glGenRenderbuffers(1, &m_rbo); 263 glBindRenderbuffer(GL_RENDERBUFFER, m_rbo); 264 glRenderbufferStorage(GL_RENDERBUFFER, GL_STENCIL_INDEX8, m_textureSize.width(), m_textureSize.height()); 265 glBindRenderbuffer(GL_RENDERBUFFER, 0); 266 glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_RENDERBUFFER, m_rbo); 267 glClearStencil(0); 268 glClear(GL_STENCIL_BUFFER_BIT); 271 269 } 272 270 … … 276 274 return; 277 275 278 m_depthBufferObject = m_context3D->createRenderbuffer();279 m_context3D->bindRenderbuffer(GraphicsContext3D::RENDERBUFFER, m_depthBufferObject);280 m_context3D->renderbufferStorage(GraphicsContext3D::RENDERBUFFER, GraphicsContext3D::DEPTH_COMPONENT16, m_textureSize.width(), m_textureSize.height());281 m_context3D->bindRenderbuffer(GraphicsContext3D::RENDERBUFFER, 0);282 m_context3D->framebufferRenderbuffer(GraphicsContext3D::FRAMEBUFFER, GraphicsContext3D::DEPTH_ATTACHMENT, GraphicsContext3D::RENDERBUFFER, m_depthBufferObject);276 glGenRenderbuffers(1, &m_depthBufferObject); 277 glBindRenderbuffer(GL_RENDERBUFFER, m_depthBufferObject); 278 glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT16, m_textureSize.width(), m_textureSize.height()); 279 glBindRenderbuffer(GL_RENDERBUFFER, 0); 280 glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_RENDERBUFFER, m_depthBufferObject); 283 281 } 284 282 … … 290 288 m_clipStack.reset(IntRect(IntPoint::zero(), m_textureSize), ClipStack::YAxisMode::Default); 291 289 m_clipStack.applyIfNeeded(); 292 m_context3D->clearColor(0, 0, 0, 0);293 m_context3D->clear(GraphicsContext3D::COLOR_BUFFER_BIT);290 glClearColor(0, 0, 0, 0); 291 glClear(GL_COLOR_BUFFER_BIT); 294 292 m_shouldClear = false; 295 293 } … … 300 298 return; 301 299 302 m_fbo = m_context3D->createFramebuffer();303 m_context3D->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, m_fbo);304 m_context3D->framebufferTexture2D(GraphicsContext3D::FRAMEBUFFER, GraphicsContext3D::COLOR_ATTACHMENT0, GraphicsContext3D::TEXTURE_2D, id(), 0);300 glGenFramebuffers(1, &m_fbo); 301 glBindFramebuffer(GL_FRAMEBUFFER, m_fbo); 302 glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, id(), 0); 305 303 m_shouldClear = true; 306 304 } 307 305 308 void BitmapTextureGL::bindAsSurface( GraphicsContext3D* context3D)309 { 310 context3D->bindTexture(GraphicsContext3D::TEXTURE_2D, 0);306 void BitmapTextureGL::bindAsSurface() 307 { 308 glBindTexture(GL_TEXTURE_2D, 0); 311 309 createFboIfNeeded(); 312 context3D->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, m_fbo);313 context3D->viewport(0, 0, m_textureSize.width(), m_textureSize.height());310 glBindFramebuffer(GL_FRAMEBUFFER, m_fbo); 311 glViewport(0, 0, m_textureSize.width(), m_textureSize.height()); 314 312 clearIfNeeded(); 315 313 m_clipStack.apply(); … … 319 317 { 320 318 if (m_id) 321 m_context3D->deleteTexture(m_id);319 glDeleteTextures(1, &m_id); 322 320 323 321 if (m_fbo) 324 m_context3D->deleteFramebuffer(m_fbo);322 glDeleteFramebuffers(1, &m_fbo); 325 323 326 324 if (m_rbo) 327 m_context3D->deleteRenderbuffer(m_rbo);325 glDeleteRenderbuffers(1, &m_rbo); 328 326 329 327 if (m_depthBufferObject) 330 m_context3D->deleteRenderbuffer(m_depthBufferObject);328 glDeleteRenderbuffers(1, &m_depthBufferObject); 331 329 } 332 330 … … 342 340 343 341 344 void BitmapTextureGL::copyFromExternalTexture(Platform3DObject sourceTextureID) 345 { 346 GC3Dint boundTexture = 0; 347 GC3Dint boundFramebuffer = 0; 348 GC3Dint boundActiveTexture = 0; 349 350 m_context3D->getIntegerv(GraphicsContext3D::TEXTURE_BINDING_2D, &boundTexture); 351 m_context3D->getIntegerv(GraphicsContext3D::FRAMEBUFFER_BINDING, &boundFramebuffer); 352 m_context3D->getIntegerv(GraphicsContext3D::ACTIVE_TEXTURE, &boundActiveTexture); 353 354 m_context3D->bindTexture(GraphicsContext3D::TEXTURE_2D, sourceTextureID); 355 356 Platform3DObject copyFbo = m_context3D->createFramebuffer(); 357 m_context3D->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, copyFbo); 358 m_context3D->framebufferTexture2D(GraphicsContext3D::FRAMEBUFFER, GraphicsContext3D::COLOR_ATTACHMENT0, GraphicsContext3D::TEXTURE_2D, sourceTextureID, 0); 359 360 m_context3D->activeTexture(GraphicsContext3D::TEXTURE0); 361 m_context3D->bindTexture(GraphicsContext3D::TEXTURE_2D, id()); 362 m_context3D->copyTexSubImage2D(GraphicsContext3D::TEXTURE_2D, 0, 0, 0, 0, 0, m_textureSize.width(), m_textureSize.height()); 363 364 m_context3D->bindTexture(GraphicsContext3D::TEXTURE_2D, boundTexture); 365 m_context3D->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, boundFramebuffer); 366 m_context3D->bindTexture(GraphicsContext3D::TEXTURE_2D, boundTexture); 367 m_context3D->activeTexture(boundActiveTexture); 368 m_context3D->deleteFramebuffer(copyFbo); 342 void BitmapTextureGL::copyFromExternalTexture(GLuint sourceTextureID) 343 { 344 GLint boundTexture = 0; 345 GLint boundFramebuffer = 0; 346 GLint boundActiveTexture = 0; 347 348 glGetIntegerv(GL_TEXTURE_BINDING_2D, &boundTexture); 349 glGetIntegerv(GL_FRAMEBUFFER_BINDING, &boundFramebuffer); 350 glGetIntegerv(GL_ACTIVE_TEXTURE, &boundActiveTexture); 351 352 glBindTexture(GL_TEXTURE_2D, sourceTextureID); 353 354 GLuint copyFbo = 0; 355 glGenFramebuffers(1, ©Fbo); 356 glBindFramebuffer(GL_FRAMEBUFFER, copyFbo); 357 glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, sourceTextureID, 0); 358 359 glActiveTexture(GL_TEXTURE0); 360 glBindTexture(GL_TEXTURE_2D, id()); 361 glCopyTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, 0, 0, m_textureSize.width(), m_textureSize.height()); 362 363 glBindTexture(GL_TEXTURE_2D, boundTexture); 364 glBindFramebuffer(GL_FRAMEBUFFER, boundFramebuffer); 365 glBindTexture(GL_TEXTURE_2D, boundTexture); 366 glActiveTexture(boundActiveTexture); 367 glDeleteFramebuffers(1, ©Fbo); 369 368 } 370 369 -
trunk/Source/WebCore/platform/graphics/texmap/BitmapTextureGL.h
r220392 r220519 27 27 #include "ClipStack.h" 28 28 #include "FilterOperation.h" 29 #include "GraphicsContext3D.h"30 29 #include "IntSize.h" 31 30 #include "TextureMapperContextAttributes.h" 32 31 #include "TextureMapperGL.h" 32 #include "TextureMapperGLHeaders.h" 33 33 34 34 namespace WebCore { … … 40 40 class BitmapTextureGL : public BitmapTexture { 41 41 public: 42 static Ref<BitmapTexture> create(const TextureMapperContextAttributes& contextAttributes, Ref<GraphicsContext3D>&& context3D, const Flags flags = NoFlag, GC3Dint internalFormat = GraphicsContext3D::DONT_CARE)42 static Ref<BitmapTexture> create(const TextureMapperContextAttributes& contextAttributes, const Flags flags = NoFlag, GLint internalFormat = GL_DONT_CARE) 43 43 { 44 return adoptRef(*new BitmapTextureGL(contextAttributes, WTFMove(context3D),flags, internalFormat));44 return adoptRef(*new BitmapTextureGL(contextAttributes, flags, internalFormat)); 45 45 } 46 46 … … 50 50 bool isValid() const override; 51 51 void didReset() override; 52 void bindAsSurface( GraphicsContext3D*);52 void bindAsSurface(); 53 53 void initializeStencil(); 54 54 void initializeDepthBuffer(); 55 55 virtual uint32_t id() const { return m_id; } 56 uint32_t textureTarget() const { return G raphicsContext3D::TEXTURE_2D; }56 uint32_t textureTarget() const { return GL_TEXTURE_2D; } 57 57 IntSize textureSize() const { return m_textureSize; } 58 58 void updateContents(Image*, const IntRect&, const IntPoint&, UpdateContentsFlag) override; 59 59 void updateContents(const void*, const IntRect& target, const IntPoint& sourceOffset, int bytesPerLine, UpdateContentsFlag) override; 60 void updateContentsNoSwizzle(const void*, const IntRect& target, const IntPoint& sourceOffset, int bytesPerLine, unsigned bytesPerPixel = 4, Platform3DObject glFormat = GraphicsContext3D::RGBA);60 void updateContentsNoSwizzle(const void*, const IntRect& target, const IntPoint& sourceOffset, int bytesPerLine, unsigned bytesPerPixel = 4, GLuint glFormat = GL_RGBA); 61 61 bool isBackedByOpenGL() const override { return true; } 62 62 … … 76 76 ClipStack& clipStack() { return m_clipStack; } 77 77 78 G C3Dint internalFormat() const { return m_internalFormat; }78 GLint internalFormat() const { return m_internalFormat; } 79 79 80 void copyFromExternalTexture( Platform3DObject textureID);80 void copyFromExternalTexture(GLuint textureID); 81 81 82 82 private: 83 BitmapTextureGL(const TextureMapperContextAttributes&, RefPtr<GraphicsContext3D>&&, const Flags, GC3Dint internalFormat);83 BitmapTextureGL(const TextureMapperContextAttributes&, const Flags, GLint internalFormat); 84 84 85 Platform3DObject m_id { 0 };85 GLuint m_id { 0 }; 86 86 IntSize m_textureSize; 87 87 IntRect m_dirtyRect; 88 Platform3DObject m_fbo { 0 };89 Platform3DObject m_rbo { 0 };90 Platform3DObject m_depthBufferObject { 0 };88 GLuint m_fbo { 0 }; 89 GLuint m_rbo { 0 }; 90 GLuint m_depthBufferObject { 0 }; 91 91 bool m_shouldClear { true }; 92 92 ClipStack m_clipStack; 93 93 TextureMapperContextAttributes m_contextAttributes; 94 RefPtr<GraphicsContext3D> m_context3D;95 94 96 95 void clearIfNeeded(); … … 99 98 FilterInfo m_filterInfo; 100 99 101 G C3Dint m_internalFormat;102 G C3Denum m_format;103 G C3Denum m_type {100 GLint m_internalFormat; 101 GLenum m_format; 102 GLenum m_type { 104 103 #if OS(DARWIN) 105 104 GL_UNSIGNED_INT_8_8_8_8_REV 106 105 #else 107 G raphicsContext3D::UNSIGNED_BYTE106 GL_UNSIGNED_BYTE 108 107 #endif 109 108 }; -
trunk/Source/WebCore/platform/graphics/texmap/BitmapTexturePool.cpp
r220392 r220519 95 95 { 96 96 #if USE(TEXTURE_MAPPER_GL) 97 return BitmapTextureGL::create(m_contextAttributes, *m_context3D,flags);97 return BitmapTextureGL::create(m_contextAttributes, flags); 98 98 #else 99 99 UNUSED_PARAM(flags); -
trunk/Source/WebCore/platform/graphics/texmap/TextureMapperGL.cpp
r220399 r220519 665 665 } 666 666 667 static_cast<BitmapTextureGL*>(surface)->bindAsSurface( m_context3D.get());667 static_cast<BitmapTextureGL*>(surface)->bindAsSurface(); 668 668 data().projectionMatrix = createProjectionMatrix(surface->size(), true /* mirrored */); 669 669 data().currentSurface = surface; … … 761 761 Ref<BitmapTexture> TextureMapperGL::createTexture(GC3Dint internalFormat) 762 762 { 763 return BitmapTextureGL::create(m_contextAttributes, *m_context3D,internalFormat);763 return BitmapTextureGL::create(m_contextAttributes, internalFormat); 764 764 } 765 765
Note: See TracChangeset
for help on using the changeset viewer.