Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(115)

Side by Side Diff: Source/WebCore/platform/graphics/gpu/DrawingBuffer.cpp

Issue 7044078: Merge 88403 - 2011-06-08 Brian Salomon <bsalomon@google.com> Reviewed by James Robinson.... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/782/
Patch Set: Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2010, Google Inc. All rights reserved. 2 * Copyright (c) 2010, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 m_context->deleteRenderbuffer(m_depthBuffer); 77 m_context->deleteRenderbuffer(m_depthBuffer);
78 m_depthBuffer = 0; 78 m_depthBuffer = 0;
79 } 79 }
80 80
81 if (m_stencilBuffer) { 81 if (m_stencilBuffer) {
82 m_context->deleteRenderbuffer(m_stencilBuffer); 82 m_context->deleteRenderbuffer(m_stencilBuffer);
83 m_stencilBuffer = 0; 83 m_stencilBuffer = 0;
84 } 84 }
85 85
86 if (m_multisampleFBO) { 86 if (m_multisampleFBO) {
87 m_context->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, m_multisample FBO);
88 m_context->deleteFramebuffer(m_multisampleFBO); 87 m_context->deleteFramebuffer(m_multisampleFBO);
89 m_multisampleFBO = 0; 88 m_multisampleFBO = 0;
90 } 89 }
91 90
92 m_context->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, m_fbo);
93 m_context->deleteFramebuffer(m_fbo); 91 m_context->deleteFramebuffer(m_fbo);
94 m_fbo = 0; 92 m_fbo = 0;
95 } 93 }
96 94
97 void DrawingBuffer::createSecondaryBuffers() 95 void DrawingBuffer::createSecondaryBuffers()
98 { 96 {
99 // create a multisample FBO 97 // create a multisample FBO
100 if (multisample()) { 98 if (multisample()) {
101 m_multisampleFBO = m_context->createFramebuffer(); 99 m_multisampleFBO = m_context->createFramebuffer();
102 m_context->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, m_multisample FBO); 100 m_context->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, m_multisample FBO);
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 if (!m_context) 290 if (!m_context)
293 return; 291 return;
294 292
295 m_context->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, m_multisampleFBO ? m_multisampleFBO : m_fbo); 293 m_context->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, m_multisampleFBO ? m_multisampleFBO : m_fbo);
296 m_context->viewport(0, 0, m_size.width(), m_size.height()); 294 m_context->viewport(0, 0, m_size.width(), m_size.height());
297 } 295 }
298 296
299 } // namespace WebCore 297 } // namespace WebCore
300 298
301 #endif 299 #endif
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698